From: David Miller <davem@davemloft.net>
To: gregory.herrero@intel.com
Cc: netdev@vger.kernel.org, kuznet@ms2.inr.ac.ru, jmorris@namei.org,
yoshfuji@linux-ipv6.org, kaber@trash.net,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] ipv6: release idev lock before calling ipv6_ifa_notify()
Date: Fri, 29 Jan 2016 17:43:03 -0800 (PST) [thread overview]
Message-ID: <20160129.174303.663518084694618919.davem@davemloft.net> (raw)
In-Reply-To: <1453970092-10605-1-git-send-email-gregory.herrero@intel.com>
From: Gregory Herrero <gregory.herrero@intel.com>
Date: Thu, 28 Jan 2016 09:34:52 +0100
> @@ -2302,8 +2302,11 @@ static void manage_tempaddrs(struct inet6_dev *idev,
> ift->flags &= ~IFA_F_DEPRECATED;
>
> spin_unlock(&ift->lock);
> - if (!(flags&IFA_F_TENTATIVE))
> + if (!(flags & IFA_F_TENTATIVE)) {
> + read_unlock_bh(&idev->lock);
> ipv6_ifa_notify(0, ift);
> + read_lock_bh(&idev->lock);
> + }
> }
>
> if ((create || list_empty(&idev->tempaddr_list)) &&
You can't do this, the idev->lock has to be held to keep the list we
are iterating over from changing.
prev parent reply other threads:[~2016-01-30 1:43 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-28 8:34 Gregory Herrero
2016-01-30 1:43 ` David Miller [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160129.174303.663518084694618919.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=gregory.herrero@intel.com \
--cc=jmorris@namei.org \
--cc=kaber@trash.net \
--cc=kuznet@ms2.inr.ac.ru \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=yoshfuji@linux-ipv6.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®