<div dir="ltr">I'm not sure what I did to get the extra debug messages. When I run the usb01 example, I just see:<div>nexus0: <RTEMS Nexus device></div><div><br></div><div>I will have to read up on how the libbsd drivers are used, and what needs to be done to set them up in nexus-devices.h</div><div><br></div><div>Chris: do you know if it would help to boot FreeBSD on the Pi to see the messages and look at what drivers are used?</div><div><br></div><div>Alan</div><div><br></div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jul 12, 2016 at 12:41 AM, Deval Shah <span dir="ltr"><<a href="mailto:deval.maker@gmail.com" target="_blank">deval.maker@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">I am sorry, I forgot to mention those details. <div><br></div><div>I have added --freebsd-options=bootverbose,verbose_sysinit,bus_debug for more log, while configuring waf. </div><div><br></div><div>There are two branches currently. RaspberryPi_USB and rpi_usb. Both are same as far as my added code is concerned. rpi_usb has a different starting point and not updated while the other one is up to date. </div><div><br></div><div>The problem with the RaspberryPi_USB was that due to some other updates in mainline, I was not getting the device_printfs. So I switched back to the old repo of mine. </div><div><br></div><div>Also, I am surprised how you are getting the device_printfs on my latest code. <a href="https://lists.rtems.org/pipermail/devel/2016-July/015557.html" target="_blank">https://lists.rtems.org/pipermail/devel/2016-July/015557.html</a> </div><div><br></div><div>Regards,</div><div>Deval Shah</div></div><div class="gmail_extra"><div><div class="h5"><br><div class="gmail_quote">On Tue, Jul 12, 2016 at 7:05 AM, Alan Cudmore <span dir="ltr"><<a href="mailto:alan.cudmore@gmail.com" target="_blank">alan.cudmore@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word">Hi Deval,<div><br></div><div>What code do I need to add to try your test? </div><div><br></div><div>I am using the items git head kernel, and your rtems-libbsd RaspberryPi_USB branch.</div><div>When I run init01 on my Pi Zero, I get the output below. </div><div><br></div><div>Alan</div><div><br></div><div><div style="margin:0px;font-size:18px;font-family:'Andale Mono'">*** LIBBSD INIT 1 TEST ***</div><div style="margin:0px;font-size:18px;font-family:'Andale Mono'">nexus0: <RTEMS Nexus device></div><div style="margin:0px;font-size:18px;font-family:'Andale Mono'">bcm283x_dwcotg0: <DWC OTG 2.0 integrated USB controller (bcm283x)> on nexus0</div><div style="margin:0px;font-size:18px;font-family:'Andale Mono'">usbus0 on bcm283x_dwcotg0</div><div style="margin:0px;font-size:18px;font-family:'Andale Mono'">usbus0: 480Mbps High Speed USB v2.0</div><div style="margin:0px;font-size:18px;font-family:'Andale Mono'">uhub0: <DWCOTG OTG Root HUB, class 9/0, rev 2.00/1.00, addr 1> on usbus0</div><div style="margin:0px;font-size:18px;font-family:'Andale Mono'">Sleeping to see what happens</div><div style="margin:0px;font-size:18px;font-family:'Andale Mono'">uhub0: 1 port with 1 removable, self powered</div></div><div><br></div><div><br></div><div><br><div><blockquote type="cite"><div><div><div>On Jul 11, 2016, at 10:37 AM, Deval Shah <<a href="mailto:deval.maker@gmail.com" target="_blank">deval.maker@gmail.com</a>> wrote:</div><br></div></div><div><div><div><div dir="ltr"><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif">Hello all,</div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif"><br></div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif">I am trying to add usb_ethernet (smsc) driver for raspberry pi for both USB and Ethernet support.</div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif">Now I have added the required files. But the USB device is not getting power. To get the compilation error-less, I have applied a hack.</div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif"><br></div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif">if_smsc.c is using the function “usbd_m_copy_in” which is present in the file sys/dev/usb/usb_busdma.c. But due to this macro #if USB_HAVE_MBUF the function was not getting compiled. So I have commented out the macro and let the function compile.</div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif"><br></div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif">Now ideally I should have used the DMA controller. Here I don't know the status of DMA's functions and their usage. Any pointers on that ?</div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif">I believe the problem is secondary for the USB to function. Anyhow the USB devices should get the power if the code is added. I suspect there is no proper linking between the drivers. (i.e. dwcotg, bcm283x_dwcotg, ushub, smsc, uhub, usb.) I would like some insights on how these interact.</div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif"><br></div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif">I have added following lines in the nexus-devices.h file under Raspberry-pi-BSP.</div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif"><br></div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif">SYSINIT_DRIVER_REFERENCE(bcm283x_dwcotg, nexus);</div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif">SYSINIT_DRIVER_REFERENCE(smsc, uhub);</div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif">SYSINIT_DRIVER_REFERENCE(smsc, uether);</div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif">SYSINIT_DRIVER_REFERENCE(smsc, usb);</div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif">SYSINIT_DRIVER_REFERENCE(smsc, ether);</div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif">SYSINIT_DRIVER_REFERENCE(smsc, miibus);</div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif"><br></div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif">I am also attaching the log of INIT01 Test.</div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif"><br></div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif">I need help at this point. I am kind of stuck here.</div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif"><br></div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif">Thank you in advance.</div><div style="margin:0px;padding:0px;border:0px;font-size:13px;line-height:17.03px;font-family:Arial,sans-serif">Deval Shah</div><div data-smartmail="gmail_signature"><div dir="ltr"><div></div></div></div>
</div>
</div></div><span><libbsd-init01-test.log></span>_______________________________________________<br>devel mailing list<br><a href="mailto:devel@rtems.org" target="_blank">devel@rtems.org</a><br><a href="http://lists.rtems.org/mailman/listinfo/devel" target="_blank">http://lists.rtems.org/mailman/listinfo/devel</a></div></blockquote></div><br></div></div></blockquote></div><br><br clear="all"><div><br></div></div></div><span class="HOEnZb"><font color="#888888">-- <br><div data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div>Deval Shah</div><div>Graduate Student,</div><div><div style="font-size:12.8px">B.E. (Hons.) Electrical and Electronics Engineering<br></div><div style="font-size:12.8px"><a href="http://www.bits-pilani.ac.in/hyderabad/" style="color:rgb(17,85,204);font-size:12.8px" target="_blank">BITS Pilani Hyderabad Campus</a></div></div><img src="https://encrypted-tbn2.gstatic.com/images?q=tbn:ANd9GcQrfqfQ2BeDwbmyqDm6xXZtDzweCXlsUaVTjJkCOsZ3eyztVIs8dg"><br></div><div><a href="https://github.com/deval-maker" target="_blank">Github Profile</a></div></div></div></div>
</font></span></div>
</blockquote></div><br></div>