Skip to content

Commit

Permalink
[PATCH] JMB 368 PATA detection
Browse files Browse the repository at this point in the history
The Jmicron JMB368 is PATA only so has the PATA on function zero.  Don't
therefore skip function zero on this device when probing

Signed-off-by: Alan Cox <alan@redhat.com>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Alan Cox authored and Linus Torvalds committed Oct 28, 2006
1 parent 8fa1d7d commit c333526
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions drivers/ide/pci/generic.c
Original file line number Diff line number Diff line change
Expand Up @@ -247,8 +247,10 @@ static int __devinit generic_init_one(struct pci_dev *dev, const struct pci_devi
(!(PCI_FUNC(dev->devfn) & 1)))
goto out;

if (dev->vendor == PCI_VENDOR_ID_JMICRON && PCI_FUNC(dev->devfn) != 1)
goto out;
if (dev->vendor == PCI_VENDOR_ID_JMICRON) {
if (dev->device != PCI_DEVICE_ID_JMICRON_JMB368 && PCI_FUNC(dev->devfn) != 1)
goto out;
}

if (dev->vendor != PCI_VENDOR_ID_JMICRON) {
pci_read_config_word(dev, PCI_COMMAND, &command);
Expand Down

0 comments on commit c333526

Please sign in to comment.