[PATCH 22/31] hwmon: (pmbus/mp5920) use 4-argument i2c_smbus_read_block_data()
From: Dmitry Torokhov
Date: Sat Oct 24 2026 - 23:12:41 EST
Pass the size of the receive buffer to i2c_smbus_read_block_data() in
mp5920_probe().
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@xxxxxxxxx>
---
drivers/hwmon/pmbus/mp5920.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/hwmon/pmbus/mp5920.c b/drivers/hwmon/pmbus/mp5920.c
index b803f3ddf8ea..5c61b3c610d1 100644
--- a/drivers/hwmon/pmbus/mp5920.c
+++ b/drivers/hwmon/pmbus/mp5920.c
@@ -46,7 +46,8 @@ static int mp5920_probe(struct i2c_client *client)
I2C_FUNC_SMBUS_READ_WORD_DATA))
return -ENODEV;
- ret = i2c_smbus_read_block_data(client, PMBUS_MFR_MODEL, buf);
+ ret = i2c_smbus_read_block_data(client, PMBUS_MFR_MODEL,
+ sizeof(buf), buf);
if (ret < 0)
return dev_err_probe(dev, ret, "Failed to read PMBUS_MFR_MODEL\n");
--
2.56.0.257.gf7497c7d27-goog