aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/raid/git:/git.zx2c4.com/ssh:/git@git.zx2c4.com
diff options
context:
space:
mode:
authorDan Carpenter <dan.carpenter@oracle.com>2022-07-08 16:46:38 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2022-07-14 16:53:19 +0200
commit71d46f1ff2212ced4852c7e77c5176382a1bdcec (patch)
tree9226c6185ec84a77f8ef44713a1ff4e714c68512 /include/linux/raid/git:/git.zx2c4.com/ssh:/git@git.zx2c4.com
parentMerge tag 'iio-for-5.20a' of https://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio into char-misc-next (diff)
downloadlinux-dev-71d46f1ff2212ced4852c7e77c5176382a1bdcec.tar.xz
linux-dev-71d46f1ff2212ced4852c7e77c5176382a1bdcec.zip
eeprom: idt_89hpesx: uninitialized data in idt_dbgfs_csr_write()
The simple_write_to_buffer() function will return positive/success if it is able to write a single byte anywhere within the buffer. However that potentially leaves a lot of the buffer uninitialized. In this code it's better to return 0 if the offset is non-zero. This code is not written to support partial writes. And then return -EFAULT if the buffer is not completely initialized. Fixes: cfad6425382e ("eeprom: Add IDT 89HPESx EEPROM/CSR driver") Reviewed-by: Serge Semin <fancer.lancer@gmail.com> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Link: https://lore.kernel.org/r/Ysg1Pu/nzSMe3r1q@kili Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/raid/git:/git.zx2c4.com/ssh:/git@git.zx2c4.com')
0 files changed, 0 insertions, 0 deletions