All of lore.kernel.org
 help / color / mirror / Atom feed
From: Brian Foster <bfoster@redhat.com>
To: Yumei Huang <yuhuang@redhat.com>
Cc: linux-xfs@vger.kernel.org, david@fromorbit.com, sandeen@sandeen.net
Subject: Re: [PATCH] xfs: Fix assert failure in xfs_setattr_size()
Date: Fri, 15 Jan 2021 06:39:31 -0500	[thread overview]
Message-ID: <20210115113931.GA1405324@bfoster> (raw)
In-Reply-To: <1492355130.64829487.1610706535069.JavaMail.zimbra@redhat.com>

On Fri, Jan 15, 2021 at 05:28:55AM -0500, Yumei Huang wrote:
> An assert failure is triggered by syzkaller test due to
> ATTR_KILL_PRIV is not cleared before xfs_setattr_size.
> As ATTR_KILL_PRIV is not checked/used by xfs_setattr_size,
> just remove it from the assert.
> 
> Signed-off-by: Yumei Huang <yuhuang@redhat.com>
> ---

LGTM. Thanks for the patch.

Reviewed-by: Brian Foster <bfoster@redhat.com>

>  fs/xfs/xfs_iops.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/fs/xfs/xfs_iops.c b/fs/xfs/xfs_iops.c
> index 67c8dc9..f1e21b6 100644
> --- a/fs/xfs/xfs_iops.c
> +++ b/fs/xfs/xfs_iops.c
> @@ -846,7 +846,7 @@
>          ASSERT(xfs_isilocked(ip, XFS_MMAPLOCK_EXCL));
>          ASSERT(S_ISREG(inode->i_mode));
>          ASSERT((iattr->ia_valid & (ATTR_UID|ATTR_GID|ATTR_ATIME|ATTR_ATIME_SET|
> -                ATTR_MTIME_SET|ATTR_KILL_PRIV|ATTR_TIMES_SET)) == 0);
> +                ATTR_MTIME_SET|ATTR_TIMES_SET)) == 0);
>  
>          oldsize = inode->i_size;
>          newsize = iattr->ia_size;
> -- 
> 1.8.3.1
> 


  reply	other threads:[~2021-01-15 11:41 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <316142100.64829455.1610706461022.JavaMail.zimbra@redhat.com>
2021-01-15 10:28 ` [PATCH] xfs: Fix assert failure in xfs_setattr_size() Yumei Huang
2021-01-15 11:39   ` Brian Foster [this message]
2021-01-20 18:53   ` Christoph Hellwig
2021-01-20 19:27   ` Darrick J. Wong

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210115113931.GA1405324@bfoster \
    --to=bfoster@redhat.com \
    --cc=david@fromorbit.com \
    --cc=linux-xfs@vger.kernel.org \
    --cc=sandeen@sandeen.net \
    --cc=yuhuang@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.