public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Tejun Heo <htejun@gmail.com>
To: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Cc: Jeff Garzik <jgarzik@pobox.com>,
	axboe@suse.de, James.Bottomley@steeleye.com,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH Linux 2.6.12-rc5-mm2 08/09] blk: update IDE to use the new blk_ordered.
Date: Tue, 07 Jun 2005 11:26:10 +0900	[thread overview]
Message-ID: <42A505C2.6030206@gmail.com> (raw)
In-Reply-To: <58cb370e050605071472e95465@mail.gmail.com>


  Hello, Jeff.
  Hello, Bartlomiej.

Bartlomiej Zolnierkiewicz wrote:
> On 6/5/05, Jeff Garzik <jgarzik@pobox.com> wrote:
> 
>>Tejun Heo wrote:
>>
>>>@@ -176,6 +176,18 @@ static ide_startstop_t __ide_do_rw_disk(
>>>                      lba48 = 0;
>>>      }
>>>
>>>+     if (blk_fua_rq(rq) &&
>>>+         (!rq_data_dir(rq) || !drive->select.b.lba || !lba48)) {
>>>+             if (!rq_data_dir(rq))
>>>+                     printk(KERN_WARNING "%s: FUA READ unsupported\n",
>>>+                            drive->name);
>>>+             else
>>>+                     printk(KERN_WARNING "%s: FUA request received but "
>>>+                            "cannot use LBA48\n", drive->name);
>>>+             ide_end_request(drive, 0, 0);
>>>+             return ide_stopped;
>>>+     }
>>>+
>>
>>
>>Does this string of tests really need to be added to the main fast path?
>>
>>It would be better to simply guarantee that this check need never exist
>>in the IDE driver, by guaranteeing that the block layer will never send
>>a FUA-READ command to a driver that does not wish it.
>>
>>        Jeff

  I am not particulary proud of the way I've modified the IDE driver 
but, to defend my ass a bit, the structure of __ide_do_rw_disk() was a 
little bit awkward to add FUA support as it first loads all address 
registers and then looks what to execute, and I didn't want to load 
taskfile registers only to abort the command.

  Currently none issues FUA READs, so the rq_data_dir() test can go away 
but I think it's just nice to have it there for completeness.  As the 
whole test is invoked only when blk_fua_rq() is true, I don't think the 
overhead will be anything accountable (or reducible).  And for the 
following select.b.lba and lba48 tests, we actually only need the lba48 
test but I wasn't really sure whether lba48 implies select.b.lba.  It 
seems it currently does but I couldn't find anything that guarantees it 
by design.  Bartlomiej, is it safe to skip select.b.lba test?

  I'll try to make it look better.  If you have any ideas, please let me 
know.

> 
> 
> Seconded, plus please use <linux/ata.h> instead of <linux/hdreg.h>
> for adding new opcodes.

  will do.

  Thank you a lot.

-- 
tejun

  reply	other threads:[~2005-06-07  2:26 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-06-05  5:57 [PATCH Linux 2.6.12-rc5-mm2 00/09] blk: ordered request reimplementation (take 2, for review) Tejun Heo
2005-06-05  5:57 ` [PATCH Linux 2.6.12-rc5-mm2 01/09] blk: add @uptodate to end_that_request_last() and @error to rq_end_io_fn() Tejun Heo
2005-06-05  5:57 ` [PATCH Linux 2.6.12-rc5-mm2 02/09] blk: make scsi use -EOPNOTSUPP instead of -EIO on ILLEGAL_REQUEST Tejun Heo
2005-06-05  7:10   ` Jeff Garzik
2005-06-07  1:34     ` Tejun Heo
2005-06-05  5:57 ` [PATCH Linux 2.6.12-rc5-mm2 03/09] blk: make ide use -EOPNOTSUPP instead of -EIO on ABRT_ERR Tejun Heo
2005-06-05  5:57 ` [PATCH Linux 2.6.12-rc5-mm2 04/09] blk: separate out bio init part from __make_request Tejun Heo
2005-06-05  5:57 ` [PATCH Linux 2.6.12-rc5-mm2 05/09] blk: reimplement handling of barrier request Tejun Heo
2005-06-05  5:57 ` [PATCH Linux 2.6.12-rc5-mm2 06/09] blk: update SCSI to use the new blk_ordered Tejun Heo
2005-06-05  7:08   ` Jeff Garzik
2005-06-07  1:58     ` Tejun Heo
2005-06-05  5:57 ` [PATCH Linux 2.6.12-rc5-mm2 07/09] blk: update libata " Tejun Heo
2005-06-05  7:02   ` Jeff Garzik
2005-06-07  2:11     ` Tejun Heo
2005-06-05  5:57 ` [PATCH Linux 2.6.12-rc5-mm2 08/09] blk: update IDE " Tejun Heo
2005-06-05  6:47   ` Jeff Garzik
2005-06-05 14:14     ` Bartlomiej Zolnierkiewicz
2005-06-07  2:26       ` Tejun Heo [this message]
2005-06-05  5:57 ` [PATCH Linux 2.6.12-rc5-mm2 09/09] blk: debug messages Tejun Heo

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=42A505C2.6030206@gmail.com \
    --to=htejun@gmail.com \
    --cc=James.Bottomley@steeleye.com \
    --cc=axboe@suse.de \
    --cc=bzolnier@gmail.com \
    --cc=jgarzik@pobox.com \
    --cc=linux-kernel@vger.kernel.org \
    /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