From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <550D3074.7020908@grandegger.com> Date: Sat, 21 Mar 2015 09:48:52 +0100 From: Wolfgang Grandegger MIME-Version: 1.0 References: <550BD231.5020002@web.de> <20150320181638.GB27775@hermes.click-hack.org> In-Reply-To: <20150320181638.GB27775@hermes.click-hack.org> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Subject: Re: [Xenomai] RT-CAN question (was: CAN bus on beaglebone black) List-Id: Discussions about the Xenomai project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Gilles Chanteperdrix , Steve B Cc: xenomai On 03/20/2015 07:16 PM, Gilles Chanteperdrix wrote: > On Fri, Mar 20, 2015 at 10:42:05AM -0700, Steve B wrote: >> Michael, >> At least for the Beaglebone Black case, it is looking like you will have a >> good and simple way of picking which driver you load. >> I am working on getting the driver integrated to the Xenomai tree and in >> the process making minor tweaks.. by changing the "compatibility" string to >> something unique it looks like you can match the CAN device to the driver >> in your device tree overlay. Should be no more having to load the original >> driver first. >> >> I have a bit of an issue that I'm trying to work around with splitting the >> driver into the multiple source files, but once I get that sorted out it >> should be ready to work that way! > >>>From what I understood, the device tree is a description of the > hardware, so the compatibility string describes what hardware a > board/controller is based on. So, it does not make sense to change > the compatibility string to change the driver used. This is contrary > to the spirit of the device tree. A device tree is supposed to be OS > independent, the device tree files licenses for instance, have been > chosen to not prevent a device tree file from being used with BSD. Yes, that's also my understanding and other RTCAN drivers use the same bindings than the Linux driver. There are various options to handle the driver binding: - use rmmod to unload the Linux driver - use "unbind" to disconnect the Linux driver and "bind" to connect the RT-variant - do not build the Linux driver at all - use /etc/modprobe.d/blacklist Wolfgang.