Re: [PATCH 2/7] xfs: remove xfs_buf_get / xfs_buf_read

Christoph Hellwig
2009-11-16T11:03:15Z

On Mon, Nov 16, 2009 at 02:15:12PM +1100, Dave Chinner wrote:
> On Sat, Nov 14, 2009 at 11:17:19AM -0500, Christoph Hellwig wrote:
> > The two interfaces are highl confusing as they do have a flags argument
> > which gets ignored and replaced with default flags. Switch the few remaining
> > callers to use xfs_buf_get_flags and xfs_buf_read_flags instead and remove
> > these wrappers.
> >
> > Signed-off-by: Christoph Hellwig <hch@lst.de>
>
> Personally I would have dropped the *_flags from the function names
> as well (so everything calls xfs_buf_get() or xfs_buf_read()) but
> it doesn't really matter....

Maybe. The issue would be if we forward-port some code that expects it
can pass random crap in the flags field will get different behaviour
now. Then again it'll blow up fast enough to notice..

> > + XFS_AGB_TO_DADDR(mp, agno, XFS_BNO_BLOCK(mp)),
> > + BTOBB(mp->m_sb.sb_blocksize), XBF_LOCK | XBF_MAPPED);
>
> That looks wider than 80 columns. Same for the other conversions,
> too.

I'll fix it.