* [U-Boot] CAN console @ 2009-10-26 8:20 Matthias Weißer 2009-10-26 8:37 ` Mike Frysinger 2009-10-26 12:42 ` Wolfgang Grandegger 0 siblings, 2 replies; 10+ messages in thread From: Matthias Weißer @ 2009-10-26 8:20 UTC (permalink / raw) To: u-boot Hi I have a device here which has only a CAN interface to the outside world. I am currently thinking about implementing a "serial" driver using the CAN controller. Is there any chance to get this accepted in the public u-boot tree? A special program on the PC side would be needed to translate the CAN messages back to a serial stream and vice versa and make it available to a terminal program. But thats another story. Regards, Matthias Wei?er ^ permalink raw reply [flat|nested] 10+ messages in thread
* [U-Boot] CAN console 2009-10-26 8:20 [U-Boot] CAN console Matthias Weißer @ 2009-10-26 8:37 ` Mike Frysinger 2009-10-26 11:09 ` Matthias Weißer 2009-10-26 12:42 ` Wolfgang Grandegger 1 sibling, 1 reply; 10+ messages in thread From: Mike Frysinger @ 2009-10-26 8:37 UTC (permalink / raw) To: u-boot On Monday 26 October 2009 04:20:02 Matthias Wei?er wrote: > I have a device here which has only a CAN interface to the > outside world. I am currently thinking about implementing > a "serial" driver using the CAN controller. > > Is there any chance to get this accepted in the public u-boot > tree? someone just posted a port of the Linux CAN framework. if your driver used that to implement a serial layer, i dont see why it wouldnt be accepted. -mike -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 836 bytes Desc: This is a digitally signed message part. Url : http://lists.denx.de/pipermail/u-boot/attachments/20091026/92f6d591/attachment.pgp ^ permalink raw reply [flat|nested] 10+ messages in thread
* [U-Boot] CAN console 2009-10-26 8:37 ` Mike Frysinger @ 2009-10-26 11:09 ` Matthias Weißer 2009-10-26 11:26 ` Mike Frysinger 0 siblings, 1 reply; 10+ messages in thread From: Matthias Weißer @ 2009-10-26 11:09 UTC (permalink / raw) To: u-boot Mike Frysinger schrieb: > On Monday 26 October 2009 04:20:02 Matthias Wei?er wrote: >> I have a device here which has only a CAN interface to the >> outside world. I am currently thinking about implementing >> a "serial" driver using the CAN controller. >> >> Is there any chance to get this accepted in the public u-boot >> tree? > > someone just posted a port of the Linux CAN framework. if your driver used > that to implement a serial layer, i dont see why it wouldnt be accepted. > -mike Well, that means that I have to implement a full functional CAN driver and then additionally add a serial driver using the (completely new) CAN framework. My idea was that I just add a serial_ccan.c to drivers/serial. Matthias Wei?er ^ permalink raw reply [flat|nested] 10+ messages in thread
* [U-Boot] CAN console 2009-10-26 11:09 ` Matthias Weißer @ 2009-10-26 11:26 ` Mike Frysinger 2009-10-26 12:20 ` Matthias Weißer 2009-10-26 12:28 ` Wolfgang Grandegger 0 siblings, 2 replies; 10+ messages in thread From: Mike Frysinger @ 2009-10-26 11:26 UTC (permalink / raw) To: u-boot On Monday 26 October 2009 07:09:03 Matthias Wei?er wrote: > Mike Frysinger schrieb: > > On Monday 26 October 2009 04:20:02 Matthias Wei?er wrote: > >> I have a device here which has only a CAN interface to the > >> outside world. I am currently thinking about implementing > >> a "serial" driver using the CAN controller. > >> > >> Is there any chance to get this accepted in the public u-boot > >> tree? > > > > someone just posted a port of the Linux CAN framework. if your driver > > used that to implement a serial layer, i dont see why it wouldnt be > > accepted. > > Well, that means that I have to implement a full functional CAN driver > and then additionally add a serial driver using the (completely new) CAN > framework. My idea was that I just add a serial_ccan.c to drivers/serial. you would rather write a driver that is specific to one CAN hardware ? writing it to a common framework would allow every one with a CAN driver to use it ... -mike -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 836 bytes Desc: This is a digitally signed message part. Url : http://lists.denx.de/pipermail/u-boot/attachments/20091026/bc264a6d/attachment.pgp ^ permalink raw reply [flat|nested] 10+ messages in thread
* [U-Boot] CAN console 2009-10-26 11:26 ` Mike Frysinger @ 2009-10-26 12:20 ` Matthias Weißer 2009-10-26 12:28 ` Mike Frysinger 2009-10-26 12:52 ` Wolfgang Denk 2009-10-26 12:28 ` Wolfgang Grandegger 1 sibling, 2 replies; 10+ messages in thread From: Matthias Weißer @ 2009-10-26 12:20 UTC (permalink / raw) To: u-boot Mike Frysinger schrieb: > you would rather write a driver that is specific to one CAN hardware ? In general? No, I wouldn't. I would use a given CAN driver framework where I put my CAN driver in. In this specific case: I think I would, as there is currently no CAN framework available in u-boot. Is there any chance that the stuff posted by miaofng will be available in u-boot-next? > writing it to a common framework would allow every one with a CAN driver to > use it ... Yes. I totally agree here. And if there is a chance that there will be a CAN framework in u-boot in not to far future I will write my stuff against that. I think I am not deep enough in u-boot that I will be able to write such a framework by myself. Ragards, Matthias Wei?er ^ permalink raw reply [flat|nested] 10+ messages in thread
* [U-Boot] CAN console 2009-10-26 12:20 ` Matthias Weißer @ 2009-10-26 12:28 ` Mike Frysinger 2009-10-26 12:52 ` Wolfgang Denk 1 sibling, 0 replies; 10+ messages in thread From: Mike Frysinger @ 2009-10-26 12:28 UTC (permalink / raw) To: u-boot On Monday 26 October 2009 08:20:03 Matthias Wei?er wrote: > Mike Frysinger schrieb: > > you would rather write a driver that is specific to one CAN hardware ? > > In general? No, I wouldn't. I would use a given CAN driver framework > where I put my CAN driver in. > > In this specific case: I think I would, as there is currently no CAN > framework available in u-boot. my point was more that a common driver would probably be more likely to be accepted, but this leads me to the next point ... > Is there any chance that the stuff posted by miaofng will be available > in u-boot-next? no idea, i'm not the maintainer. just part of the peanut gallery. -mike -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 836 bytes Desc: This is a digitally signed message part. Url : http://lists.denx.de/pipermail/u-boot/attachments/20091026/a1577066/attachment.pgp ^ permalink raw reply [flat|nested] 10+ messages in thread
* [U-Boot] CAN console 2009-10-26 12:20 ` Matthias Weißer 2009-10-26 12:28 ` Mike Frysinger @ 2009-10-26 12:52 ` Wolfgang Denk 2009-10-26 13:53 ` miaofng 1 sibling, 1 reply; 10+ messages in thread From: Wolfgang Denk @ 2009-10-26 12:52 UTC (permalink / raw) To: u-boot Dear =?ISO-8859-15?Q?Matthias_Wei=DFer?=, In message <4AE593F3.3030608@arcor.de> you wrote: > > In this specific case: I think I would, as there is currently no CAN > framework available in u-boot. This just means that your implementation requires a two-step approach. In step 1, implement the framework. > Is there any chance that the stuff posted by miaofng will be available > in u-boot-next? I'm not really sure. As Wolfgang Grandegger already commented, the implementation is really heavy for a mere boot loader. Sharing code with Linux is generally a good thing, but it has to fit, too. I'm not convinced it fits here. Let's see wht the now following discussion gives. In any case, this is too green for "next". IMHO it would even bee too green for "staging" if we had something like this (which we don't have :-) > Yes. I totally agree here. And if there is a chance that there will be a > CAN framework in u-boot in not to far future I will write my stuff > against that. Do both things at once? The effort saved to re-implement your driver code against the to-be framwork can be thrown at implementing the framework in a first step ... > I think I am not deep enough in u-boot that I will be able to write such > a framework by myself. That's only a "not yet", believe me :-) Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de The further the spiritual evolution of mankind advances, the more certain it seems to me that the path to genuine religiosity does not lie through the fear of life, and the fear of death, and blind faith, but through striving after rational knowledge. - Albert Einstein ^ permalink raw reply [flat|nested] 10+ messages in thread
* [U-Boot] CAN console 2009-10-26 12:52 ` Wolfgang Denk @ 2009-10-26 13:53 ` miaofng 0 siblings, 0 replies; 10+ messages in thread From: miaofng @ 2009-10-26 13:53 UTC (permalink / raw) To: u-boot Wolfgang Denk wrote: >> Is there any chance that the stuff posted by miaofng will be available >> in u-boot-next? >> > > I'm not really sure. As Wolfgang Grandegger already commented, the > implementation is really heavy for a mere boot loader. Sharing code > with Linux is generally a good thing, but it has to fit, too. I'm not > convinced it fits here. Let's see wht the now following discussion > gives. In any case, this is too green for "next". IMHO it would even > bee too green for "staging" if we had something like this (which we > don't have :-) > > > In fact it's not so heavy, it is not socket can architecture based!!! I copied some of linux socket can based ->driver part<- of codes and added a small wrapped layer(by myself) only because i am too lazy to rewrite the sja1000 driver. For blocked or unblocked access problem, it does support both. To me, i agree mike's view if i write the sja1000 driver from scratch:) ^ permalink raw reply [flat|nested] 10+ messages in thread
* [U-Boot] CAN console 2009-10-26 11:26 ` Mike Frysinger 2009-10-26 12:20 ` Matthias Weißer @ 2009-10-26 12:28 ` Wolfgang Grandegger 1 sibling, 0 replies; 10+ messages in thread From: Wolfgang Grandegger @ 2009-10-26 12:28 UTC (permalink / raw) To: u-boot Mike Frysinger wrote: > On Monday 26 October 2009 07:09:03 Matthias Wei?er wrote: >> Mike Frysinger schrieb: >>> On Monday 26 October 2009 04:20:02 Matthias Wei?er wrote: >>>> I have a device here which has only a CAN interface to the >>>> outside world. I am currently thinking about implementing >>>> a "serial" driver using the CAN controller. >>>> >>>> Is there any chance to get this accepted in the public u-boot >>>> tree? >>> someone just posted a port of the Linux CAN framework. if your driver >>> used that to implement a serial layer, i dont see why it wouldnt be >>> accepted. >> Well, that means that I have to implement a full functional CAN driver >> and then additionally add a serial driver using the (completely new) CAN >> framework. My idea was that I just add a serial_ccan.c to drivers/serial. > > you would rather write a driver that is specific to one CAN hardware ? > writing it to a common framework would allow every one with a CAN driver to > use it ... There are many simple USB CAN devices which are operated through the tty interface. See http://prdownload.berlios.de/socketcan/SLCAN-API.pdf Wolfgang. ^ permalink raw reply [flat|nested] 10+ messages in thread
* [U-Boot] CAN console 2009-10-26 8:20 [U-Boot] CAN console Matthias Weißer 2009-10-26 8:37 ` Mike Frysinger @ 2009-10-26 12:42 ` Wolfgang Grandegger 1 sibling, 0 replies; 10+ messages in thread From: Wolfgang Grandegger @ 2009-10-26 12:42 UTC (permalink / raw) To: u-boot Matthias Wei?er wrote: > Hi > > I have a device here which has only a CAN interface to the > outside world. I am currently thinking about implementing > a "serial" driver using the CAN controller. OK, a dedicated CAN driver would make more sense. > Is there any chance to get this accepted in the public u-boot > tree? I think yes, if it does not mis-use U-BOOT > A special program on the PC side would be needed to translate > the CAN messages back to a serial stream and vice versa and > make it available to a terminal program. But thats another story. Netconsole could do the job, but that would require to run IP over CAN. Wolfgang. ^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2009-10-26 13:53 UTC | newest] Thread overview: 10+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2009-10-26 8:20 [U-Boot] CAN console Matthias Weißer 2009-10-26 8:37 ` Mike Frysinger 2009-10-26 11:09 ` Matthias Weißer 2009-10-26 11:26 ` Mike Frysinger 2009-10-26 12:20 ` Matthias Weißer 2009-10-26 12:28 ` Mike Frysinger 2009-10-26 12:52 ` Wolfgang Denk 2009-10-26 13:53 ` miaofng 2009-10-26 12:28 ` Wolfgang Grandegger 2009-10-26 12:42 ` Wolfgang Grandegger
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox