summaryrefslogtreecommitdiff
path: root/include/linux/kobject.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/kobject.h')
-rw-r--r--include/linux/kobject.h30
1 files changed, 30 insertions, 0 deletions
diff --git a/include/linux/kobject.h b/include/linux/kobject.h
new file mode 100644
index 000000000000..12431a980712
--- /dev/null
+++ b/include/linux/kobject.h
@@ -0,0 +1,30 @@
+/*
+ * kobject.h - generic kernel object infrastructure.
+ *
+ */
+
+#ifndef _KOBJECT_H_
+#define _KOBJECT_H_
+
+#include <linux/types.h>
+#include <linux/list.h>
+#include <linux/sysfs.h>
+#include <asm/atomic.h>
+
+struct kobject {
+ char name[16];
+ atomic_t refcount;
+ struct list_head entry;
+ struct kobject * parent;
+ struct sysfs_dir dir;
+};
+
+extern void kobject_init(struct kobject *);
+
+extern int kobject_register(struct kobject *);
+extern void kobject_unregister(struct kobject *);
+
+extern struct kobject * kobject_get(struct kobject *);
+extern void kobject_put(struct kobject *);
+
+#endif /* _KOBJECT_H_ */