[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20070827110226.GA15362@pingi.kke.suse.de>
Date: Mon, 27 Aug 2007 13:02:26 +0200
From: Karsten Keil <kkeil@...e.de>
To: isdn4linux@...tserv.isdn4linux.de, netdev@...r.kernel.org
Subject: Re: [PATCH] isdn capi driver broken on 64 bit.
On Fri, Aug 24, 2007 at 11:08:11AM -0700, Stephen Hemminger wrote:
> The following driver API is broken on any architecture with 64 bit addresses.
> because of cast that loses high bits.
>
> Signed-off-by: Stephen Hemminger <shemminger@...ux-foundation.org>
>
>
> --- a/drivers/isdn/capi/capidrv.c 2007-06-25 09:03:12.000000000 -0700
> +++ b/drivers/isdn/capi/capidrv.c 2007-08-24 11:06:46.000000000 -0700
> @@ -1855,6 +1855,9 @@ static int if_sendbuf(int id, int channe
> return 0;
> }
> datahandle = nccip->datahandle;
> +
> + /* This won't work on 64 bit! */
> + BUILD_BUG_ON(sizeof(skb->data) > sizeof(u32));
> capi_fill_DATA_B3_REQ(&sendcmsg, global.ap.applid, card->msgid++,
> nccip->ncci, /* adr */
> (u32) skb->data, /* Data */
NACK.
It is not a BUG.
This is OK, since this field must have a value and on 32 it has the correct
one) On 64 bit this field is ignored (but also need a value, random data is
bad as well).
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists