Commit fc4c3ad2 authored by Shai Fultheim's avatar Shai Fultheim Committed by Linus Torvalds

[PATCH] Multiple (ICH3) IDE-controllers in a system

This fixes a problem with multiple IDE controllers in a system.

The problem is that pcibios_fixups table (in arch/i386/pci/fixup.c) uses
the pci_fixup_ide_trash() quirk for Intel's ICH3 (my case specifically
8086:248b).  This clears any bogus BAR information set up by the BIOS.

In a system which has multiple ICH3's can't use any of the IDE
controllers beside the one on the first ICH3.

Anyhow, the fix is to make sure pci_fixup_ide_trash resets the BARs only
for first time being called, so the subsequent IDE controllers will use
the BIOS BARs.  This is better than "loosing" all these IDE controllers
in the case their BARs set right.

The issue discussed and agreed with Bartlomiej Zolnierkiewicz (see below).
parent e92f75e7
...@@ -91,6 +91,15 @@ static void __devinit pci_fixup_ide_trash(struct pci_dev *d) ...@@ -91,6 +91,15 @@ static void __devinit pci_fixup_ide_trash(struct pci_dev *d)
{ {
int i; int i;
/*
* Runs the fixup only for the first IDE controller
* (Shai Fultheim - shai@ftcon.com)
*/
static int called = 0;
if (called)
return;
called = 1;
/* /*
* There exist PCI IDE controllers which have utter garbage * There exist PCI IDE controllers which have utter garbage
* in first four base registers. Ignore that. * in first four base registers. Ignore that.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment