diff options
author | Dmitry Torokhov <dtor_core@ameritech.net> | 2006-01-05 22:25:13 -0500 |
---|---|---|
committer | Dmitry Torokhov <dtor_core@ameritech.net> | 2006-01-05 22:25:13 -0500 |
commit | fed8bf19ec20efc0641740b2d10aa589dbd6d1ab (patch) | |
tree | c104a13c7b8cb7f4152b15729dc5aede7c063e91 /drivers/pci/quirks.c | |
parent | e7c3aad53dba54d375b632f2a21b680546828dec (diff) | |
parent | 46f25dffbaba48c571d75f5f574f31978287b8d2 (diff) | |
download | talos-op-linux-fed8bf19ec20efc0641740b2d10aa589dbd6d1ab.tar.gz talos-op-linux-fed8bf19ec20efc0641740b2d10aa589dbd6d1ab.zip |
Merge rsync://rsync.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
Diffstat (limited to 'drivers/pci/quirks.c')
-rw-r--r-- | drivers/pci/quirks.c | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c index 3a4f49f4effb..f28ebdd3958a 100644 --- a/drivers/pci/quirks.c +++ b/drivers/pci/quirks.c @@ -1098,6 +1098,23 @@ static void __init quirk_alder_ioapic(struct pci_dev *pdev) DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_EESSC, quirk_alder_ioapic ); #endif +enum ide_combined_type { COMBINED = 0, IDE = 1, LIBATA = 2 }; +/* Defaults to combined */ +static enum ide_combined_type combined_mode; + +static int __init combined_setup(char *str) +{ + if (!strncmp(str, "ide", 3)) + combined_mode = IDE; + else if (!strncmp(str, "libata", 6)) + combined_mode = LIBATA; + else /* "combined" or anything else defaults to old behavior */ + combined_mode = COMBINED; + + return 1; +} +__setup("combined_mode=", combined_setup); + #ifdef CONFIG_SCSI_SATA_INTEL_COMBINED static void __devinit quirk_intel_ide_combined(struct pci_dev *pdev) { @@ -1164,6 +1181,19 @@ static void __devinit quirk_intel_ide_combined(struct pci_dev *pdev) if (prog & comb) return; + /* Don't reserve any so the IDE driver can get them (but only if + * combined_mode=ide). + */ + if (combined_mode == IDE) + return; + + /* Grab them both for libata if combined_mode=libata. */ + if (combined_mode == LIBATA) { + request_region(0x1f0, 8, "libata"); /* port 0 */ + request_region(0x170, 8, "libata"); /* port 1 */ + return; + } + /* SATA port is in legacy mode. Reserve port so that * IDE driver does not attempt to use it. If request_region * fails, it will be obvious at boot time, so we don't bother |