From: Jens Axboe <axboe@suse.de>
To: Blaisorblade <blaisorblade@yahoo.it>
Cc: akpm@osdl.org, jdike@addtoit.com, bstroesser@fujitsu-siemens.com,
linux-kernel@vger.kernel.org,
user-mode-linux-devel@lists.sourceforge.net
Subject: Re: [patch 7/7] uml ubd: handle readonly status
Date: Tue, 26 Apr 2005 10:22:48 +0200 [thread overview]
Message-ID: <20050426082247.GB1851@suse.de> (raw)
In-Reply-To: <200504252120.15493.blaisorblade@yahoo.it>
On Mon, Apr 25 2005, Blaisorblade wrote:
> On Monday 25 April 2005 12:16, Jens Axboe wrote:
> > On Sun, Apr 24 2005, blaisorblade@yahoo.it wrote:
> > > @@ -1099,6 +1104,7 @@ static int prepare_request(struct reques
> > > if((rq_data_dir(req) == WRITE) && !dev->openflags.w){
> > > printk("Write attempted on readonly ubd device %s\n",
> > > disk->disk_name);
> > > + WARN_ON(1); /* This should be impossible now */
> > > end_request(req, 0);
> > > return(1);
> > > }
> >
> > I don't think that's a sound change. The WARN_ON() is strictly only
> > really useful for when you need the stack trace for something
> > interesting. As the io happens async, you will get a boring trace that
> > doesn't contain any valuable information.
> Ok, removed, and resending the patch, is the rest ok? I.e. is that
> supposed to work? I gave a walk around and it seemed that the code
> handles set_{disk,device}_ro() even during the open, but I'm no block
> layer expert.
I'd keep the checks for sanity. Although the set_disk/device_ro prevents
regular fs write mounts, a buggy layered drive could still send down a
write by accident.
--
Jens Axboe
prev parent reply other threads:[~2005-04-26 8:23 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-04-24 18:19 [patch 7/7] uml ubd: handle readonly status blaisorblade
2005-04-25 10:16 ` Jens Axboe
2005-04-25 19:20 ` Blaisorblade
2005-04-26 8:22 ` Jens Axboe [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=20050426082247.GB1851@suse.de \
--to=axboe@suse.de \
--cc=akpm@osdl.org \
--cc=blaisorblade@yahoo.it \
--cc=bstroesser@fujitsu-siemens.com \
--cc=jdike@addtoit.com \
--cc=linux-kernel@vger.kernel.org \
--cc=user-mode-linux-devel@lists.sourceforge.net \
/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