diff options
author | Wolfram Sang <w.sang@pengutronix.de> | 2010-03-13 14:56:55 -0500 |
---|---|---|
committer | Jean Delvare <khali@linux-fr.org> | 2010-03-13 14:56:55 -0500 |
commit | d07b56b3098b9f32ae6dedeacbc594bd01dcfcd1 (patch) | |
tree | 2adb2fa68fb23efa69e2e255a75858653d885047 /drivers/misc/eeprom/at24.c | |
parent | e77482d735efa2606c1f2afeebd53e1119d0e5c6 (diff) |
at24: Init dynamic bin_attribute structures
Commit 6992f5334995af474c2b58d010d08bc597f0f2fe introduced this requirement.
Reported-by: Albrecht Dress <albrecht.dress@arcor.de>
Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Diffstat (limited to 'drivers/misc/eeprom/at24.c')
-rw-r--r-- | drivers/misc/eeprom/at24.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/misc/eeprom/at24.c b/drivers/misc/eeprom/at24.c index 2cb2736d65aa..db7d0f21b65d 100644 --- a/drivers/misc/eeprom/at24.c +++ b/drivers/misc/eeprom/at24.c | |||
@@ -505,6 +505,7 @@ static int at24_probe(struct i2c_client *client, const struct i2c_device_id *id) | |||
505 | * Export the EEPROM bytes through sysfs, since that's convenient. | 505 | * Export the EEPROM bytes through sysfs, since that's convenient. |
506 | * By default, only root should see the data (maybe passwords etc) | 506 | * By default, only root should see the data (maybe passwords etc) |
507 | */ | 507 | */ |
508 | sysfs_bin_attr_init(&at24->bin); | ||
508 | at24->bin.attr.name = "eeprom"; | 509 | at24->bin.attr.name = "eeprom"; |
509 | at24->bin.attr.mode = chip.flags & AT24_FLAG_IRUGO ? S_IRUGO : S_IRUSR; | 510 | at24->bin.attr.mode = chip.flags & AT24_FLAG_IRUGO ? S_IRUGO : S_IRUSR; |
510 | at24->bin.read = at24_bin_read; | 511 | at24->bin.read = at24_bin_read; |