Linux-NVME Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@lst.de>
To: Sagi Grimberg <sagi@grimberg.me>
Cc: Keith Busch <kbusch@kernel.org>,
	Chaitanya Kulkarni <Chaitanya.Kulkarni@wdc.com>,
	Christoph Hellwig <hch@lst.de>,
	linux-nvme@lists.infradead.org
Subject: Re: [PATCH] nvme: revert commit 1293477f4f32 as it is breaking BLKROSET
Date: Fri, 6 Nov 2020 18:59:49 +0100	[thread overview]
Message-ID: <20201106175949.GA7529@lst.de> (raw)
In-Reply-To: <20201106171835.38236-1-sagi@grimberg.me>

On Fri, Nov 06, 2020 at 09:18:35AM -0800, Sagi Grimberg wrote:
> The offending commit breaks BLKROSET ioctl because a device
> revalidation will blindly override BLKROSET setting.
> 
> The author should resubmit this commit in a way that does
> not break BLKROSET.

Let's fix this properly instead of a blind revert.

> -	if (id->nsattr & NVME_NS_ATTR_RO)
> -		set_disk_ro(disk, true);
> -	else
> -		set_disk_ro(disk, false);

Just dropping the else part is probably enough for now, although
as a follow on we should probably add a "hard read-only" state to
the block layer.

_______________________________________________
Linux-nvme mailing list
Linux-nvme@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-nvme

  reply	other threads:[~2020-11-06 18:00 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-06 17:18 [PATCH] nvme: revert commit 1293477f4f32 as it is breaking BLKROSET Sagi Grimberg
2020-11-06 17:59 ` Christoph Hellwig [this message]
2020-11-06 19:02   ` Sagi Grimberg
     [not found]     ` <AEE672B4-1BEA-4DBF-9E86-0C443C10F842@wdc.com>
2020-11-06 19:52       ` Sagi Grimberg
2020-11-09  8:52     ` Christoph Hellwig
2020-11-09 10:29       ` Sagi Grimberg

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=20201106175949.GA7529@lst.de \
    --to=hch@lst.de \
    --cc=Chaitanya.Kulkarni@wdc.com \
    --cc=kbusch@kernel.org \
    --cc=linux-nvme@lists.infradead.org \
    --cc=sagi@grimberg.me \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox