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-next>] [day] [month] [year] [list]
Message-Id: <20240715024457.3743560-1-nichen@iscas.ac.cn>
Date: Mon, 15 Jul 2024 10:44:57 +0800
From: Chen Ni <nichen@...as.ac.cn>
To: roopa@...dia.com,
	razor@...ckwall.org,
	davem@...emloft.net,
	edumazet@...gle.com,
	kuba@...nel.org,
	pabeni@...hat.com
Cc: bridge@...ts.linux.dev,
	netdev@...r.kernel.org,
	linux-kernel@...r.kernel.org,
	Chen Ni <nichen@...as.ac.cn>
Subject: [PATCH] net: bridge: remove unnecessary cast from netdev_priv()

Remove unnecessary cast of void * returned by netdev_priv().

Fixes: 928990631327 ("net: bridge: add notifications for the bridge dev on vlan change")
Signed-off-by: Chen Ni <nichen@...as.ac.cn>
---
 net/bridge/br_netlink.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/net/bridge/br_netlink.c b/net/bridge/br_netlink.c
index f17dbac7d828..d02cc1497281 100644
--- a/net/bridge/br_netlink.c
+++ b/net/bridge/br_netlink.c
@@ -1085,7 +1085,7 @@ static int br_setport(struct net_bridge_port *p, struct nlattr *tb[],
 int br_setlink(struct net_device *dev, struct nlmsghdr *nlh, u16 flags,
 	       struct netlink_ext_ack *extack)
 {
-	struct net_bridge *br = (struct net_bridge *)netdev_priv(dev);
+	struct net_bridge *br = netdev_priv(dev);
 	struct nlattr *tb[IFLA_BRPORT_MAX + 1];
 	struct net_bridge_port *p;
 	struct nlattr *protinfo;
@@ -1143,7 +1143,7 @@ int br_setlink(struct net_device *dev, struct nlmsghdr *nlh, u16 flags,
 /* Delete port information */
 int br_dellink(struct net_device *dev, struct nlmsghdr *nlh, u16 flags)
 {
-	struct net_bridge *br = (struct net_bridge *)netdev_priv(dev);
+	struct net_bridge *br = netdev_priv(dev);
 	struct net_bridge_port *p;
 	struct nlattr *afspec;
 	bool changed = false;
-- 
2.25.1


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ