[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <200911191838.11791.bzolnier@gmail.com>
Date: Thu, 19 Nov 2009 18:38:11 +0100
From: Bartlomiej Zolnierkiewicz <bzolnier@...il.com>
To: Alan Cox <alan@...rguk.ukuu.org.uk>
Cc: Alan Cox <alan@...ux.intel.com>, linux-kernel@...r.kernel.org,
linux-ide@...r.kernel.org, Jeff Garzik <jgarzik@...ox.com>
Subject: Re: [PATCH 4/5] pata: Update experimental tags
On Thursday 19 November 2009 17:27:38 Alan Cox wrote:
> > > > already have a buggy cable detection (since ->pre_reset ignores the mandatory
> > >
> > > Wrong.
> >
> > You cannot know it unless you know how chip operates internally. That's it.
>
> Read the code. How the chip operates is irrelevant.
lol, there is a genuine cable detection bug in pata_hpt3x2n on closer look...
Jeff, please apply the patch below.
From: Bartlomiej Zolnierkiewicz <bzolnier@...il.com>
Subject: [PATCH] pata_hpt3x2n: fix cable detection
The detection was reversed between primary and secondary ports.
Fix it to match hpt366 and the vendor driver.
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@...il.com>
---
drivers/ata/pata_hpt3x2n.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: b/drivers/ata/pata_hpt3x2n.c
===================================================================
--- a/drivers/ata/pata_hpt3x2n.c
+++ b/drivers/ata/pata_hpt3x2n.c
@@ -133,7 +133,7 @@ static int hpt3x2n_cable_detect(struct a
/* Restore state */
pci_write_config_byte(pdev, 0x5B, scr2);
- if (ata66 & (1 << ap->port_no))
+ if (ata66 & (2 >> ap->port_no))
return ATA_CBL_PATA40;
else
return ATA_CBL_PATA80;
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists