aboutsummaryrefslogtreecommitdiff
path: root/sys/compat/linuxkpi/common/include/linux/cdev.h
diff options
context:
space:
mode:
Diffstat (limited to 'sys/compat/linuxkpi/common/include/linux/cdev.h')
-rw-r--r--sys/compat/linuxkpi/common/include/linux/cdev.h13
1 files changed, 2 insertions, 11 deletions
diff --git a/sys/compat/linuxkpi/common/include/linux/cdev.h b/sys/compat/linuxkpi/common/include/linux/cdev.h
index fb7a3cf0b447..2befe9b259cb 100644
--- a/sys/compat/linuxkpi/common/include/linux/cdev.h
+++ b/sys/compat/linuxkpi/common/include/linux/cdev.h
@@ -57,6 +57,8 @@ struct linux_cdev {
u_int siref;
};
+struct linux_cdev *cdev_alloc(void);
+
static inline void
cdev_init(struct linux_cdev *cdev, const struct file_operations *ops)
{
@@ -66,17 +68,6 @@ cdev_init(struct linux_cdev *cdev, const struct file_operations *ops)
cdev->refs = 1;
}
-static inline struct linux_cdev *
-cdev_alloc(void)
-{
- struct linux_cdev *cdev;
-
- cdev = kzalloc(sizeof(struct linux_cdev), M_WAITOK);
- kobject_init(&cdev->kobj, &linux_cdev_ktype);
- cdev->refs = 1;
- return (cdev);
-}
-
static inline void
cdev_put(struct linux_cdev *p)
{