Date: Thu, 11 Oct 2012 08:33:40 -0600 From: Ian Lepore <freebsd@damnhippie.dyndns.org> To: Tim Kientzle <tim@kientzle.com> Cc: arm@freebsd.org, Oleksandr Tymoshenko <gonzo@freebsd.org> Subject: Re: Towards an ARM system-building script Message-ID: <1349966020.1123.63.camel@revolution.hippie.lan> In-Reply-To: <CB80A684-40B8-48FF-8AB2-9CD96475FB13@kientzle.com> References: <DD05E72B9F474BFE96B6A4B050D2A18A@gmail.com> <0DCAC001-FF06-431A-A486-2B50BE913B0D@bsdimp.com> <FAA208C1-2872-4BB6-A7EC-04C757533CA4@kientzle.com> <7E18623F-3945-4EA0-B332-5A5C717B20F0@kientzle.com> <9896AA3E-D8A0-4CE8-8160-4672AA07388F@cheney.net> <6B74ADD7-3266-4919-BEB4-B10E0C1BAB58@kientzle.com> <5679C679-A434-4714-BE61-4DC093DA7F34@kientzle.com> <CAGtf9xPgFeDHMnKRacYfUg1BKJx0MjfmX=DWOc-X2NoJfPVB9Q@mail.gmail.com> <8C1192B3-EC56-4D9E-824E-774700FB2EE9@kientzle.com> <CAGtf9xO%2Bz8JhCY-TirNwh-R_zW=hY%2BbPh-4x%2Bz3H0TQHu1aXAQ@mail.gmail.com> <CAGtf9xNr9_Bh1Krw8rB1VkqKMx0eQBOC7SFuGkwS6GD8dHQdLw@mail.gmail.com> <CAGtf9xPzhq8fnarz_fNepfMkRbLc3aGL47DGm4b8K6uV_Do3sg@mail.gmail.com> <CACfq092Nakk=DF8_DRttBLwG8sw_3BdhTkfrNoYh7CmgtXQaBA@mail.gmail.com> <1349876577.1123.30.camel@revolution.hippie.lan> <CACfq092AAKXNU3fo2g0gmkHTPEEDXYsg7woaVDZDbU_mhe5S_Q@mail.gmail.com> <CB80A684-40B8-48FF-8AB2-9CD96475FB13@kientzle.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 2012-10-11 at 00:16 -0700, Tim Kientzle wrote: > On Oct 10, 2012, at 3:08 PM, Giovanni Trematerra wrote: > > > On Wed, Oct 10, 2012 at 3:42 PM, Ian Lepore > > <freebsd@damnhippie.dyndns.org> wrote: > >> On Tue, 2012-10-09 at 23:42 +0200, Giovanni Trematerra wrote: > >>> I booted a kernel with your suggestion but I get a panic during > >>> initialization of ue0 I think > >> > >> It looks like bootpc_init() is getting called before USB has found the > >> ethernet adapter. It might be fixable with a simple patch such as the > >> following, but I really don't know whether this will work, and even if > >> it does, whether it's a good idea (hopefully someone more knowledgable > >> will offer an opinion). But if nothing else it's an interesting > >> experiment to try. > > > > I think the patch is wrong at least in my case. > > I had to run the "usb start" command from U-boot to have > > ethernet card of PandaBoard working. > > What happens if you disable BOOTP in the kernel? > > That might help clarify whether the Ethernet isn't > working at all or whether the Ethernet isn't getting > started early enough for BOOTP. > > Tim > It's very clear from the panic message and the dmesg output that the usb stack hasn't finished enumerating the bus and thus hasn't instantiated the ue0 device before bootpc_init() is called. The only part I'm unsure about is whether it's safe to call root_mount_wait() from within boopc_init(). I don't know if there are any rules about calling root_mount_wait() (locking, which thread(s) can call it, etc). I'm also a bit unsure about the whole concept of using root_mount_wait() as a proxy for "all usb devices have been enumerated." That seems, conceptually, like relying on an undocumented side effect of a routine. I'm also not sure it actually works... on freebsd 8.2 at least, I've seen usb devices appear after root is mounted (hard-wired onto the motherboard devices, not removables). -- Ian
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1349966020.1123.63.camel>