lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Wed, 8 Jun 2016 21:58:58 -0700 From: Eric Dumazet <edumazet@...gle.com> To: David Ahern <dsa@...ulusnetworks.com> Cc: "David S . Miller" <davem@...emloft.net>, netdev <netdev@...r.kernel.org>, Eric Dumazet <eric.dumazet@...il.com> Subject: Re: [PATCH v2 net-next 2/4] net: vrf: call netdev_lockdep_set_classes() On Wed, Jun 8, 2016 at 9:35 PM, David Ahern <dsa@...ulusnetworks.com> wrote: > >> On Jun 8, 2016, at 10:01 PM, Eric Dumazet <edumazet@...gle.com> wrote: >> >>> On Wed, Jun 8, 2016 at 8:41 PM, David Ahern <dsa@...ulusnetworks.com> wrote: >>>> On 6/8/16 9:29 PM, Eric Dumazet wrote: >>>> >>>> In case a qdisc is used on a vrf device, we need to use different >>>> lockdep classes to avoid false positives. >>>> >>>> Fixes: f9eb8aea2a1e ("net_sched: transform qdisc running bit into a >>>> seqcount") >>>> Reported-by: David Ahern <dsa@...ulusnetworks.com> >>>> Signed-off-by: Eric Dumazet <edumazet@...gle.com> >>> >>> >>> same result with this patch set. >> >> Are you stacking multiple vrf devices ? > > No. You can also look at ipvlan. It shows the same trace. For me it is 3 commands that create the vrf, add eth1, run ping. Okay, lockdep is hard ;) I will send a v3 after some sleep, adding the following : (I might have to add a new seqcount api instead of hard coding it) diff --git a/include/net/sch_generic.h b/include/net/sch_generic.h index c4f5749342ec..d53ecfc1d60e 100644 --- a/include/net/sch_generic.h +++ b/include/net/sch_generic.h @@ -104,7 +104,11 @@ static inline bool qdisc_run_begin(struct Qdisc *qdisc) { if (qdisc_is_running(qdisc)) return false; - write_seqcount_begin(&qdisc->running); + /* Variant of write_seqcount_begin() telling lockdep a trylock + * was attempted. + */ + raw_write_seqcount_begin(&qdisc->running); + seqcount_acquire(&qdisc->running.dep_map, 0, 1, _RET_IP_); return true; } diff --git a/net/sched/sch_generic.c b/net/sched/sch_generic.c index cebea73e70ac..cad810b45e31 100644 --- a/net/sched/sch_generic.c +++ b/net/sched/sch_generic.c @@ -137,10 +137,10 @@ int sch_direct_xmit(struct sk_buff *skb, struct Qdisc *q, HARD_TX_UNLOCK(dev, txq); } else { - spin_lock_nested(root_lock, SINGLE_DEPTH_NESTING); + spin_lock(root_lock); return qdisc_qlen(q); } - spin_lock_nested(root_lock, SINGLE_DEPTH_NESTING); + spin_lock(root_lock); if (dev_xmit_complete(ret)) { /* Driver sent out skb successfully or skb was consumed */
Powered by blists - more mailing lists