Re: I never liked bitfields by some reason.

David S. Miller (davem@redhat.com)
Sat, 27 Nov 1999 16:52:19 -0800


Date: Sat, 27 Nov 1999 16:53:47 -0700
From: Richard Gooch <rgooch@ras.ucalgary.ca>

Firstly: do you know *why* the code is done this way?
Secondly: how do you know your solution won't need #ifdefs as well?

Actually, the way I see it:

1) The inl() done to obtain this wn3 config value will get the
bytes right on any architecture.

2) However the bits within the bytes themselves will be incorrect
which is why Peter's change fixes his problem.

So perhaps it should be __BIG_ENDIAN_BITFIELD ifdef'd, not just
__sparc__ as to my knowledge all other big endian hosts will
have this same issue. Similar things are done in the IDE
device drivers in similar situations.

Later,
David S. Miller
davem@redhat.com

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/