summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <greg@kroah.com>2004-09-12 21:00:26 -0700
committerGreg Kroah-Hartman <greg@kroah.com>2004-09-12 21:00:26 -0700
commitaaf87e481e621730cea49b0bc4270faa66400fac (patch)
treed71ab1059667c4582fc425eb3362c6d305bc478f /include/linux
parent8a690d16e64e76f884d74128dc10ac6b28c135d2 (diff)
parent12025235884570ba7f02a6f427f973ac6be7ec54 (diff)
Merge kroah.com:/home/greg/linux/BK/bleed-2.6
into kroah.com:/home/greg/linux/BK/driver-2.6
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/kobject.h35
-rw-r--r--include/linux/netlink.h1
2 files changed, 33 insertions, 3 deletions
diff --git a/include/linux/kobject.h b/include/linux/kobject.h
index 331d25b9cc41..dfadbe4fa848 100644
--- a/include/linux/kobject.h
+++ b/include/linux/kobject.h
@@ -26,6 +26,9 @@
#define KOBJ_NAME_LEN 20
+/* counter to tag the hotplug event, read only except for the kobject core */
+extern u64 hotplug_seqnum;
+
struct kobject {
char * k_name;
char name[KOBJ_NAME_LEN];
@@ -59,9 +62,7 @@ extern void kobject_unregister(struct kobject *);
extern struct kobject * kobject_get(struct kobject *);
extern void kobject_put(struct kobject *);
-extern void kobject_hotplug(const char *action, struct kobject *);
-
-extern char * kobject_get_path(struct kset *, struct kobject *, int);
+extern char * kobject_get_path(struct kobject *, int);
struct kobj_type {
void (*release)(struct kobject *);
@@ -234,5 +235,33 @@ struct subsys_attribute {
extern int subsys_create_file(struct subsystem * , struct subsys_attribute *);
extern void subsys_remove_file(struct subsystem * , struct subsys_attribute *);
+
+#ifdef CONFIG_HOTPLUG
+extern void kobject_hotplug(const char *action, struct kobject *kobj);
+#else
+static inline void kobject_hotplug(const char *action, struct kobject *kobj) { }
+#endif
+
+
+#ifdef CONFIG_KOBJECT_UEVENT
+extern int kobject_uevent(const char *signal, struct kobject *kobj,
+ struct attribute *attr);
+
+extern int kobject_uevent_atomic(const char *signal, struct kobject *kobj,
+ struct attribute *attr);
+#else
+static inline int kobject_uevent(const char *signal, struct kobject *kobj,
+ struct attribute *attr)
+{
+ return 0;
+}
+
+static inline int kobject_uevent_atomic(const char *signal, struct kobject *kobj,
+ struct attribute *attr)
+{
+ return 0;
+}
+#endif
+
#endif /* __KERNEL__ */
#endif /* _KOBJECT_H_ */
diff --git a/include/linux/netlink.h b/include/linux/netlink.h
index 01864a8fd17f..e969de36edaa 100644
--- a/include/linux/netlink.h
+++ b/include/linux/netlink.h
@@ -17,6 +17,7 @@
#define NETLINK_ROUTE6 11 /* af_inet6 route comm channel */
#define NETLINK_IP6_FW 13
#define NETLINK_DNRTMSG 14 /* DECnet routing messages */
+#define NETLINK_KOBJECT_UEVENT 15 /* Kernel messages to userspace */
#define NETLINK_TAPBASE 16 /* 16 to 31 are ethertap */
#define MAX_LINKS 32