* [PATCH] can: fix oops caused by wrong rtnl dellink usage
@ 2016-06-21 13:45 Oliver Hartkopp
2016-06-22 20:43 ` Marc Kleine-Budde
0 siblings, 1 reply; 3+ messages in thread
From: Oliver Hartkopp @ 2016-06-21 13:45 UTC (permalink / raw)
To: linux-can; +Cc: Oliver Hartkopp
For 'real' hardware CAN devices the netlink interface is used to set CAN
specific communication parameters. Real CAN hardware can not be created nor
removed with the ip tool ...
This patch adds a private dellink function for the CAN device driver interface
that does just nothing.
It's a follow up to commit 993e6f2fd ("can: fix oops caused by wrong rtnl
newlink usage") but for dellink.
Reported-by: ajneu <ajneu1@gmail.com>
Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net>
---
drivers/net/can/dev.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/drivers/net/can/dev.c b/drivers/net/can/dev.c
index 910c12e..b1dc109 100644
--- a/drivers/net/can/dev.c
+++ b/drivers/net/can/dev.c
@@ -1008,6 +1008,11 @@ static int can_newlink(struct net *src_net, struct net_device *dev,
return -EOPNOTSUPP;
}
+static void can_dellink(struct net_device *dev, struct list_head *head)
+{
+ return;
+}
+
static struct rtnl_link_ops can_link_ops __read_mostly = {
.kind = "can",
.maxtype = IFLA_CAN_MAX,
@@ -1016,6 +1021,7 @@ static struct rtnl_link_ops can_link_ops __read_mostly = {
.validate = can_validate,
.newlink = can_newlink,
.changelink = can_changelink,
+ .dellink = can_dellink,
.get_size = can_get_size,
.fill_info = can_fill_info,
.get_xstats_size = can_get_xstats_size,
--
2.8.1
^ permalink raw reply related [flat|nested] 3+ messages in thread* Re: [PATCH] can: fix oops caused by wrong rtnl dellink usage
2016-06-21 13:45 [PATCH] can: fix oops caused by wrong rtnl dellink usage Oliver Hartkopp
@ 2016-06-22 20:43 ` Marc Kleine-Budde
2016-06-23 5:52 ` Oliver Hartkopp
0 siblings, 1 reply; 3+ messages in thread
From: Marc Kleine-Budde @ 2016-06-22 20:43 UTC (permalink / raw)
To: Oliver Hartkopp, linux-can
[-- Attachment #1.1: Type: text/plain, Size: 894 bytes --]
On 06/21/2016 03:45 PM, Oliver Hartkopp wrote:
> For 'real' hardware CAN devices the netlink interface is used to set CAN
> specific communication parameters. Real CAN hardware can not be created nor
> removed with the ip tool ...
>
> This patch adds a private dellink function for the CAN device driver interface
> that does just nothing.
>
> It's a follow up to commit 993e6f2fd ("can: fix oops caused by wrong rtnl
> newlink usage") but for dellink.
>
> Reported-by: ajneu <ajneu1@gmail.com>
> Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net>
Applied to can + stable on Cc.
Tnx,
Marc
--
Pengutronix e.K. | Marc Kleine-Budde |
Industrial Linux Solutions | Phone: +49-231-2826-924 |
Vertretung West/Dortmund | Fax: +49-5121-206917-5555 |
Amtsgericht Hildesheim, HRA 2686 | http://www.pengutronix.de |
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 455 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH] can: fix oops caused by wrong rtnl dellink usage
2016-06-22 20:43 ` Marc Kleine-Budde
@ 2016-06-23 5:52 ` Oliver Hartkopp
0 siblings, 0 replies; 3+ messages in thread
From: Oliver Hartkopp @ 2016-06-23 5:52 UTC (permalink / raw)
To: Marc Kleine-Budde, linux-can
Hi Marc,
I sent two fixes reported by ajneu.
You probably missed this one
http://marc.info/?l=linux-can&m=146650412017263&w=2
which is a stable candidate too.
Regards,
Oliver
On 06/22/2016 10:43 PM, Marc Kleine-Budde wrote:
> On 06/21/2016 03:45 PM, Oliver Hartkopp wrote:
>> For 'real' hardware CAN devices the netlink interface is used to set CAN
>> specific communication parameters. Real CAN hardware can not be created nor
>> removed with the ip tool ...
>>
>> This patch adds a private dellink function for the CAN device driver interface
>> that does just nothing.
>>
>> It's a follow up to commit 993e6f2fd ("can: fix oops caused by wrong rtnl
>> newlink usage") but for dellink.
>>
>> Reported-by: ajneu <ajneu1@gmail.com>
>> Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net>
>
> Applied to can + stable on Cc.
>
> Tnx,
> Marc
>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2016-06-23 5:52 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-06-21 13:45 [PATCH] can: fix oops caused by wrong rtnl dellink usage Oliver Hartkopp
2016-06-22 20:43 ` Marc Kleine-Budde
2016-06-23 5:52 ` Oliver Hartkopp
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.