netdev
[Top] [All Lists]

Re: multicast hash incorrect on big endian archs

To: Manfred Spraul <manfred@xxxxxxxxxxxxxxxx>
Subject: Re: multicast hash incorrect on big endian archs
From: "David S. Miller" <davem@xxxxxxxxxx>
Date: Mon, 4 Jun 2001 03:54:42 -0700 (PDT)
Cc: linux-kernel@xxxxxxxxxxxxxxx, netdev@xxxxxxxxxxx
In-reply-to: <3B1B564E.D83A741A@xxxxxxxxxxxxxxxx>
References: <3B1A9558.2DBAECE7@xxxxxxxxxxxxxxxx> <15130.61778.471925.245018@xxxxxxxxxxxxxxx> <3B1B3268.2A02D2C@xxxxxxxxxxxxxxxx> <3B1B564E.D83A741A@xxxxxxxxxxxxxxxx>
Sender: owner-netdev@xxxxxxxxxxx
Manfred Spraul writes:
 > That could cause alignment problems.
 > <<< from starfire.c
 > {
 >      long filter_addr;
 >      u16 mc_filter[32] __attribute__ ((aligned(sizeof(long)))); 
 > <<<
 > set_bit requires word alignment, but without the __attibute__ the
 > compiler would only guarantee 16-bit alignment. IMHO ugly.

Correction, it requires "long" alignment and that is 64-bits
on several platforms.

Later,
David S. Miller
davem@xxxxxxxxxx

<Prev in Thread] Current Thread [Next in Thread>