This is the mail archive of the ecos-patches@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: synch eth patch


>>>>> "Jani" == Jani Monoses <jani@iv.ro> writes:

    Jani> I did mean to send it to the list, sorry.
    >> note: this should really be a public discussion.  My opinion is
    >> not the only one that counts :-)

    >> My question would be - "does the synthetic ethernet driver build 
    >> [without changes] when using one of the other stacks?"  If so, then
    >> IMO it's not the driver's fault.

    Jani> mine is "do other drivers build with lwIP?" - yes :)
    Jani> one of them actually defines EINVAL to be 2 before using it.

Yes, arm/ks32c500. However #define'ing a system error code inside a
device driver is a very bad idea and that driver should really be
cleaned up. Especially since the error package #define's EINVAL as 22
rather than 2.

EINVAL should always be available - most serial drivers depend on it.
I believe the correct solution is to make sure that EINVAL is always
#define'd in the synthetic target ethernet driver, probably by an
explicit #include of <cyg/error/codes.h>. I'll try to look into this
today or tomorrow.

Bart


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]