All of lore.kernel.org
 help / color / mirror / Atom feed
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Cc: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>,
	linux-ide@vger.kernel.org
Subject: Re: ide patches
Date: Tue, 24 Jul 2007 07:48:15 +1000	[thread overview]
Message-ID: <1185227295.5439.131.camel@localhost.localdomain> (raw)
In-Reply-To: <46A4AA39.3030401@ru.mvista.com>

> > Ok, there's a combination of things here:
> 
> >  - First, doing a set_pio from userland (hdparm -p XX) causes the kernel
> > to disable DMA, which I think is incorrect.
> 
>     That's the way ide_config_drive_speed() works.

And I still think that's bad.

> > It's not the case with 2.6.22 from my quick tests.
> 
>    Which means that PIO autotuning is broken there, i.e. that 
> ide_config_drive_speed() not called from the driver's tuneproc() method.

Yes, the driver uses it's own function which doesn't disable DMA
permanently, which is, IMHO, the way to go. I consider the current
behaviour a regression.

> > The problem is that ide_config_drive_speed
> > disables DMA, but only re-enables it when setting a DMA speed.
> 
>     It never "re-enables" DMA. ide_dma_host_on() method is not the same as 
> ide_dma_on() which actually enables DMA.

Ugh ? It re-enables DMA in the sense that if called to configure a DMA
speed, it re-enables dma on the host, thus effectively leaving with DMA
enabled.

> > I think
> > the whole idea of having a "current speed" is bogus here, we should have
> > a separate current DMA speed and current PIO speed. We should be able to
> > set the PIO timings without stopping DMA, toggling DMA is a separate
> > affair.
> 
>     Agreed completely.

Ah good :-)

Cheers,
Ben.



  reply	other threads:[~2007-07-23 21:48 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-07-22 18:19 [PATCH] ide-pmac: fix drive->init_speed reporting Bartlomiej Zolnierkiewicz
2007-07-22 21:50 ` Benjamin Herrenschmidt
2007-07-23 21:20   ` Bartlomiej Zolnierkiewicz
2007-07-22 23:55 ` ide patches Benjamin Herrenschmidt
2007-07-23  1:21   ` Benjamin Herrenschmidt
2007-07-23  1:57     ` Benjamin Herrenschmidt
2007-07-23  2:01       ` Benjamin Herrenschmidt
2007-07-23 13:50         ` Sergei Shtylyov
2007-07-23 21:49           ` Benjamin Herrenschmidt
2007-07-23 21:22         ` Bartlomiej Zolnierkiewicz
2007-07-23 22:00           ` Benjamin Herrenschmidt
2007-07-29 10:48           ` Sergei Shtylyov
2007-07-29 14:39             ` Bartlomiej Zolnierkiewicz
2007-07-23 13:16       ` Sergei Shtylyov
2007-07-23 21:48         ` Benjamin Herrenschmidt [this message]
2007-07-23 22:06           ` Sergei Shtylyov
2007-07-23 22:08             ` Benjamin Herrenschmidt

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=1185227295.5439.131.camel@localhost.localdomain \
    --to=benh@kernel.crashing.org \
    --cc=bzolnier@gmail.com \
    --cc=linux-ide@vger.kernel.org \
    --cc=sshtylyov@ru.mvista.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
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.