Le jeudi 10 décembre 2009 à 16:42 +0100, Wolfgang Grandegger a écrit : > Sylvain Lamontagne wrote: > > Hi > > I am working with a custom MPC5200B based board and the CAN is mostly > > working on it, using the revision 958 on the berlios svn. I know it's > > quite old, this is why this email have two part. The kernel is version > > 2.6.29.2 with some patches for our internal needs. > > > > First: > > I have been trying to figure out why sometime I'm getting a kernel Oops > > when the command "ifconfig canX down" is used. The Oops is pretty random > > so there is no easy way (that I found) to reproduce it, therefor it is > > hard to debug. I've attached the Oops to this email. (I have plenty of > > similar) > > > > My question regarding this first issue is: Is it known that this version > > (958) of the driver can cause a kernel Oops ? > > Regarding this email it seems that I'm not alone. > > https://lists.berlios.de/pipermail/socketcan-users/2009-February/000646.html > > OK, I have no quick solution for that problem and as the version is > already quite old... let's try with up-to-date software. > Yeah no problem, I'll test with the new driver for a while and if I see this kernel oops again I'll repost here.
> > I though that updating the driver would be a good thing, so I tried and > > this is why I have a second part to this email. > > > > Second: > > By reading the various source of information on the internet I have > > discovered that SocketCAN source code seems now in two different places. > > The berlios SVN and this git > > git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6 > > There is MSCAN-Support in the mainline kernel since 2.6.32. The code at > BerliOS is (usually) in sync with the official version and it still > supports older versions of the kernel. > > > So I'm a bit confused about which I should use, but I tried with the > > berlios svn r1095 but it seems that the way I was compiling before > > doesn't work anymore ... it seems to compile but the mscan driver is not > > compiled. I get some .ko but no mscan-mpc52xx.ko mscan.ko or > > mscan_5xxx.ko anywhere... previously I was getting mscan-mpc52xx.ko > > $ cd trunk/kernel/2.6 > $ make ARCH=powerpc \ > KERNELDIR=$KSRC CONFIG_CAN_DEBUG_DEVICES=y \ > CONFIG_CAN_DEV=m \ > CONFIG_CAN_MSCAN=m CONFIG_CAN_MPC52XX=m CONFIG_CAN_MPC5XXX=m \ > > should do the job. For 2.6.29 CONFIG_CAN_MPC5XXX=m should just be fine. Yep it worked fine, though I think maybe there is something odd in the different Makefile. If I don't specify the CONFIG_CAN_* options above I'll not get the driver. Specifying only CONFIG_CAN_MPC5XXX=m instead of both worked fine for my kernel. > > > I probably do something wrong, but to verify that I would need the > > procedure to compiled the drivers correctly or even better to include > > them in the kernel as a simple patch. > > > > And also before someone suggest it ... I can't upgrade the kernel to a > > new version on this unit without having really good reason. > > > > So, what is the way to get a newer version of the SocketCAN driver to > > work on a linux kernel 2.6.29.2 ? > > See above. Note that the official kernel version now uses the netlink > interface to configure the device, instead of the deprecated sysfs. Yep, I used git version of iproute2 to configure it and everything is working fine. I'll do more testing in the following days, but it seems pretty well so far. Thanks a lot! > > Wolfgang. > > > > > > > > > ------------------------------------------------------------------------ > > > > _______________________________________________ > > Socketcan-users mailing list > > [email protected] > > https://lists.berlios.de/mailman/listinfo/socketcan-users -- Sylvain Lamontagne <[email protected]> Novariant _______________________________________________ Socketcan-users mailing list [email protected] https://lists.berlios.de/mailman/listinfo/socketcan-users
