lkml.org 
[lkml]   [2002]   [Mar]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Linux 2.4.19-pre3

Jens,

Please try again because that is not the real problem.
All you have shown is that we disagree on the method of page walking
between BLOCK v/s IOCTL. This is very minor and I agreed that it is
reasonable to map the IOCTL buffer in to BH or BIO so this is a net zero
of negative point.

How about attempting to describe the differences between the atomic and
what is violated by who and where. I will help you later if you get
stuck.

Regards,

Andre Hedrick

On Wed, 13 Mar 2002, Jens Axboe wrote:

> On Tue, Mar 12 2002, Marcelo Tosatti wrote:
> > So, Jens, could you please explain the problem in the interrupt handlers
> > in detail ?
>
> Ok... It affects all the pio handlers in ide-taskfile.c,
> multi-write/read as well. The address for pio transfers is calculated
> like so:
>
> va = rq->buffer + (rq->nr_sectors - rq->current_nr_sectors) * SECTOR_SIZE;
>
> which is wrong for two reasons. First of all, rq->buffer cannot be
> indexed for the entire nr_sectors range -- it's per definition only the
> first segment in the request, and can as such only be indexed within the
> first current_nr_sectors number of sectors. The above can be grossly out
> of range... Second, nr_sectors and current_nr_sectors are indexing two
> different things -- the former indexes the entire request (all segments)
> while the latter indexes only the first segments. So
>
> foo = rq->nr_sectors - rq->current_nr_sectors;
>
> makes no sense _at all_ and can only be wrong.
>
> So why does 2.4.19-pre3 work for pio at all? For the same reason that
> Andre never found this problem in 2.5 either: the taskfile interrupt
> handlers are _never_ used in pio mode. In 2.5 it was by accident, and
> when the merge happened they did indeed get used. It ate disks, very
> quickly. Take a look at drivers/ide/ide-disk.c, line 64:
>
> #ifdef CONFIG_IDE_TASKFILE_IO
> # undef __TASKFILE__IO /* define __TASKFILE__IO */
> #else /* CONFIG_IDE_TASKFILE_IO */
> # undef __TASKFILE__IO
> #endif /* CONFIG_IDE_TASKFILE_IO */
>
> It's a mess... This really should have been fixed prior to 2.4
> inclusion. Oh well.
>
> --
> Jens Axboe
>

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:24    [W:0.112 / U:0.736 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site