summaryrefslogtreecommitdiff
path: root/include/linux/can
diff options
context:
space:
mode:
authorMarc Kleine-Budde <mkl@pengutronix.de>2018-10-08 10:02:39 +0300
committerMarc Kleine-Budde <mkl@pengutronix.de>2019-09-04 14:29:15 +0300
commit8df9ffb888c021fa68f9075d545f2ec5eca37200 (patch)
treec783503e0599f77685c82925a36bfa3f0a2a9794 /include/linux/can
parentffd956eef69b212a724b1cc4cdc61828f3ad9104 (diff)
downloadlinux-8df9ffb888c021fa68f9075d545f2ec5eca37200.tar.xz
can: make use of preallocated can_ml_priv for per device struct can_dev_rcv_lists
This patch removes the old method of allocating the per device protocol specific memory via a netdevice_notifier. This had the drawback, that the allocation can fail, leading to a lot of null pointer checks in the code. This also makes the live cycle management of this memory quite complicated. This patch switches from the allocating the struct can_dev_rcv_lists in a NETDEV_REGISTER call to using the dev->ml_priv, which is allocated by the driver since the previous patch. 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 'include/linux/can')
-rw-r--r--include/linux/can/can-ml.h1
1 files changed, 0 insertions, 1 deletions
diff --git a/include/linux/can/can-ml.h b/include/linux/can/can-ml.h
index 0a9d778de8af..79ccf6bfa232 100644
--- a/include/linux/can/can-ml.h
+++ b/include/linux/can/can-ml.h
@@ -55,7 +55,6 @@ struct can_dev_rcv_lists {
struct hlist_head rx[RX_MAX];
struct hlist_head rx_sff[CAN_SFF_RCV_ARRAY_SZ];
struct hlist_head rx_eff[CAN_EFF_RCV_ARRAY_SZ];
- int remove_on_zero_entries;
int entries;
};