summaryrefslogtreecommitdiffstats
path: root/drivers/edac
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@redhat.com>2009-09-24 09:59:13 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2010-05-10 11:45:00 -0300
commit4253868034221db6e42dbbb61e0305fe1757f8da (patch)
tree16b9da2b1bdaac195e1b273b2902a764b5b3b96e /drivers/edac
parent22e6bcbdcf9279321dbe646c5a234b816db12881 (diff)
downloadtalos-op-linux-4253868034221db6e42dbbb61e0305fe1757f8da.tar.gz
talos-op-linux-4253868034221db6e42dbbb61e0305fe1757f8da.zip
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')
-rw-r--r--drivers/edac/i7core_edac.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/edac/i7core_edac.c b/drivers/edac/i7core_edac.c
index c3fec5de3e51..2e4b0abf9d43 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[] = {
.show = i7core_ce_regs_show,
.store = NULL,
},
+ { .attr = { .name = NULL } }
};
/****************************************************************************
@@ -1155,9 +1156,9 @@ static void i7core_put_devices(struct i7core_dev *i7core_dev)
static void i7core_put_all_devices(void)
{
- struct i7core_dev *i7core_dev;
+ struct i7core_dev *i7core_dev, *tmp;
- list_for_each_entry(i7core_dev, &i7core_edac_list, list)
+ list_for_each_entry_safe(i7core_dev, tmp, &i7core_edac_list, list)
i7core_put_devices(i7core_dev);
}
OpenPOWER on IntegriCloud