From: Jeff Garzik <jgarzik@pobox.com>
To: Tejun Heo <htejun@gmail.com>
Cc: alan@lxorguk.ukuu.org.uk, linux-ide@vger.kernel.org
Subject: Re: [PATCH 2/3] libata: add per-dev pio/mwdma/udma_mask
Date: Fri, 24 Mar 2006 09:30:02 -0500 [thread overview]
Message-ID: <4424026A.1080504@pobox.com> (raw)
In-Reply-To: <11431768704184-git-send-email-htejun@gmail.com>
Tejun Heo wrote:
> -static unsigned int ata_dev_xfermask(struct ata_port *ap,
> - struct ata_device *dev)
> +static void ata_dev_xfermask(struct ata_port *ap, struct ata_device *dev)
> {
> unsigned long xfer_mask;
> int i;
> @@ -2677,6 +2676,8 @@ static unsigned int ata_dev_xfermask(str
> struct ata_device *d = &ap->device[i];
> if (!ata_dev_present(d))
> continue;
> + xfer_mask &= ata_pack_xfermask(d->pio_mask, d->mwdma_mask,
> + d->udma_mask);
> xfer_mask &= ata_id_xfermask(d->id);
> if (ata_dma_blacklisted(d))
> xfer_mask &= ~(ATA_MASK_MWDMA | ATA_MASK_UDMA);
> @@ -2686,7 +2687,8 @@ static unsigned int ata_dev_xfermask(str
> printk(KERN_WARNING "ata%u: dev %u is on DMA blacklist, "
> "disabling DMA\n", ap->id, dev->devno);
>
> - return xfer_mask;
> + ata_unpack_xfermask(xfer_mask, &dev->pio_mask, &dev->mwdma_mask,
> + &dev->udma_mask);
applied 1-3. You should add a TODO note somewhere, that notes that the
current implementation intentionally limits all devices on a single port
to the fastest mode on the slowest device. This is necessary for SOME
controllers but not all, and so we shouldn't do it unconditionally.
Jeff
next prev parent reply other threads:[~2006-03-24 14:30 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-03-24 5:07 [PATCHSET] libata: implement per-dev xfer masks, take#2 Tejun Heo
2006-03-24 5:07 ` [PATCH 1/3] libata: implement ata_unpack_xfermask() Tejun Heo
2006-03-24 5:07 ` [PATCH 3/3] libata: make per-dev transfer mode limits per-dev Tejun Heo
2006-03-24 5:07 ` [PATCH 2/3] libata: add per-dev pio/mwdma/udma_mask Tejun Heo
2006-03-24 14:30 ` Jeff Garzik [this message]
2006-03-25 2:14 ` [PATCH] libata: add FIXME above ata_dev_xfermask() Tejun Heo
2006-03-25 4:09 ` Jeff Garzik
2006-03-25 5:28 ` [PATCH] libata: kill trailing whitespace 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=4424026A.1080504@pobox.com \
--to=jgarzik@pobox.com \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=htejun@gmail.com \
--cc=linux-ide@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;
as well as URLs for NNTP newsgroup(s).