All of lore.kernel.org
 help / color / mirror / Atom feed
From: Steve French <smfrench@gmail.com>
To: Ronnie Sahlberg <lsahlber@redhat.com>
Cc: linux-cifs <linux-cifs@vger.kernel.org>
Subject: Re: [PATCH] cifs: when extending a file with falloc we should make files not-sparse
Date: Tue, 31 May 2022 15:58:05 -0700	[thread overview]
Message-ID: <CAH2r5mtxgpxj6uThwG7SaTT1EQ5_GUkv8UOKDcG5ZbY74Ytgww@mail.gmail.com> (raw)
In-Reply-To: <20220531224838.425356-1-lsahlber@redhat.com>

will merge to cifs-2.6.git for-next and cc:stable

On Tue, May 31, 2022 at 3:48 PM Ronnie Sahlberg <lsahlber@redhat.com> wrote:
>
> as this is the only way to make sure the region is allocated.
> Fix the conditional that was wrong and only tried to make already
> non-sparse files non-sparse.
>
> Signed-off-by: Ronnie Sahlberg <lsahlber@redhat.com>
> ---
>  fs/cifs/smb2ops.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/fs/cifs/smb2ops.c b/fs/cifs/smb2ops.c
> index d7ade739cde1..03ab28c341c4 100644
> --- a/fs/cifs/smb2ops.c
> +++ b/fs/cifs/smb2ops.c
> @@ -3859,7 +3859,7 @@ static long smb3_simple_falloc(struct file *file, struct cifs_tcon *tcon,
>                 if (rc)
>                         goto out;
>
> -               if ((cifsi->cifsAttrs & FILE_ATTRIBUTE_SPARSE_FILE) == 0)
> +               if (cifsi->cifsAttrs & FILE_ATTRIBUTE_SPARSE_FILE)
>                         smb2_set_sparse(xid, tcon, cfile, inode, false);
>
>                 eof = cpu_to_le64(off + len);
> --
> 2.35.3
>


-- 
Thanks,

Steve

      reply	other threads:[~2022-05-31 22:58 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-31 22:48 [PATCH] cifs: when extending a file with falloc we should make files not-sparse Ronnie Sahlberg
2022-05-31 22:58 ` Steve French [this message]

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=CAH2r5mtxgpxj6uThwG7SaTT1EQ5_GUkv8UOKDcG5ZbY74Ytgww@mail.gmail.com \
    --to=smfrench@gmail.com \
    --cc=linux-cifs@vger.kernel.org \
    --cc=lsahlber@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.