Changeset View
Changeset View
Standalone View
Standalone View
sys/fs/devfs/devfs_int.h
Show All 34 Lines | |||||
#ifndef _FS_DEVFS_DEVFS_INT_H_ | #ifndef _FS_DEVFS_DEVFS_INT_H_ | ||||
#define _FS_DEVFS_DEVFS_INT_H_ | #define _FS_DEVFS_DEVFS_INT_H_ | ||||
#include <sys/queue.h> | #include <sys/queue.h> | ||||
#ifdef _KERNEL | #ifdef _KERNEL | ||||
struct devfs_dirent; | struct devfs_dirent; | ||||
struct devfs_mount; | struct devfs_mount; | ||||
kib: Is that needed ? Even if it is, devfs_int.h is included in 5 or 6 files at all, so it is easy… | |||||
struct cdev_privdata { | struct cdev_privdata { | ||||
struct file *cdpd_fp; | struct file *cdpd_fp; | ||||
void *cdpd_data; | void *cdpd_data; | ||||
void (*cdpd_dtr)(void *); | void (*cdpd_dtr)(void *); | ||||
LIST_ENTRY(cdev_privdata) cdpd_list; | LIST_ENTRY(cdev_privdata) cdpd_list; | ||||
}; | }; | ||||
Show All 13 Lines | #define CDP_UNREF_DTR (1 << 2) | ||||
struct devfs_dirent **cdp_dirents; | struct devfs_dirent **cdp_dirents; | ||||
struct devfs_dirent *cdp_dirent0; | struct devfs_dirent *cdp_dirent0; | ||||
TAILQ_ENTRY(cdev_priv) cdp_dtr_list; | TAILQ_ENTRY(cdev_priv) cdp_dtr_list; | ||||
void (*cdp_dtr_cb)(void *); | void (*cdp_dtr_cb)(void *); | ||||
void *cdp_dtr_cb_arg; | void *cdp_dtr_cb_arg; | ||||
LIST_HEAD(, cdev_privdata) cdp_fdpriv; | LIST_HEAD(, cdev_privdata) cdp_fdpriv; | ||||
struct mtx cdp_threadlock; | |||||
}; | }; | ||||
#define cdev2priv(c) __containerof(c, struct cdev_priv, cdp_c) | #define cdev2priv(c) __containerof(c, struct cdev_priv, cdp_c) | ||||
struct cdev *devfs_alloc(int); | struct cdev *devfs_alloc(int); | ||||
int devfs_dev_exists(const char *); | int devfs_dev_exists(const char *); | ||||
void devfs_free(struct cdev *); | void devfs_free(struct cdev *); | ||||
void devfs_create(struct cdev *); | void devfs_create(struct cdev *); | ||||
Show All 18 Lines |
Is that needed ? Even if it is, devfs_int.h is included in 5 or 6 files at all, so it is easy to arrange sys/mutex.h before it in .c files.