commit | 748a7295d7242bc1aaaec0e245cc61f2be754766 | [log] [tgz] |
---|---|---|
author | Vladimir Zapolskiy <vz@mleia.com> | Tue May 26 03:50:04 2015 +0300 |
committer | David S. Miller <davem@davemloft.net> | Wed May 27 00:25:33 2015 -0400 |
tree | 161b2291bb05f5b0b3fd4e3339525665badbbfb2 | |
parent | 082739aa458a74add9a2362988e5aca0367bfa53 [diff] |
net: netxen: correct sysfs bin attribute return code If read() syscall requests unexpected number of bytes from "dimm" binary attribute file, return EINVAL instead of EPERM. At the same time pin down sysfs file size to the fixed sizeof(struct netxen_dimm_cfg), which allows to exploit some missing sanity checks from kernfs (file boundary checks vs offset etc.) Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: David S. Miller <davem@davemloft.net>