This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: SMSC LAN91CXX driver
Hi, Hugo.
Thanks for your detailed explanation.
>
> We're talking about the package in PACKAGES/devs/eth/smsc/lan91cxx/VERSION,
> called CYGPKG_DEVS_ETH_SMSC_LAN91CXX, right?
>
Right.
> We use it for a customer board that's like an assabet but not quite; the
> details are not public, so the module that instantiates the 91cxx driver is
> not available in anoncvs.
>
That was my guess.
>
> I believe it may not work on an assabet anyway. The assabet is rather
> untested IME; after our customer asked Intel enough times they admitted
> that the ethernet device isn't tested and is not actually connected up
> correctly. (IIRC - this from memory, disclaimers apply... could be only
> early versions of assabet that are not good - or it could be that address
> wiring "feature" that stopped us! ;-> )
>
I see. Just for test, I have changed the addressing and it works. Now
I'm
thinking how to do it in the least intrusive way.
>
> Changing the type of "base" in struct lan91cxx_priv_data {} to "unsigned
> long *" would probably do it! Use a #define that your .inl file can set to
> tell it to use long addressing instead of short.
>
Changing the pointer type wouldn't be enough because the SMC (in my
platform)
is hardwired to 16-bit mode, so the chip ignores A0 (which is A2 in
SA1110).
This makes a total 3-bit shift. Anyway, your solution would be ok for
Assabet
since the chip is hardwired to 8-bit mode. This is how the linux driver
works.
> > One more question: why isn't this driver available
> > as a package (CYGPKG_ETH_SMSC_LAN91CXX) in ecos.db ?
>
> That's a simple oversight which I shall correct right now.
>
> The clause to add is:
>
> package CYGPKG_DEVS_ETH_SMSC_LAN91CXX {
> alias { "SMSC LAN91CXX ethernet driver" lan91cxx_eth_driver lan9000_eth_driver }
> hardware
> directory devs/eth/smsc/lan91cxx
> script smsc_lan91cxx_eth_drivers.cdl
> description "Ethernet driver for SMSC LAN91CXX (LAN9000) controller."
> }
>
> anywhere in ecos.db
>
Great.
In my platform (and Assabet), the chip is in PCMCIA mode so additional
actions must be done : reset and enable on ECOR and ECSR registers.
The driver doesn't do this at present, probably I will add this but
controlled by a new config variable.
Thanks.
Jordi