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]
Message-ID: <20250520203614.2693870-2-stfomichev@gmail.com>
Date: Tue, 20 May 2025 13:36:12 -0700
From: Stanislav Fomichev <stfomichev@...il.com>
To: netdev@...r.kernel.org
Cc: davem@...emloft.net,
	edumazet@...gle.com,
	kuba@...nel.org,
	pabeni@...hat.com,
	skalluru@...vell.com,
	manishc@...vell.com,
	andrew+netdev@...n.ch,
	michael.chan@...adcom.com,
	pavan.chebbi@...adcom.com,
	ajit.khaparde@...adcom.com,
	sriharsha.basavapatna@...adcom.com,
	somnath.kotur@...adcom.com,
	anthony.l.nguyen@...el.com,
	przemyslaw.kitszel@...el.com,
	tariqt@...dia.com,
	saeedm@...dia.com,
	louis.peens@...igine.com,
	shshaikh@...vell.com,
	GR-Linux-NIC-Dev@...vell.com,
	ecree.xilinx@...il.com,
	horms@...nel.org,
	dsahern@...nel.org,
	ruanjinjie@...wei.com,
	mheib@...hat.com,
	stfomichev@...il.com,
	linux-kernel@...r.kernel.org,
	intel-wired-lan@...ts.osuosl.org,
	linux-rdma@...r.kernel.org,
	oss-drivers@...igine.com,
	linux-net-drivers@....com,
	leon@...nel.org
Subject: [PATCH net-next 1/3] net: ASSERT_RTNL remove netif_set_real_num_{rx,tx}_queues

Existing netdev_ops_assert_locked takes care of asserting either
netdev lock or RTNL.

Cc: Michael Chan <michael.chan@...adcom.com>
Signed-off-by: Stanislav Fomichev <stfomichev@...il.com>
---
 net/core/dev.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/net/core/dev.c b/net/core/dev.c
index fccf2167b235..5ea718036921 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -3179,7 +3179,6 @@ int netif_set_real_num_tx_queues(struct net_device *dev, unsigned int txq)
 
 	if (dev->reg_state == NETREG_REGISTERED ||
 	    dev->reg_state == NETREG_UNREGISTERING) {
-		ASSERT_RTNL();
 		netdev_ops_assert_locked(dev);
 
 		rc = netdev_queue_update_kobjects(dev, dev->real_num_tx_queues,
@@ -3229,7 +3228,6 @@ int netif_set_real_num_rx_queues(struct net_device *dev, unsigned int rxq)
 		return -EINVAL;
 
 	if (dev->reg_state == NETREG_REGISTERED) {
-		ASSERT_RTNL();
 		netdev_ops_assert_locked(dev);
 
 		rc = net_rx_queue_update_kobjects(dev, dev->real_num_rx_queues,
-- 
2.49.0


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ