[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20221208090940.3695670-1-yebin@huaweicloud.com>
Date: Thu, 8 Dec 2022 17:09:40 +0800
From: Ye Bin <yebin@...weicloud.com>
To: socketcan@...tkopp.net, mkl@...gutronix.de, davem@...emloft.net,
edumazet@...gle.com, kuba@...nel.org, pabeni@...hat.com,
linux-can@...r.kernel.org, netdev@...r.kernel.org
Cc: yebin10@...wei.com
Subject: [PATCH net-next] net: af_can: remove useless parameter 'err' in 'can_rx_register()'
From: Ye Bin <yebin10@...wei.com>
Since commit bdfb5765e45b remove NULL-ptr checks from users of
can_dev_rcv_lists_find(). 'err' parameter is useless, so remove it.
Signed-off-by: Ye Bin <yebin10@...wei.com>
---
net/can/af_can.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/net/can/af_can.c b/net/can/af_can.c
index 27dcdcc0b808..ec3f7e658295 100644
--- a/net/can/af_can.c
+++ b/net/can/af_can.c
@@ -446,7 +446,6 @@ int can_rx_register(struct net *net, struct net_device *dev, canid_t can_id,
struct hlist_head *rcv_list;
struct can_dev_rcv_lists *dev_rcv_lists;
struct can_rcv_lists_stats *rcv_lists_stats = net->can.rcv_lists_stats;
- int err = 0;
/* insert new receiver (dev,canid,mask) -> (func,data) */
@@ -481,7 +480,7 @@ int can_rx_register(struct net *net, struct net_device *dev, canid_t can_id,
rcv_lists_stats->rcv_entries);
spin_unlock_bh(&net->can.rcvlists_lock);
- return err;
+ return 0;
}
EXPORT_SYMBOL(can_rx_register);
--
2.31.1
Powered by blists - more mailing lists