From: Sergei Shtylyov <sshtylyov@ru.mvista.com>
To: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Cc: linux-ide@vger.kernel.org
Subject: Re: [PATCH 9/15] ide: add PIO masks
Date: Tue, 03 Jul 2007 21:40:14 +0400 [thread overview]
Message-ID: <468A89FE.1040806@ru.mvista.com> (raw)
In-Reply-To: <200706302107.42458.bzolnier@gmail.com>
Hello.
Bartlomiej Zolnierkiewicz wrote:
> * Add ATA_PIO[0-6] defines to <linux/ata.h>.
> * Add ->pio_mask field to ide_pci_device_t and ide_hwif_t.
> * Add PIO masks to host drivers.
Hm, the next logical step would be to use the mask constants in
<linux/ata.h> for the drivers' DMA caps too...
> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
> Index: b/drivers/ide/pci/it8213.c
> ===================================================================
> --- a/drivers/ide/pci/it8213.c
> +++ b/drivers/ide/pci/it8213.c
> @@ -276,6 +276,7 @@ static void __devinit init_hwif_it8213(i
> .enablebits = {{0x41,0x80,0x80}}, \
> .bootable = ON_BOARD, \
> .host_flags = IDE_HFLAG_SINGLE, \
> + .pio_mask = ATA_PIO4, \
> }
>
> static ide_pci_device_t it8213_chipsets[] __devinitdata = {
[...]
> Index: b/drivers/ide/pci/piix.c
> ===================================================================
> --- a/drivers/ide/pci/piix.c
> +++ b/drivers/ide/pci/piix.c
> @@ -498,6 +498,7 @@ static void __devinit init_hwif_piix(ide
> .autodma = AUTODMA, \
> .enablebits = {{0x41,0x80,0x80}, {0x43,0x80,0x80}}, \
> .bootable = ON_BOARD, \
> + .pio_mask = ATA_PIO4, \
> .udma_mask = udma, \
> }
>
> @@ -517,6 +518,7 @@ static ide_pci_device_t piix_pci_info[]
> .enablebits = {{0x6d,0xc0,0x80}, {0x6d,0xc0,0xc0}},
> .bootable = ON_BOARD,
> .host_flags = IDE_HFLAG_ISA_PORTS,
> + .pio_mask = ATA_PIO4,
> },
>
> /* 3 */ DECLARE_PIIX_DEV("PIIX3", 0x00), /* no udma */
[...]
> Index: b/drivers/ide/pci/slc90e66.c
> ===================================================================
> --- a/drivers/ide/pci/slc90e66.c
> +++ b/drivers/ide/pci/slc90e66.c
> @@ -217,6 +217,7 @@ static ide_pci_device_t slc90e66_chipset
> .autodma = AUTODMA,
> .enablebits = {{0x41,0x80,0x80}, {0x43,0x80,0x80}},
> .bootable = ON_BOARD,
> + .pio_mask = ATA_PIO4,
> };
>
> static int __devinit slc90e66_init_one(struct pci_dev *dev, const struct
pci_device_id *id)
Strictly speaking, these Intel/SMsC/ITE chips don't support PIO mode 1,
only modes 0 and 2 thru 4 but the drivers are just using PIO0 timings for PIO1...
> Index: b/drivers/ide/pci/scc_pata.c
> ===================================================================
> --- a/drivers/ide/pci/scc_pata.c
> +++ b/drivers/ide/pci/scc_pata.c
> @@ -734,6 +734,7 @@ static void __devinit init_hwif_scc(ide_
> .autodma = AUTODMA, \
> .bootable = ON_BOARD, \
> .host_flags = IDE_HFLAG_SINGLE, \
> + .pio_mask = ATA_PIO4, \
Erm, formatting nit: leading spaces () and contrarywise, space ISO tab
after field name wouldn't have caught an eye. B-)
Well, I see that the style is borken all over the macros, no forget about
spaces...
> }
>
> static ide_pci_device_t scc_chipsets[] __devinitdata = {
> Index: b/drivers/ide/pci/sgiioc4.c
> ===================================================================
> --- a/drivers/ide/pci/sgiioc4.c
> +++ b/drivers/ide/pci/sgiioc4.c
> @@ -586,6 +586,7 @@ ide_init_sgiioc4(ide_hwif_t * hwif)
> hwif->ultra_mask = 0x0; /* Disable Ultra DMA */
> hwif->mwdma_mask = 0x2; /* Multimode-2 DMA */
> hwif->swdma_mask = 0x2;
> + hwif->pio_mask = 0x00;
"I don't believe!" :-D Should be at least supporting PIO0. ;-)
> hwif->tuneproc = NULL; /* Sets timing for PIO mode */
... but it won't matter anyway due to missing tuneproc() method.
MBR, Sergei
next prev parent reply other threads:[~2007-07-03 17:38 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-06-30 19:07 [PATCH 9/15] ide: add PIO masks Bartlomiej Zolnierkiewicz
2007-06-30 20:04 ` Jeff Garzik
2007-07-03 17:40 ` Sergei Shtylyov [this message]
2007-07-03 19:12 ` Bartlomiej Zolnierkiewicz
2007-07-06 0:40 ` Jeff Garzik
2007-07-03 19:28 ` Sergei Shtylyov
2007-07-03 20:08 ` Bartlomiej Zolnierkiewicz
2007-07-03 20:35 ` Sergei Shtylyov
2007-07-03 22:00 ` Alan Cox
2007-07-04 14:24 ` Sergei Shtylyov
2007-07-04 14:31 ` Alan Cox
2007-07-04 19:02 ` Bartlomiej Zolnierkiewicz
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=468A89FE.1040806@ru.mvista.com \
--to=sshtylyov@ru.mvista.com \
--cc=bzolnier@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).