summaryrefslogtreecommitdiff
path: root/fs
diff options
context:
space:
mode:
authorPatrick Mochel <mochel@osdl.org>2002-07-30 06:43:13 -0700
committerPatrick Mochel <mochel@osdl.org>2002-07-30 06:43:13 -0700
commit3ffe04d886f663bd48cce815f77ff38e4d6fb061 (patch)
treebabe434f07f10813615a0d562c5c3746ce7c8f8c /fs
parenta9ae3e34951d8f719190ce50c991b3ec815c7d0d (diff)
driverfs: Change the name of struct driver_file_entry to struct device_attribute
It may seem gratuitous, but it's what we really want. driverfs files are meant to expose attributes of various kernel objects, so in that sense, the change adds more accurate meaning to the object. Plus, we will soon gain the ability to expose attributes of drivers (both device and bus) themselves, and we want to be able to have each mean something reasonable. This changes driverfs and the device model core (but none of the other users)
Diffstat (limited to 'fs')
-rw-r--r--fs/driverfs/inode.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/fs/driverfs/inode.c b/fs/driverfs/inode.c
index 08df41832bb1..f533eb2c45ea 100644
--- a/fs/driverfs/inode.c
+++ b/fs/driverfs/inode.c
@@ -266,7 +266,7 @@ static int driverfs_rmdir(struct inode *dir, struct dentry *dentry)
*
* Userspace wants data from a file. It is up to the creator of the file to
* provide that data.
- * There is a struct driver_file_entry embedded in file->private_data. We
+ * There is a struct device_attribute embedded in file->private_data. We
* obtain that and check if the read callback is implemented. If so, we call
* it, passing the data field of the file entry.
* Said callback is responsible for filling the buffer and returning the number
@@ -275,14 +275,14 @@ static int driverfs_rmdir(struct inode *dir, struct dentry *dentry)
static ssize_t
driverfs_read_file(struct file *file, char *buf, size_t count, loff_t *ppos)
{
- struct driver_file_entry * entry;
+ struct device_attribute * entry;
struct driver_dir_entry * dir;
unsigned char *page;
ssize_t retval = 0;
struct device * dev;
dir = file->f_dentry->d_parent->d_fsdata;
- entry = (struct driver_file_entry *)file->f_dentry->d_fsdata;
+ entry = (struct device_attribute *)file->f_dentry->d_fsdata;
if (!entry) {
DBG("%s: file entry is NULL\n",__FUNCTION__);
return -ENOENT;
@@ -341,7 +341,7 @@ driverfs_read_file(struct file *file, char *buf, size_t count, loff_t *ppos)
static ssize_t
driverfs_write_file(struct file *file, const char *buf, size_t count, loff_t *ppos)
{
- struct driver_file_entry * entry;
+ struct device_attribute * entry;
struct driver_dir_entry * dir;
struct device * dev;
ssize_t retval = 0;
@@ -349,7 +349,7 @@ driverfs_write_file(struct file *file, const char *buf, size_t count, loff_t *pp
dir = file->f_dentry->d_parent->d_fsdata;
- entry = (struct driver_file_entry *)file->f_dentry->d_fsdata;
+ entry = (struct device_attribute *)file->f_dentry->d_fsdata;
if (!entry) {
DBG("%s: file entry is NULL\n",__FUNCTION__);
return -ENOENT;
@@ -618,7 +618,7 @@ driverfs_create_dir(struct driver_dir_entry * entry,
* @parent: directory to create it in
*/
int
-driverfs_create_file(struct driver_file_entry * entry,
+driverfs_create_file(struct device_attribute * entry,
struct driver_dir_entry * parent)
{
struct dentry * dentry;