Gitweb: http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=d8fae9c2f2642ffe411424ed2e4677f959168152 Commit: d8fae9c2f2642ffe411424ed2e4677f959168152 Parent: 6570ebc4f57ad0761104f769576ae5652d9b8d64 Author: Ursula Braun <[EMAIL PROTECTED]> AuthorDate: Fri Oct 5 16:45:46 2007 +0200 Committer: David S. Miller <[EMAIL PROTECTED]> CommitDate: Wed Oct 10 16:54:41 2007 -0700
qeth: avoid duplicate deletion of multicast addresses if qeth_set_multicast_list() is performed on 2 CPUs in parallel, card->ip_list may end corrupted. Solution: In function __qeth_delete_all_mc() remove card->ip_list entry before invoking qeth_deregister_addr_entry(). Thus a 2nd invocation of qeth_set_multicast_list() cannot try to remove the same entry twice. Signed-off-by Ursula Braun <[EMAIL PROTECTED]> Signed-off-by: Jeff Garzik <[EMAIL PROTECTED]> --- drivers/s390/net/qeth_main.c | 5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/s390/net/qeth_main.c b/drivers/s390/net/qeth_main.c index fe61647..6d7b79e 100644 --- a/drivers/s390/net/qeth_main.c +++ b/drivers/s390/net/qeth_main.c @@ -823,14 +823,15 @@ __qeth_delete_all_mc(struct qeth_card *card, unsigned long *flags) again: list_for_each_entry_safe(addr, tmp, &card->ip_list, entry) { if (addr->is_multicast) { + list_del(&addr->entry); spin_unlock_irqrestore(&card->ip_lock, *flags); rc = qeth_deregister_addr_entry(card, addr); spin_lock_irqsave(&card->ip_lock, *flags); if (!rc) { - list_del(&addr->entry); kfree(addr); goto again; - } + } else + list_add(&addr->entry, &card->ip_list); } } } - To unsubscribe from this list: send the line "unsubscribe git-commits-head" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html