WSL2-Linux-Kernel/drivers/hwmon
David Arcari 84e261553e hwmon: (amd_energy) fix allocation of hwmon_channel_info config
hwmon, specifically hwmon_num_channel_attrs, expects the config
array in the hwmon_channel_info structure to be terminated by
a zero entry.  amd_energy does not honor this convention.  As
result, a KASAN warning is possible.  Fix this by adding an
additional entry and setting it to zero.

Fixes: 8abee9566b ("hwmon: Add amd_energy driver to report energy counters")

Signed-off-by: David Arcari <darcari@redhat.com>
Cc: Naveen Krishna Chatradhi <nchatrad@amd.com>
Cc: Jean Delvare <jdelvare@suse.com>
Cc: Guenter Roeck <linux@roeck-us.net>
Cc: linux-kernel@vger.kernel.org
Cc: stable@vger.kernel.org
Signed-off-by: David Arcari <darcari@redhat.com>
Acked-by: Naveen Krishna Chatradhi <nchatrad@amd.com>
Link: https://lore.kernel.org/r/20210107144707.6927-1-darcari@redhat.com
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2021-01-08 07:31:03 -08:00
..
occ hwmon: (occ) Add new temperature sensor type 2020-12-11 07:42:27 -08:00
pmbus hwmon: (pmbus) Driver for Delta power supplies Q54SJ108A2 2020-12-11 07:41:20 -08:00
Kconfig hwmon: (sbtsi) Add basic support for SB-TSI sensors 2020-12-12 08:32:35 -08:00
Makefile hwmon: (sbtsi) Add basic support for SB-TSI sensors 2020-12-12 08:32:35 -08:00
ab8500.c
abituguru.c
abituguru3.c
abx500.c hwmon: (abx500) Switch to using the new API kobj_to_dev() 2020-12-02 17:42:24 -08:00
abx500.h
acpi_power_meter.c hwmon: (acpi_power_meter) clean up freeing code 2020-12-02 17:42:22 -08:00
ad7314.c
ad7414.c
ad7418.c
adc128d818.c
adcxx.c
adm1021.c
adm1025.c
adm1026.c
adm1029.c
adm1031.c
adm1177.c hwmon: (adm1177) Fix kerneldoc attribute formatting 2020-12-02 17:42:23 -08:00
adm9240.c
ads7828.c
ads7871.c
adt7x10.c
adt7x10.h
adt7310.c
adt7410.c
adt7411.c
adt7462.c
adt7470.c hwmon: (adt7470) Create functions for updating readings and limits 2020-12-02 17:42:23 -08:00
adt7475.c
amc6821.c
amd_energy.c hwmon: (amd_energy) fix allocation of hwmon_channel_info config 2021-01-08 07:31:03 -08:00
applesmc.c hwmon: (applesmc) Add DMI product matches for Intel-based Xserves (non-RackMac*) 2020-12-02 17:42:24 -08:00
as370-hwmon.c
asb100.c
asc7621.c
aspeed-pwm-tacho.c
asus_atk0110.c
atxp1.c
axi-fan-control.c
bt1-pvt.c
bt1-pvt.h
coretemp.c
corsair-cpro.c
corsair-psu.c hwmon: (corsair-psu) Fix fan rpm calculation 2020-12-02 17:42:23 -08:00
da9052-hwmon.c
da9055-hwmon.c
dell-smm-hwmon.c
dme1737.c
drivetemp.c hwmon: drivetemp: fix typo temperatire => temperature 2020-12-02 17:42:23 -08:00
ds620.c
ds1621.c
emc6w201.c
emc1403.c
emc2103.c
f71805f.c
f71882fg.c
f75375s.c
fam15h_power.c
fschmd.c
ftsteutates.c
g760a.c
g762.c
gl518sm.c
gl520sm.c
gpio-fan.c
gsc-hwmon.c
hih6130.c
hwmon-vid.c
hwmon.c
i5k_amb.c
i5500_temp.c
ibmaem.c
ibmpex.c
ibmpowernv.c hwmon: (ibmpowernv) Silence strncpy() warning 2020-12-02 17:42:23 -08:00
iio_hwmon.c hwmon: (iio_hwmon) Drop bogus __refdata annotation 2020-12-11 07:42:27 -08:00
ina2xx.c
ina209.c
ina3221.c hwmon: (ina3221) Demote seemingly unintentional kerneldoc header 2020-12-02 17:42:23 -08:00
intel-m10-bmc-hwmon.c
it87.c
jc42.c
k8temp.c
k10temp.c hwmon: (k10temp) Remove support for displaying voltage and current on Zen CPUs 2020-12-22 08:18:36 -08:00
lineage-pem.c
lm63.c
lm70.c
lm73.c
lm75.c
lm75.h
lm77.c
lm78.c
lm80.c
lm83.c
lm85.c
lm87.c
lm90.c
lm92.c
lm93.c
lm95234.c
lm95241.c
lm95245.c
lochnagar-hwmon.c
ltc2945.c
ltc2947-core.c
ltc2947-i2c.c
ltc2947-spi.c
ltc2947.h
ltc2990.c
ltc2992.c hwmon: (ltc2992) Fix less than zero comparisons with an unsigned integer 2020-12-11 07:42:27 -08:00
ltc4151.c
ltc4215.c
ltc4222.c
ltc4245.c
ltc4260.c
ltc4261.c
ltq-cputemp.c
max127.c hwmon: (max127) Add Maxim MAX127 hardware monitoring driver 2020-12-02 17:42:24 -08:00
max197.c
max1111.c
max1619.c
max1668.c
max6621.c
max6639.c
max6642.c
max6650.c
max6697.c
max16065.c
max31722.c
max31730.c
max31790.c
mc13783-adc.c
mcp3021.c
menf21bmc_hwmon.c
mlxreg-fan.c
mr75203.c
nct6683.c hwmon: (nct6683) Support NCT6687D. 2020-12-02 17:42:24 -08:00
nct6775.c
nct7802.c
nct7904.c
npcm750-pwm-fan.c
nsa320-hwmon.c
ntc_thermistor.c
pc87360.c
pc87427.c
pcf8591.c
powr1220.c
pwm-fan.c hwmon: (pwm-fan) Ensure that calculation doesn't discard big period values 2020-12-30 08:21:04 -08:00
raspberrypi-hwmon.c
s3c-hwmon.c
sbtsi_temp.c hwmon: (sbtsi) Add basic support for SB-TSI sensors 2020-12-12 08:32:35 -08:00
sch56xx-common.c
sch56xx-common.h
sch5627.c
sch5636.c
scmi-hwmon.c
scpi-hwmon.c
sht3x.c
sht15.c
sht21.c
shtc1.c
sis5595.c
sl28cpld-hwmon.c
smm665.c
smsc47b397.c
smsc47m1.c
smsc47m192.c
sparx5-temp.c
stts751.c
tc74.c
tc654.c
thmc50.c
tmp102.c
tmp103.c
tmp108.c
tmp401.c
tmp421.c
tmp513.c
ultra45_env.c
vexpress-hwmon.c
via-cputemp.c
via686a.c
vt1211.c
vt8231.c
w83l785ts.c
w83l786ng.c
w83627ehf.c
w83627hf.c
w83773g.c
w83781d.c
w83791d.c
w83792d.c
w83793.c
w83795.c
wm831x-hwmon.c
wm8350-hwmon.c
xgene-hwmon.c hwmon: (xgene) Drop bogus __refdata annotation 2020-12-11 07:42:27 -08:00