misc: eeprom: at24: clean up at24_bin_write()
The change removes redundant sysfs binary file boundary check, since this task is already done on caller side in fs/sysfs/file.c Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
This commit is contained in:
parent
1f023297f7
commit
d12c0aaf37
@ -438,9 +438,6 @@ static ssize_t at24_bin_write(struct file *filp, struct kobject *kobj,
|
|||||||
{
|
{
|
||||||
struct at24_data *at24;
|
struct at24_data *at24;
|
||||||
|
|
||||||
if (unlikely(off >= attr->size))
|
|
||||||
return -EFBIG;
|
|
||||||
|
|
||||||
at24 = dev_get_drvdata(container_of(kobj, struct device, kobj));
|
at24 = dev_get_drvdata(container_of(kobj, struct device, kobj));
|
||||||
return at24_write(at24, buf, off, count);
|
return at24_write(at24, buf, off, count);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user