diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-09-24 08:59:13 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2010-05-10 10:45:00 -0400 |
commit | 4253868034221db6e42dbbb61e0305fe1757f8da (patch) | |
tree | 16b9da2b1bdaac195e1b273b2902a764b5b3b96e /drivers/edac/i7core_edac.c | |
parent | 22e6bcbdcf9279321dbe646c5a234b816db12881 (diff) |
i7core_edac: We need to use list_for_each_entry_safe to avoid errors
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/edac/i7core_edac.c')
-rw-r--r-- | drivers/edac/i7core_edac.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/edac/i7core_edac.c b/drivers/edac/i7core_edac.c index c3fec5de3e5..2e4b0abf9d4 100644 --- a/drivers/edac/i7core_edac.c +++ b/drivers/edac/i7core_edac.c | |||
@@ -1124,6 +1124,7 @@ static struct mcidev_sysfs_attribute i7core_inj_attrs[] = { | |||
1124 | .show = i7core_ce_regs_show, | 1124 | .show = i7core_ce_regs_show, |
1125 | .store = NULL, | 1125 | .store = NULL, |
1126 | }, | 1126 | }, |
1127 | { .attr = { .name = NULL } } | ||
1127 | }; | 1128 | }; |
1128 | 1129 | ||
1129 | /**************************************************************************** | 1130 | /**************************************************************************** |
@@ -1155,9 +1156,9 @@ static void i7core_put_devices(struct i7core_dev *i7core_dev) | |||
1155 | 1156 | ||
1156 | static void i7core_put_all_devices(void) | 1157 | static void i7core_put_all_devices(void) |
1157 | { | 1158 | { |
1158 | struct i7core_dev *i7core_dev; | 1159 | struct i7core_dev *i7core_dev, *tmp; |
1159 | 1160 | ||
1160 | list_for_each_entry(i7core_dev, &i7core_edac_list, list) | 1161 | list_for_each_entry_safe(i7core_dev, tmp, &i7core_edac_list, list) |
1161 | i7core_put_devices(i7core_dev); | 1162 | i7core_put_devices(i7core_dev); |
1162 | } | 1163 | } |
1163 | 1164 | ||