Re: [PATCH 2/3] xfs: inode unlink does not set AGI buffer type

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jan 21, 2015 at 11:39:39AM +1100, Dave Chinner wrote:
> From: Dave Chinner <dchinner@xxxxxxxxxx>
> 
> This leads to log recovery throwing errors like:
> 
> XFS (md0): Mounting V5 Filesystem
> XFS (md0): Starting recovery (logdev: internal)
> XFS (md0): Unknown buffer type 0!
> XFS (md0): _xfs_buf_ioapply: no ops on block 0xaea8802/0x1
> ffff8800ffc53800: 58 41 47 49 .....
> 
> Which is the AGI buffer magic number.
> 
> Ensure that we set the type appropriately in both unlink list
> addition and removal.
> 
> Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>
> ---

Reviewed-by: Brian Foster <bfoster@xxxxxxxxxx>

>  fs/xfs/xfs_inode.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/fs/xfs/xfs_inode.c b/fs/xfs/xfs_inode.c
> index 573b49c..f616c8f 100644
> --- a/fs/xfs/xfs_inode.c
> +++ b/fs/xfs/xfs_inode.c
> @@ -2051,6 +2051,7 @@ xfs_iunlink(
>  	agi->agi_unlinked[bucket_index] = cpu_to_be32(agino);
>  	offset = offsetof(xfs_agi_t, agi_unlinked) +
>  		(sizeof(xfs_agino_t) * bucket_index);
> +	xfs_trans_buf_set_type(tp, agibp, XFS_BLFT_AGI_BUF);
>  	xfs_trans_log_buf(tp, agibp, offset,
>  			  (offset + sizeof(xfs_agino_t) - 1));
>  	return 0;
> @@ -2142,6 +2143,7 @@ xfs_iunlink_remove(
>  		agi->agi_unlinked[bucket_index] = cpu_to_be32(next_agino);
>  		offset = offsetof(xfs_agi_t, agi_unlinked) +
>  			(sizeof(xfs_agino_t) * bucket_index);
> +		xfs_trans_buf_set_type(tp, agibp, XFS_BLFT_AGI_BUF);
>  		xfs_trans_log_buf(tp, agibp, offset,
>  				  (offset + sizeof(xfs_agino_t) - 1));
>  	} else {
> -- 
> 2.0.0
> 
> _______________________________________________
> xfs mailing list
> xfs@xxxxxxxxxxx
> http://oss.sgi.com/mailman/listinfo/xfs

_______________________________________________
xfs mailing list
xfs@xxxxxxxxxxx
http://oss.sgi.com/mailman/listinfo/xfs




[Index of Archives]     [Linux XFS Devel]     [Linux Filesystem Development]     [Filesystem Testing]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux