diff options
| author | Patrick Mochel <mochel@osdl.org> | 2002-07-31 00:08:54 -0700 |
|---|---|---|
| committer | Patrick Mochel <mochel@osdl.org> | 2002-07-31 00:08:54 -0700 |
| commit | 5509cd3616bf58dd82b62b0e350e09bbc75ccf21 (patch) | |
| tree | 1663d96e5dd071f615baecbbb1e570cb2b5bdca4 | |
| parent | 1ec13f9f598851af7e2c763cababa6f1df70a460 (diff) | |
driverfs:
make device_remove_file take a struct device_attribute *, instead of just
a char * (for consistency with device_create_file)
| -rw-r--r-- | drivers/base/fs.c | 5 | ||||
| -rw-r--r-- | include/linux/device.h | 2 |
2 files changed, 3 insertions, 4 deletions
diff --git a/drivers/base/fs.c b/drivers/base/fs.c index 4aa4938461e8..972d9433dcde 100644 --- a/drivers/base/fs.c +++ b/drivers/base/fs.c @@ -42,11 +42,11 @@ int device_create_file(struct device * dev, struct device_attribute * entry) * @name: name of the file * */ -void device_remove_file(struct device * dev, const char * name) +void device_remove_file(struct device * dev, struct device_attribute * attr) { if (dev) { get_device(dev); - driverfs_remove_file(&dev->dir,name); + driverfs_remove_file(&dev->dir,attr->name); put_device(dev); } } @@ -61,7 +61,6 @@ void device_remove_dir(struct device * dev) driverfs_remove_dir(&dev->dir); } - static int get_devpath_length(struct device * dev) { int length = 1; diff --git a/include/linux/device.h b/include/linux/device.h index 38048776fdd8..670be49d1718 100644 --- a/include/linux/device.h +++ b/include/linux/device.h @@ -180,7 +180,7 @@ g_list_to_dev(struct list_head *g_list) extern int device_register(struct device * dev); extern int device_create_file(struct device *device, struct device_attribute * entry); -extern void device_remove_file(struct device * dev, const char * name); +extern void device_remove_file(struct device * dev, struct device_attribute * attr); /* * Platform "fixup" functions - allow the platform to have their say |
