summaryrefslogtreecommitdiffstats
path: root/drivers/input/gameport/ns558.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/input/gameport/ns558.c')
-rw-r--r--drivers/input/gameport/ns558.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/input/gameport/ns558.c b/drivers/input/gameport/ns558.c
index 1ab5f2dc8a2..70f051894a3 100644
--- a/drivers/input/gameport/ns558.c
+++ b/drivers/input/gameport/ns558.c
@@ -275,9 +275,9 @@ static int __init ns558_init(void)
static void __exit ns558_exit(void)
{
- struct ns558 *ns558;
+ struct ns558 *ns558, *safe;
- list_for_each_entry(ns558, &ns558_list, node) {
+ list_for_each_entry_safe(ns558, safe, &ns558_list, node) {
gameport_unregister_port(ns558->gameport);
release_region(ns558->io & ~(ns558->size - 1), ns558->size);
kfree(ns558);