[haiku-development] Re: ipro1000 (e1000) are now 3 drivers in freebsd

  • From: Fredrik Modèen <fredrik@xxxxxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Wed, 15 Jun 2011 13:09:35 +0200 (CEST)

> Fredrik Modèen<fredrik@xxxxxxxxx> wrote:
>> Can be that I was too fast about this. All function etc. has their own
>> name in if_em.c and if_lem.c what I do have problem with when having
>> both
>> these file in the same build are. Multi defines of devclass_t
>> em_devclass.
>> How do I solve this if not extern will do it?
> What do you mean with "too fast about this"? About what?
> If those are separate drivers, they will obviously be separate drivers in
> Haiku as well (unless you went through the effort of merging them again)
> which also solves any multiple definitions.
Sorry. About the driver being 3 drivers in one. It looks like FreeBSD are
only making one file from e1000.

From a FreeBSD commit of if_lem.c
"       - Using driver devclass, seperate legacy (pre-pcie) code
          into a seperate source file. This will at least help
          protect against regression issues. It compiles along
          with em, and is transparent to end use, devices in each
          appear to be 'emX'. When using em in a modular form this
          also allows the legacy stuff to be defined out.
But my problem now if I try to compile both files are “Multi defines of
devclass_t em_devclass” I don’t have access to the exact error

It’s in if_em.c like this
devclass_t em_devclass;

and in if_lem.c
extern devclass_t em_devclass;

> Bye,
>    Axel.

Fredrik Modèen

Other related posts: