aboutsummaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorMing Lei <ming.lei@canonical.com>2011-09-15 10:27:11 +0800
committerJohn Rigby <john.rigby@linaro.org>2011-10-17 09:57:00 -0600
commit49c00ca5aa1b9aa367a8aa7d59a808e70719e707 (patch)
tree167990582ea11b0daeb5356a1923c77c0bb70393 /drivers
parent0c585e734331f8c80e4cdf8139e80cd97da574d3 (diff)
UBUNTU: SAUCE: ata: make DVD drive recognisable on systems with Sandybridge CPT chipset
This quirk patch fixes one kind of bug inside Intel Sandybridge CPT chipset, see reports from LP794642, LP737388, LP758433, ... Many guys have reported the problem. With help from upstream ata maintainer Tejun[1], the problem is found to be caused by 32bit PIO mode, which is introduced in the commit below: commit 0b67c7439fe2a5d76602de36854c88e2beab00b0 Author: Tejun Heo <tj@kernel.org> Date: Mon Jan 11 17:03:11 2010 +0900 ata_piix: enable 32bit PIO on SATA piix Commit 871af1210f13966ab911ed2166e4ab2ce775b99d enabled 32bit PIO for PATA piix but didn't for SATA. There's no reason not to use 32bit PIO on SATA piix. Enable it. Signed-off-by: Tejun Heo <tj@kernel.org> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: Jeff Garzik <jgarzik@redhat.com> so introduce the quirk patch to disable 32bit PIO on SATA piix for Sandybridge CPT chipset, Alan Cox has agreed on the patch[2]. SRU Justification: Impact: - without the patch, DVD drive can't be recognized on Dell optiplex 390. Fix: - After applying the patch, DVD drive can be recognized well on Dell optiplex 390. BugLink: http://bugs.launchpad.net/bugs/794642 Upstream: [1]/[2] [1], https://bugzilla.kernel.org/show_bug.cgi?id=40592 [2], http://marc.info/?t=131528297300002&r=1&w=2 Signed-off-by: Ming Lei <ming.lei@canonical.com> Acked-by: Tim Gardner <tim.gardner@canonical.com> Signed-off-by: Leann Ogasawara <leann.ogasawara@canonical.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/ata/ata_piix.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/drivers/ata/ata_piix.c b/drivers/ata/ata_piix.c
index 6f6e7718b05..bfaa44ecfca 100644
--- a/drivers/ata/ata_piix.c
+++ b/drivers/ata/ata_piix.c
@@ -341,11 +341,12 @@ static struct ata_port_operations piix_sata_ops = {
};
static struct ata_port_operations piix_pata_ops = {
- .inherits = &piix_sata_ops,
+ .inherits = &ata_bmdma32_port_ops,
.cable_detect = ata_cable_40wire,
.set_piomode = piix_set_piomode,
.set_dmamode = piix_set_dmamode,
.prereset = piix_pata_prereset,
+ .sff_irq_check = piix_irq_check,
};
static struct ata_port_operations piix_vmw_ops = {
@@ -1587,6 +1588,15 @@ static int __devinit piix_init_one(struct pci_dev *pdev,
"on poweroff and hibernation\n");
}
+ /*
+ * Sandybridge chipset H61/P67/H67 have broken 32 mode up to now
+ * see https://bugzilla.kernel.org/show_bug.cgi?id=40592
+ */
+ if (pdev->vendor == PCI_VENDOR_ID_INTEL && pdev->device == 0x1c00)
+ piix_sata_ops.inherits = &ata_bmdma_port_ops;
+ else
+ piix_sata_ops.inherits = &ata_bmdma32_port_ops;
+
port_info[0] = piix_port_info[ent->driver_data];
port_info[1] = piix_port_info[ent->driver_data];