diff options
author | Marc Kleine-Budde <mkl@pengutronix.de> | 2018-10-08 09:02:34 +0200 |
---|---|---|
committer | Marc Kleine-Budde <mkl@pengutronix.de> | 2019-09-04 13:29:14 +0200 |
commit | fac785009aaf2f6588649778617b33cb0dcd4c8e (patch) | |
tree | af8803ea5a239b37f5a35e7c29f86c15d5a37b05 /net/can/af_can.c | |
parent | 3ee6d2bebef8cd35d2a43422b642f7b57fb409f9 (diff) | |
download | linux-stable-fac785009aaf2f6588649778617b33cb0dcd4c8e.tar.gz linux-stable-fac785009aaf2f6588649778617b33cb0dcd4c8e.tar.bz2 linux-stable-fac785009aaf2f6588649778617b33cb0dcd4c8e.zip |
can: af_can: rename find_dev_rcv_lists() to can_dev_rcv_lists_find()
This patch add the commonly used prefix "can_" to the find_dev_rcv_lists()
function and moves the "find" to the end, as the function returns a struct
can_dev_rcv_list. This improves the overall readability of the code.
Signed-off-by: Oleksij Rempel <o.rempel@pengutronix.de>
Acked-by: Oliver Hartkopp <socketcan@hartkopp.net>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Diffstat (limited to 'net/can/af_can.c')
-rw-r--r-- | net/can/af_can.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/net/can/af_can.c b/net/can/af_can.c index 0b008187a840..a5bb364cbf61 100644 --- a/net/can/af_can.c +++ b/net/can/af_can.c @@ -298,8 +298,8 @@ EXPORT_SYMBOL(can_send); /* af_can rx path */ -static struct can_dev_rcv_lists *find_dev_rcv_lists(struct net *net, - struct net_device *dev) +static struct can_dev_rcv_lists *can_dev_rcv_lists_find(struct net *net, + struct net_device *dev) { if (!dev) return net->can.rx_alldev_list; @@ -458,7 +458,7 @@ int can_rx_register(struct net *net, struct net_device *dev, canid_t can_id, spin_lock(&net->can.rcvlists_lock); - dev_rcv_lists = find_dev_rcv_lists(net, dev); + dev_rcv_lists = can_dev_rcv_lists_find(net, dev); if (dev_rcv_lists) { rl = can_rcv_list_find(&can_id, &mask, dev_rcv_lists); @@ -526,7 +526,7 @@ void can_rx_unregister(struct net *net, struct net_device *dev, canid_t can_id, spin_lock(&net->can.rcvlists_lock); - dev_rcv_lists = find_dev_rcv_lists(net, dev); + dev_rcv_lists = can_dev_rcv_lists_find(net, dev); if (!dev_rcv_lists) { pr_err("BUG: receive list not found for dev %s, id %03X, mask %03X\n", DNAME(dev), can_id, mask); @@ -671,7 +671,7 @@ static void can_receive(struct sk_buff *skb, struct net_device *dev) matches = can_rcv_filter(net->can.rx_alldev_list, skb); /* find receive list for this device */ - dev_rcv_lists = find_dev_rcv_lists(net, dev); + dev_rcv_lists = can_dev_rcv_lists_find(net, dev); if (dev_rcv_lists) matches += can_rcv_filter(dev_rcv_lists, skb); |