Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

hwmon: (raspberrypi) Use generic notification mechanism

Use hwmon_notify_event() to make the code easier to
understand and to also generate udev events.

Signed-off-by: Armin Wolf <W_Armin@gmx.de>
Link: https://lore.kernel.org/r/20210905190049.11381-1-W_Armin@gmx.de
Signed-off-by: Guenter Roeck <linux@roeck-us.net>

authored by

Armin Wolf and committed by
Guenter Roeck
d73287ee 6665e10a

+1 -1
+1 -1
drivers/hwmon/raspberrypi-hwmon.c
··· 53 53 else 54 54 dev_info(data->hwmon_dev, "Voltage normalised\n"); 55 55 56 - sysfs_notify(&data->hwmon_dev->kobj, NULL, "in0_lcrit_alarm"); 56 + hwmon_notify_event(data->hwmon_dev, hwmon_in, hwmon_in_lcrit_alarm, 0); 57 57 } 58 58 59 59 static void get_values_poll(struct work_struct *work)