linux/drivers/net/can/usb
Christopher R. Baker 3e66d0138c can: populate netdev::dev_id for udev discrimination
My objective is to be able to totally discriminate CAN ports on multi-port
cards via udev so as to rename them to semantically interesting/unique names
for my system (e.g., "ecuCAN" and "auxCAN" instead of "can0" and "can1").

The following patch assigns the dev_id field to match the channel number on all
multi-channel devices. I can only test my two-port Peak PCI card, but it works
as expected: ATTRS{dev_id} now expresses the port number and my udev rules now
unambiguously pick out and rename my individual CAN ports.

Signed-off-by: Christopher R. Baker <cbaker@rec.ri.cmu.edu>
Tested-by: Oliver Hartkopp <socketcan@hartkopp.net> [PEAK PCAN-USB pro and EMS PCMCIA]
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2014-03-17 09:20:16 +01:00
..
peak_usb can: populate netdev::dev_id for udev discrimination 2014-03-17 09:20:16 +01:00
ems_usb.c can: Unify MTU settings for CAN interfaces 2014-03-17 09:20:16 +01:00
esd_usb2.c can: populate netdev::dev_id for udev discrimination 2014-03-17 09:20:16 +01:00
Kconfig can: usb_8dev: Add support for USB2CAN interface from 8 devices 2013-01-26 16:58:58 +01:00
kvaser_usb.c can: populate netdev::dev_id for udev discrimination 2014-03-17 09:20:16 +01:00
Makefile can: usb_8dev: Add support for USB2CAN interface from 8 devices 2013-01-26 16:58:58 +01:00
usb_8dev.c can: Unify MTU settings for CAN interfaces 2014-03-17 09:20:16 +01:00