From: igorm@etf.rs
To: netdev@vger.kernel.org
Cc: Igor Maravic <igorm@etf.rs>
Subject: [PATCH] Fix skb_update_prio
Date: Fri, 25 Nov 2011 18:44:54 +0100 [thread overview]
Message-ID: <1322243094-10420-2-git-send-email-igorm@etf.rs> (raw)
In-Reply-To: <1322243094-10420-1-git-send-email-igorm@etf.rs>
From: Igor Maravic <igorm@etf.rs>
Change function rcu_dereference to rcu_dereference_bh to avoid warning
[ INFO: suspicious RCU usage. ]
-------------------------------
net/core/dev.c:2459 suspicious rcu_dereference_check() usage!
because we are locking with
rcu_read_lock_bh();
in function dev_queue_xmit(struct sk_buff *skb)
Signed-off-by: Igor Maravic <igorm@etf.rs>
---
net/core/dev.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/net/core/dev.c b/net/core/dev.c
index 8afb244..d1f1071 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -2452,7 +2452,7 @@ static inline int __dev_xmit_skb(struct sk_buff *skb, struct Qdisc *q,
#if IS_ENABLED(CONFIG_NETPRIO_CGROUP)
static void skb_update_prio(struct sk_buff *skb)
{
- struct netprio_map *map = rcu_dereference(skb->dev->priomap);
+ struct netprio_map *map = rcu_dereference_bh(skb->dev->priomap);
if ((!skb->priority) && (skb->sk) && map)
skb->priority = map->priomap[skb->sk->sk_cgrp_prioidx];
--
1.7.5.4
next prev parent reply other threads:[~2011-11-25 17:45 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-25 17:44 [PATCH] Fix skb_update_prio igorm
2011-11-25 17:44 ` igorm [this message]
2011-11-29 23:25 ` David Miller
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=1322243094-10420-2-git-send-email-igorm@etf.rs \
--to=igorm@etf.rs \
--cc=netdev@vger.kernel.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