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
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Sat, 21 Nov 2020 11:06:16 +0800
From:   Yunsheng Lin <linyunsheng@...wei.com>
To:     <peterz@...radead.org>, <mingo@...hat.com>, <will@...nel.org>,
        <viro@...iv.linux.org.uk>, <kyk.segfault@...il.com>,
        <davem@...emloft.net>, <kuba@...nel.org>, <linmiaohe@...wei.com>,
        <martin.varghese@...ia.com>, <pabeni@...hat.com>,
        <pshelar@....org>, <fw@...len.de>, <gnault@...hat.com>,
        <steffen.klassert@...unet.com>, <vladimir.oltean@....com>,
        <edumazet@...gle.com>, <saeed@...nel.org>
CC:     <netdev@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
        <linuxarm@...wei.com>
Subject: [PATCH net-next v2 2/2] net: Use lockdep_assert_in_softirq() in napi_consume_skb()

Use napi_consume_skb() to assert the case when it is not called
in a atomic softirq context.

Signed-off-by: Yunsheng Lin <linyunsheng@...wei.com>
---
 net/core/skbuff.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/net/core/skbuff.c b/net/core/skbuff.c
index ffe3dcc..effa19d 100644
--- a/net/core/skbuff.c
+++ b/net/core/skbuff.c
@@ -902,6 +902,8 @@ void napi_consume_skb(struct sk_buff *skb, int budget)
 		return;
 	}
 
+	lockdep_assert_in_softirq();
+
 	if (!skb_unref(skb))
 		return;
 
-- 
2.8.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ