linux/drivers/misc/mchp_pci1xxxx
Joy Chakraborty a6a0f04e7d misc: microchip: pci1xxxx: Fix return value of nvmem callbacks
Read/write callbacks registered with nvmem core expect 0 to be returned
on success and a negative value to be returned on failure.

Currently pci1xxxx_otp_read()/pci1xxxx_otp_write() and
pci1xxxx_eeprom_read()/pci1xxxx_eeprom_write() return the number of
bytes read/written on success.
Fix to return 0 on success.

Fixes: 9ab5465349 ("misc: microchip: pci1xxxx: Add support to read and write into PCI1XXXX EEPROM via NVMEM sysfs")
Fixes: 0969001569 ("misc: microchip: pci1xxxx: Add support to read and write into PCI1XXXX OTP via NVMEM sysfs")
Cc: stable@vger.kernel.org
Signed-off-by: Joy Chakraborty <joychakr@google.com>
Reviewed-by: Dan Carpenter <dan.carpenter@linaro.org>
Link: https://lore.kernel.org/r/20240612070031.1215558-1-joychakr@google.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-07-03 16:37:33 +02:00
..
Kconfig misc: microchip: pci1xxxx: Add support to read and write into PCI1XXXX OTP via NVMEM sysfs 2023-08-04 15:36:43 +02:00
Makefile misc: microchip: pci1xxxx: Add support to read and write into PCI1XXXX OTP via NVMEM sysfs 2023-08-04 15:36:43 +02:00
mchp_pci1xxxx_gp.c misc: microchip: pci1xxxx: Fix a memory leak in the error handling of gp_aux_bus_probe() 2024-06-04 18:08:39 +02:00
mchp_pci1xxxx_gp.h
mchp_pci1xxxx_gpio.c misc: microchip: pci1xxxx: Convert to immutable irqchip 2023-03-09 18:07:29 +01:00
mchp_pci1xxxx_otpe2p.c misc: microchip: pci1xxxx: Fix return value of nvmem callbacks 2024-07-03 16:37:33 +02:00