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 for Android: free password hash cracker in your pocket
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250825135749.299534-1-mheib@redhat.com>
Date: Mon, 25 Aug 2025 16:57:49 +0300
From: mheib@...hat.com
To: netdev@...r.kernel.org
Cc: ecree.xilinx@...il.com,
	Mohammad Heib <mheib@...hat.com>
Subject: [PATCH net] sfc: remove ASSERT_RTNL() from get_ts_info function

From: Mohammad Heib <mheib@...hat.com>

The SFC driver currently asserts that the RTNL lock is held in
efx_ptp_get_ts_info() using ASSERT_RTNL(). While this is correct for
the ethtool ioctl path, this function can also be called from the
SO_TIMESTAMPING socket path where RTNL is not held, which triggers
kernel BUGs in debug builds.

This patch removes the ASSERT_RTNL() to avoid these assertions in
kernel logs when called from paths that do not hold RTNL.

Signed-off-by: Mohammad Heib <mheib@...hat.com>
---
 drivers/net/ethernet/sfc/ptp.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/net/ethernet/sfc/ptp.c b/drivers/net/ethernet/sfc/ptp.c
index 4c7222bf26be..7d37d1d18f27 100644
--- a/drivers/net/ethernet/sfc/ptp.c
+++ b/drivers/net/ethernet/sfc/ptp.c
@@ -1864,8 +1864,6 @@ void efx_ptp_get_ts_info(struct efx_nic *efx, struct kernel_ethtool_ts_info *ts_
 	struct efx_ptp_data *ptp = efx->ptp_data;
 	struct efx_nic *primary = efx->primary;
 
-	ASSERT_RTNL();
-
 	if (!ptp)
 		return;
 
-- 
2.50.1


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ