Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

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>

authored by

Wolfram Sang and committed by
Jean Delvare
d07b56b3 e77482d7

+1
+1
drivers/misc/eeprom/at24.c
··· 505 505 * Export the EEPROM bytes through sysfs, since that's convenient. 506 506 * By default, only root should see the data (maybe passwords etc) 507 507 */ 508 + sysfs_bin_attr_init(&at24->bin); 508 509 at24->bin.attr.name = "eeprom"; 509 510 at24->bin.attr.mode = chip.flags & AT24_FLAG_IRUGO ? S_IRUGO : S_IRUSR; 510 511 at24->bin.read = at24_bin_read;