Re: [PATCH 6/6] can: peak_usb: add ethtool interface to user defined flashed device number

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue. 22 Feb 2022 à 01:39, Stéphane Grosjean
<s.grosjean@xxxxxxxxxxxxxxx> wrote:
>
> Hi Marc,
>
> >On 15.02.2022 16:10:45, Marc Kleine-Budde wrote:
> >> On 11.02.2022 10:57:34, Stéphane Grosjean wrote:
> >> > endianess is handled by lower level functions (see for ex
> >> > pcan_usb_fd_get_user_devid()/pcan_usb_fd_set_user_devid() in PATCH
> >> > 2/6).
> >> >
> >> > This data is really a number and must be treated as such.
> >>
> >> What's the use case for the data/number? What's the big picture?
>
> >| Jan 01 05:16:21 DistroKit kernel: peak_usb 1-1:1.0: PEAK-System PCAN-USB FD v1 fw v3.2.0 (1 channels)
> >| Jan 01 05:16:21 DistroKit kernel: peak_usb 1-1:1.0 can0: attached to PCAN-USB FD channel 0 (device 1144201745)
> >                                                                                                     ^^^^^^^^^^
>
> >But that is something different than the serial number, right?
>
> Yep! This is a number that can be used to uniquely identify the device, regardless of the USB port or the order in which it is connected. The purpose is to allow the user to name the network interface according to this number. This is for example what is done by the "historical" driver "pcan" which is freely downloadable from www.peak-system.com.

FYI, for the dual interfaces (PCAN-USB Pro), you might want to
populate net_device::dev_port as well.
c.f. https://git.kernel.org/pub/scm/linux/kernel/git/mkl/linux-can-next.git/commit/?h=testing&id=e233640cd3034ae65924316a0d95ccacb86ae4bd


Yours sincerely,
Vincent Mailhol




[Index of Archives]     [Automotive Discussions]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]     [CAN Bus]

  Powered by Linux