xfs: Remove the macro XFS_BUFTARG_NAME

Remove the definition and usages of the macro XFS_BUFTARG_NAME.

Signed-off-by: Chandra Seetharaman <sekharan@us.ibm.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Alex Elder <aelder@sgi.com>
This commit is contained in:
Chandra Seetharaman 2011-07-22 23:40:46 +00:00 коммит произвёл Alex Elder
Родитель 49074c069c
Коммит c35a549c8b
4 изменённых файлов: 10 добавлений и 7 удалений

Просмотреть файл

@ -1480,7 +1480,7 @@ xfs_setsize_buftarg_flags(
if (set_blocksize(btp->bt_bdev, sectorsize)) { if (set_blocksize(btp->bt_bdev, sectorsize)) {
xfs_warn(btp->bt_mount, xfs_warn(btp->bt_mount,
"Cannot set_blocksize to %u on device %s\n", "Cannot set_blocksize to %u on device %s\n",
sectorsize, XFS_BUFTARG_NAME(btp)); sectorsize, xfs_buf_target_name(btp));
return EINVAL; return EINVAL;
} }

Просмотреть файл

@ -228,8 +228,13 @@ extern void xfs_buf_delwri_promote(xfs_buf_t *);
extern int xfs_buf_init(void); extern int xfs_buf_init(void);
extern void xfs_buf_terminate(void); extern void xfs_buf_terminate(void);
#define xfs_buf_target_name(target) \ static inline const char *
({ char __b[BDEVNAME_SIZE]; bdevname((target)->bt_bdev, __b); __b; }) xfs_buf_target_name(struct xfs_buftarg *target)
{
static char __b[BDEVNAME_SIZE];
return bdevname(target->bt_bdev, __b);
}
#define XFS_BUF_ZEROFLAGS(bp) \ #define XFS_BUF_ZEROFLAGS(bp) \
@ -292,8 +297,6 @@ static inline int xfs_buf_ispinned(struct xfs_buf *bp)
#define XFS_BUF_FINISH_IOWAIT(bp) complete(&bp->b_iowait); #define XFS_BUF_FINISH_IOWAIT(bp) complete(&bp->b_iowait);
#define XFS_BUFTARG_NAME(target) xfs_buf_target_name(target)
static inline void xfs_buf_relse(xfs_buf_t *bp) static inline void xfs_buf_relse(xfs_buf_t *bp)
{ {
xfs_buf_unlock(bp); xfs_buf_unlock(bp);

Просмотреть файл

@ -975,7 +975,7 @@ xfs_buf_iodone_callbacks(
time_after(jiffies, (lasttime + 5*HZ))) { time_after(jiffies, (lasttime + 5*HZ))) {
lasttime = jiffies; lasttime = jiffies;
xfs_alert(mp, "Device %s: metadata write error block 0x%llx", xfs_alert(mp, "Device %s: metadata write error block 0x%llx",
XFS_BUFTARG_NAME(bp->b_target), xfs_buf_target_name(bp->b_target),
(__uint64_t)XFS_BUF_ADDR(bp)); (__uint64_t)XFS_BUF_ADDR(bp));
} }
lasttarg = bp->b_target; lasttarg = bp->b_target;

Просмотреть файл

@ -104,7 +104,7 @@ xfs_ioerror_alert(
xfs_alert(mp, xfs_alert(mp,
"I/O error occurred: meta-data dev %s block 0x%llx" "I/O error occurred: meta-data dev %s block 0x%llx"
" (\"%s\") error %d buf count %zd", " (\"%s\") error %d buf count %zd",
XFS_BUFTARG_NAME(bp->b_target), xfs_buf_target_name(bp->b_target),
(__uint64_t)blkno, func, (__uint64_t)blkno, func,
bp->b_error, XFS_BUF_COUNT(bp)); bp->b_error, XFS_BUF_COUNT(bp));
} }