Re: mcp251xfd on RPi 5.4 downstream

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

 





On 25.10.20 05:30, Drew Fustini wrote:
On Thu, Oct 22, 2020 at 1:42 PM Drew Fustini <drew@xxxxxxxxxxxxxxx> wrote:

On Thu, Oct 22, 2020 at 1:33 AM Marc Kleine-Budde <mkl@xxxxxxxxxxxxxx> wrote:

On 10/22/20 8:00 AM, Drew Fustini wrote:
It appears it was simpler to get it to compile than I expected.

\o/

cs_change_delay.unit becomes cs_change_delay_unit,  and
cs_change_delay.value becomes cs_change_delay.

The other issue was 728fc9ff73d3 ("can: rx-offload:
can_rx_offload_add_manual(): add new initialization function") which
was simply solved by adding can_rx_offload_add_manual() to:
include/linux/can/rx-offload.h
drivers/net/can/rx-offload.c

The driver builds ok:

With your help :) I backported current linus/master to the rpi-5.4:

https://github.com/marckleinebudde/linux/tree/v5.4-rpi/mcp251xfd-20201022-54

Can you test that?

Thanks, will do.   I am currently trying to finish up my ELC-E talk
prep :) but will get back to you with the results of testing later.

I noticed up doing a modprobe that there are several Unknown symbol errors.

Any ideas?

[  358.686691] mcp251xfd: Unknown symbol can_rx_offload_del (err -2)
[  358.686744] mcp251xfd: Unknown symbol can_put_echo_skb (err -2)
[  358.686796] mcp251xfd: Unknown symbol can_len2dlc (err -2)
[  358.686844] mcp251xfd: Unknown symbol alloc_canfd_skb (err -2)
[  358.686942] mcp251xfd: Unknown symbol open_candev (err -2)
[  358.687042] mcp251xfd: Unknown symbol alloc_can_skb (err -2)
[  358.687093] mcp251xfd: Unknown symbol unregister_candev (err -2)
[  358.687139] mcp251xfd: Unknown symbol can_change_state (err -2)
[  358.687183] mcp251xfd: Unknown symbol can_change_mtu (err -2)
[  358.687227] mcp251xfd: Unknown symbol can_rx_offload_add_manual (err -2)
[  358.687294] mcp251xfd: Unknown symbol free_candev (err -2)
[  358.687345] mcp251xfd: Unknown symbol alloc_candev_mqs (err -2)
[  358.687416] mcp251xfd: Unknown symbol close_candev (err -2)
[  358.687475] mcp251xfd: Unknown symbol can_bus_off (err -2)
[  358.687519] mcp251xfd: Unknown symbol can_rx_offload_enable (err -2)
[  358.687569] mcp251xfd: Unknown symbol can_rx_offload_get_echo_skb (err -2)
[  358.687656] mcp251xfd: Unknown symbol can_dlc2len (err -2)
[  358.687710] mcp251xfd: Unknown symbol alloc_can_err_skb (err -2)
[  358.687773] mcp251xfd: Unknown symbol can_rx_offload_queue_sorted (err -2)
[  358.687819] mcp251xfd: Unknown symbol register_candev (err -2)
[  369.092608] CAN device driver interface

The can-dev module has been loaded *after* mcp251xfd.

Don't know why autoloading did not work on your machine but doing a 'modprobe can-dev' before loading the MCP driver should do it for a test.

Best,
Oliver


root@raspberrypi:~# modinfo mcp251xfd
filename:
/lib/modules/5.4.72-v7l+/kernel/drivers/net/can/spi/mcp251xfd/mcp251xfd.ko
license:        GPL v2
description:    Microchip MCP251xFD Family CAN controller driver
author:         Marc Kleine-Budde <mkl@xxxxxxxxxxxxxx>
srcversion:     1E05EEB5939E9AB22BA2E1B
alias:          spi:mcp251xfd
alias:          spi:mcp2518fd
alias:          spi:mcp2517fd
alias:          of:N*T*Cmicrochip,mcp251xfdC*
alias:          of:N*T*Cmicrochip,mcp251xfd
alias:          of:N*T*Cmicrochip,mcp2518fdC*
alias:          of:N*T*Cmicrochip,mcp2518fd
alias:          of:N*T*Cmicrochip,mcp2517fdC*
alias:          of:N*T*Cmicrochip,mcp2517fd
depends:        can-dev
intree:         Y
name:           mcp251xfd
vermagic:       5.4.72-v7l+ SMP mod_unload modversions ARMv7 p2v8

root@raspberrypi:~# lsmod |grep mcp
mcp251xfd              36864  0
can_dev                28672  1 mcp251xfd


Thanks,
Drew




[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