Skip to content

Commit

Permalink
hwmon: (adm1026) Properly terminate sysfs groups
Browse files Browse the repository at this point in the history
The missing NULL at the end of two sysfs file groups causes a kernel
crash when calling sysfs_create_group().

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
  • Loading branch information
Jean Delvare authored and Mark M. Hoffman committed Feb 17, 2008
1 parent af86576 commit 1d5f2c1
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/hwmon/adm1026.c
Original file line number Diff line number Diff line change
Expand Up @@ -1624,6 +1624,7 @@ static struct attribute *adm1026_attributes_temp3[] = {
&dev_attr_temp3_crit_enable.attr,
&dev_attr_temp3_auto_point1_pwm.attr,
&dev_attr_temp3_auto_point2_pwm.attr,
NULL
};

static const struct attribute_group adm1026_group_temp3 = {
Expand All @@ -1639,6 +1640,7 @@ static struct attribute *adm1026_attributes_in8_9[] = {
&sensor_dev_attr_in9_max.dev_attr.attr,
&sensor_dev_attr_in9_min.dev_attr.attr,
&sensor_dev_attr_in9_alarm.dev_attr.attr,
NULL
};

static const struct attribute_group adm1026_group_in8_9 = {
Expand Down

0 comments on commit 1d5f2c1

Please sign in to comment.