diff options
| author | Cristian Marussi <[email protected]> | 2020-07-15 12:13:38 +0000 |
|---|---|---|
| committer | Guenter Roeck <[email protected]> | 2020-07-15 14:08:21 +0000 |
| commit | 3ce17cd2b94907f6d91b81b32848044b84c97606 (patch) | |
| tree | b1675d892be202559a65314c4cc4d8edcd52cf3b /drivers/usb/cdns3/cdns3-pci-wrap.c | |
| parent | hwmon: (nct6775) Accept PECI Calibration as temperature source for NCT6798D (diff) | |
| download | kernel-3ce17cd2b94907f6d91b81b32848044b84c97606.tar.gz kernel-3ce17cd2b94907f6d91b81b32848044b84c97606.zip | |
hwmon: (scmi) Fix potential buffer overflow in scmi_hwmon_probe()
SMATCH detected a potential buffer overflow in the manipulation of
hwmon_attributes array inside the scmi_hwmon_probe function:
drivers/hwmon/scmi-hwmon.c:226
scmi_hwmon_probe() error: buffer overflow 'hwmon_attributes' 6 <= 9
Fix it by statically declaring the size of the array as the maximum
possible as defined by hwmon_max define.
Signed-off-by: Cristian Marussi <[email protected]>
Reviewed-by: Sudeep Holla <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Guenter Roeck <[email protected]>
Diffstat (limited to 'drivers/usb/cdns3/cdns3-pci-wrap.c')
0 files changed, 0 insertions, 0 deletions
