Linux-Block Archive on lore.kernel.org
 help / color / Atom feed
From: Yang Xu <xuyang2018.jy@cn.fujitsu.com>
To: <linux-block@vger.kernel.org>
Cc: Martijn Coenen <maco@android.com>
Subject: Re: [PATCH] loop: Remove redundant status flag operation
Date: Sat, 1 Aug 2020 11:04:47 +0800
Message-ID: <d2a8b662-a99a-104c-b749-c10293f71211@cn.fujitsu.com> (raw)
In-Reply-To: <1591929831-2397-1-git-send-email-xuyang2018.jy@cn.fujitsu.com>

Hi
Ping.

> Since ~LOOP_SET_STATUS_SETTABLE_FLAG is always a subset of ~LOOP_SET_STATUS_CLEARABLE_FLAGS
> ,remove this redundant flags operation.
> 
> Cc: Martijn Coenen <maco@android.com>
> Signed-off-by: Yang Xu <xuyang2018.jy@cn.fujitsu.com>
> ---
>   drivers/block/loop.c | 2 --
>   1 file changed, 2 deletions(-)
> 
> diff --git a/drivers/block/loop.c b/drivers/block/loop.c
> index c33bbbf..2a61079 100644
> --- a/drivers/block/loop.c
> +++ b/drivers/block/loop.c
> @@ -1391,8 +1391,6 @@ static int loop_clr_fd(struct loop_device *lo)
>   
>   	/* Mask out flags that can't be set using LOOP_SET_STATUS. */
>   	lo->lo_flags &= LOOP_SET_STATUS_SETTABLE_FLAGS;
> -	/* For those flags, use the previous values instead */
> -	lo->lo_flags |= prev_lo_flags & ~LOOP_SET_STATUS_SETTABLE_FLAGS;
>   	/* For flags that can't be cleared, use previous values too */
>   	lo->lo_flags |= prev_lo_flags & ~LOOP_SET_STATUS_CLEARABLE_FLAGS;
>   
> 



  reply index

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-12  2:43 Yang Xu
2020-08-01  3:04 ` Yang Xu [this message]
2020-08-06  7:45   ` Martijn Coenen
2020-08-06  8:03     ` Yang Xu

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=d2a8b662-a99a-104c-b749-c10293f71211@cn.fujitsu.com \
    --to=xuyang2018.jy@cn.fujitsu.com \
    --cc=linux-block@vger.kernel.org \
    --cc=maco@android.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

Linux-Block Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-block/0 linux-block/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-block linux-block/ https://lore.kernel.org/linux-block \
		linux-block@vger.kernel.org
	public-inbox-index linux-block

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-block


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git