xfs
[Top] [All Lists]

Re: [PATCH 3/9] xfs: add discontiguous buffer map interface

To: Dave Chinner <david@xxxxxxxxxxxxx>
Subject: Re: [PATCH 3/9] xfs: add discontiguous buffer map interface
From: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Date: Wed, 20 Jun 2012 02:53:23 -0400
Cc: xfs@xxxxxxxxxxx
In-reply-to: <1339133914-11148-4-git-send-email-david@xxxxxxxxxxxxx>
References: <1339133914-11148-1-git-send-email-david@xxxxxxxxxxxxx> <1339133914-11148-4-git-send-email-david@xxxxxxxxxxxxx>
User-agent: Mutt/1.5.21 (2010-09-15)
> +     struct xfs_buf_map      map = {
> +             .bm_bn = blkno,
> +             .bm_len = numblks,
> +     };

I'm not a big fan of creative macro use, but with the amount of copies
of these line why not add a:

#define DEFINE_SINGLE_BUF_MAP(map, blkno, numblk) \
struct xfs_buf_map (map) = { .bm_bn = (blkno), .bm_len = (numblk) };

Otherwise looks good,

Reviewed-by: Christoph Hellwig <hch@xxxxxx>

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