lkml.org 
[lkml]   [2020]   [Nov]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 5.4 040/151] xfs: fix scrub flagging rtinherit even if there is no rt device
    Date
    From: Darrick J. Wong <darrick.wong@oracle.com>

    [ Upstream commit c1f6b1ac00756a7108e5fcb849a2f8230c0b62a5 ]

    The kernel has always allowed directories to have the rtinherit flag
    set, even if there is no rt device, so this check is wrong.

    Fixes: 80e4e1268802 ("xfs: scrub inodes")
    Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
    Reviewed-by: Christoph Hellwig <hch@lst.de>
    Signed-off-by: Sasha Levin <sashal@kernel.org>
    ---
    fs/xfs/scrub/inode.c | 3 +--
    1 file changed, 1 insertion(+), 2 deletions(-)

    diff --git a/fs/xfs/scrub/inode.c b/fs/xfs/scrub/inode.c
    index 6d483ab29e639..1bea029b634a6 100644
    --- a/fs/xfs/scrub/inode.c
    +++ b/fs/xfs/scrub/inode.c
    @@ -121,8 +121,7 @@ xchk_inode_flags(
    goto bad;

    /* rt flags require rt device */
    - if ((flags & (XFS_DIFLAG_REALTIME | XFS_DIFLAG_RTINHERIT)) &&
    - !mp->m_rtdev_targp)
    + if ((flags & XFS_DIFLAG_REALTIME) && !mp->m_rtdev_targp)
    goto bad;

    /* new rt bitmap flag only valid for rbmino */
    --
    2.27.0


    \
     
     \ /
      Last update: 2020-11-17 14:27    [W:3.823 / U:0.100 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site