lkml.org 
[lkml]   [2007]   [Mar]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: 2.6.21-rc2-mm2: drivers/net/wireless/libertas/debugfs.c addr bogosity
On Wed, Mar 07, 2007 at 03:00:57PM -0800, Andrew Morton wrote:
> On Wed, 7 Mar 2007 23:41:16 +0100
> Adrian Bunk <bunk@stusta.de> wrote:
>
> > On Tue, Mar 06, 2007 at 12:44:08AM -0800, Andrew Morton wrote:
> > >...
> > > Changes since 2.6.20-rc2-mm1:
> > >...
> > > git-netdev-all.patch
> > >...
> > > git trees
> > >...
> >
> > drivers/net/wireless/libertas/debugfs.c contains:
> > #define item_addr(n) ((u32) &((wlan_adapter *)0)->n)
> >
> > This is wrong on 64bit architectures.
>
> Is OK - it is simply yet another reimplementation of offsetof(). Hint.

Thanks for the correction - it seems C pointers and me will never become
close friends...

cu
Adrian

--

"Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
"Only a promise," Lao Er said.
Pearl S. Buck - Dragon Seed

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

\
 
 \ /
  Last update: 2007-03-08 09:05    [W:0.110 / U:1.044 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site