lkml.org 
[lkml]   [2001]   [Dec]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [Ext2-devel] [RFC] [PATCH] Clean up fs.h union for ext2
Oliver Xymoron wrote:
>
> > Minor nit: this is already done for the ext3 code, but it looks like:
> >
> > #define EXT3_I (&((inode)->u.ext3_i))
> >
> > We already have the EXT3_SB, so I thought I would be consistent with it:
> >
> > #define EXT3_SB (&((sb)->u.ext3_sb))
> >
> > Do people like the inline version better? Either way, I would like to make
> > the ext2 and ext3 codes more similar, rather than less.
>
> The ext3 macros are rather revolting, simply because they assume the
> variable name. A parameterized macro might be the best compromise:
>
> #define EXT2_I(i) (&(i->u.ext2_inode_info))
>

They _would_ be revolting, except Andreas mistyped :) We have:

#define EXT3_SB(sb) (&((sb)->u.ext3_sb))
#define EXT3_I(inode) (&((inode)->u.ext3_i))

(A number of the mm macros accidentally only work correctly if their
argument is called "page". Dunno if this is stil the case though).

-
-
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: 2005-03-22 13:14    [W:0.129 / U:0.868 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site