aboutsummaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@g5.osdl.org>2006-03-21 09:25:15 -0800
committerLinus Torvalds <torvalds@g5.osdl.org>2006-03-21 09:25:15 -0800
commit08a4ecee986dd98e86090ff5faac4782b6765aed (patch)
tree74df5de49f38c432a6a18303b0c6d834fd09028f /include/linux
parentba93c6297b9cfad5a70b5e5ed13c9dbead6601d3 (diff)
parentb3229087c5e08589cea4f5040dab56f7dc11332a (diff)
Merge master.kernel.org:/pub/scm/linux/kernel/git/gregkh/driver-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/gregkh/driver-2.6: (23 commits) [PATCH] sysfs: fix a kobject leak in sysfs_add_link on the error path [PATCH] sysfs: don't export dir symbols [PATCH] get_cpu_sysdev() signedness fix [PATCH] kobject_add_dir [PATCH] debugfs: Add debugfs_create_blob() helper for exporting binary data [PATCH] sysfs: fix problem with duplicate sysfs directories and files [PATCH] Kobject: kobject.h: fix a typo [PATCH] Kobject: provide better warning messages when people do stupid things [PATCH] Driver core: add macros notice(), dev_notice() [PATCH] firmware: fix BUG: in fw_realloc_buffer [PATCH] sysfs: kzalloc conversion [PATCH] fix module sysfs files reference counting [PATCH] add EXPORT_SYMBOL_GPL_FUTURE() to USB subsystem [PATCH] add EXPORT_SYMBOL_GPL_FUTURE() to RCU subsystem [PATCH] add EXPORT_SYMBOL_GPL_FUTURE() [PATCH] Clean up module.c symbol searching logic [PATCH] kobj_map semaphore to mutex conversion [PATCH] kref: avoid an atomic operation in kref_put() [PATCH] handle errors returned by platform_get_irq*() [PATCH] driver core: platform_get_irq*(): return -ENXIO on error ...
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/cpu.h2
-rw-r--r--include/linux/debugfs.h15
-rw-r--r--include/linux/device.h2
-rw-r--r--include/linux/kobj_map.h4
-rw-r--r--include/linux/kobject.h4
-rw-r--r--include/linux/module.h10
6 files changed, 33 insertions, 4 deletions
diff --git a/include/linux/cpu.h b/include/linux/cpu.h
index 0ed1d4853c6..d612b89dce3 100644
--- a/include/linux/cpu.h
+++ b/include/linux/cpu.h
@@ -32,7 +32,7 @@ struct cpu {
};
extern int register_cpu(struct cpu *, int, struct node *);
-extern struct sys_device *get_cpu_sysdev(int cpu);
+extern struct sys_device *get_cpu_sysdev(unsigned cpu);
#ifdef CONFIG_HOTPLUG_CPU
extern void unregister_cpu(struct cpu *, struct node *);
#endif
diff --git a/include/linux/debugfs.h b/include/linux/debugfs.h
index a5fa6a6eede..4b0428e335b 100644
--- a/include/linux/debugfs.h
+++ b/include/linux/debugfs.h
@@ -21,6 +21,11 @@
struct file_operations;
+struct debugfs_blob_wrapper {
+ void *data;
+ unsigned long size;
+};
+
#if defined(CONFIG_DEBUG_FS)
struct dentry *debugfs_create_file(const char *name, mode_t mode,
struct dentry *parent, void *data,
@@ -39,6 +44,9 @@ struct dentry *debugfs_create_u32(const char *name, mode_t mode,
struct dentry *debugfs_create_bool(const char *name, mode_t mode,
struct dentry *parent, u32 *value);
+struct dentry *debugfs_create_blob(const char *name, mode_t mode,
+ struct dentry *parent,
+ struct debugfs_blob_wrapper *blob);
#else
#include <linux/err.h>
@@ -94,6 +102,13 @@ static inline struct dentry *debugfs_create_bool(const char *name, mode_t mode,
return ERR_PTR(-ENODEV);
}
+static inline struct dentry *debugfs_create_blob(const char *name, mode_t mode,
+ struct dentry *parent,
+ struct debugfs_blob_wrapper *blob)
+{
+ return ERR_PTR(-ENODEV);
+}
+
#endif
#endif
diff --git a/include/linux/device.h b/include/linux/device.h
index 58df18d9cd3..5b595fdfb67 100644
--- a/include/linux/device.h
+++ b/include/linux/device.h
@@ -424,6 +424,8 @@ extern void firmware_unregister(struct subsystem *);
dev_printk(KERN_INFO , dev , format , ## arg)
#define dev_warn(dev, format, arg...) \
dev_printk(KERN_WARNING , dev , format , ## arg)
+#define dev_notice(dev, format, arg...) \
+ dev_printk(KERN_NOTICE , dev , format , ## arg)
/* Create alias, so I can be autoloaded. */
#define MODULE_ALIAS_CHARDEV(major,minor) \
diff --git a/include/linux/kobj_map.h b/include/linux/kobj_map.h
index cbe7d800804..bafe178a381 100644
--- a/include/linux/kobj_map.h
+++ b/include/linux/kobj_map.h
@@ -1,6 +1,6 @@
#ifdef __KERNEL__
-#include <asm/semaphore.h>
+#include <linux/mutex.h>
typedef struct kobject *kobj_probe_t(dev_t, int *, void *);
struct kobj_map;
@@ -9,6 +9,6 @@ int kobj_map(struct kobj_map *, dev_t, unsigned long, struct module *,
kobj_probe_t *, int (*)(dev_t, void *), void *);
void kobj_unmap(struct kobj_map *, dev_t, unsigned long);
struct kobject *kobj_lookup(struct kobj_map *, dev_t, int *);
-struct kobj_map *kobj_map_init(kobj_probe_t *, struct semaphore *);
+struct kobj_map *kobj_map_init(kobj_probe_t *, struct mutex *);
#endif
diff --git a/include/linux/kobject.h b/include/linux/kobject.h
index c374b5fa8d3..4cb1214ec29 100644
--- a/include/linux/kobject.h
+++ b/include/linux/kobject.h
@@ -80,6 +80,8 @@ extern void kobject_unregister(struct kobject *);
extern struct kobject * kobject_get(struct kobject *);
extern void kobject_put(struct kobject *);
+extern struct kobject *kobject_add_dir(struct kobject *, const char *);
+
extern char * kobject_get_path(struct kobject *, gfp_t);
struct kobj_type {
@@ -255,7 +257,7 @@ struct subsys_attribute {
extern int subsys_create_file(struct subsystem * , struct subsys_attribute *);
extern void subsys_remove_file(struct subsystem * , struct subsys_attribute *);
-#if defined(CONFIG_HOTPLUG) & defined(CONFIG_NET)
+#if defined(CONFIG_HOTPLUG) && defined(CONFIG_NET)
void kobject_uevent(struct kobject *kobj, enum kobject_action action);
int add_uevent_var(char **envp, int num_envp, int *cur_index,
diff --git a/include/linux/module.h b/include/linux/module.h
index 84d75f3a8ac..70bd843c71c 100644
--- a/include/linux/module.h
+++ b/include/linux/module.h
@@ -198,6 +198,9 @@ void *__symbol_get_gpl(const char *symbol);
#define EXPORT_SYMBOL_GPL(sym) \
__EXPORT_SYMBOL(sym, "_gpl")
+#define EXPORT_SYMBOL_GPL_FUTURE(sym) \
+ __EXPORT_SYMBOL(sym, "_gpl_future")
+
#endif
struct module_ref
@@ -242,6 +245,7 @@ struct module
/* Sysfs stuff. */
struct module_kobject mkobj;
struct module_param_attrs *param_attrs;
+ struct module_attribute *modinfo_attrs;
const char *version;
const char *srcversion;
@@ -255,6 +259,11 @@ struct module
unsigned int num_gpl_syms;
const unsigned long *gpl_crcs;
+ /* symbols that will be GPL-only in the near future. */
+ const struct kernel_symbol *gpl_future_syms;
+ unsigned int num_gpl_future_syms;
+ const unsigned long *gpl_future_crcs;
+
/* Exception table */
unsigned int num_exentries;
const struct exception_table_entry *extable;
@@ -441,6 +450,7 @@ void module_remove_driver(struct device_driver *);
#else /* !CONFIG_MODULES... */
#define EXPORT_SYMBOL(sym)
#define EXPORT_SYMBOL_GPL(sym)
+#define EXPORT_SYMBOL_GPL_FUTURE(sym)
/* Given an address, look for it in the exception tables. */
static inline const struct exception_table_entry *