projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9fa7eb2
)
PCI: use fixed-up device class when configuring device
author
Yu Zhao
<
[email protected]
>
Wed, 27 May 2009 16:25:05 +0000
(
00:25
+0800)
committer
Jesse Barnes
<
[email protected]
>
Thu, 4 Jun 2009 10:29:43 +0000
(11:29 +0100)
The device class may be changed after the fixup, so re-read the class
value from pci_dev when configuring the device. Otherwise some devices
such as JMicron SATA controller won't work.
Reviewed-by: Matthew Wilcox <
[email protected]
>
Reviewed-by: Grant Grundler <
[email protected]
>
Tested-by: Marc Dionne <
[email protected]
>
Signed-off-by: Yu Zhao <
[email protected]
>
Signed-off-by: Jesse Barnes <
[email protected]
>
drivers/pci/probe.c
patch
|
blob
|
history
diff --git
a/drivers/pci/probe.c
b/drivers/pci/probe.c
index e3c3e081b83431755b7c3e875c84e5e7bc30f684..f1ae2475ffffcd827844694c0075448d62cfb3e1 100644
(file)
--- a/
drivers/pci/probe.c
+++ b/
drivers/pci/probe.c
@@
-745,6
+745,8
@@
int pci_setup_device(struct pci_dev *dev)
/* Early fixups, before probing the BARs */
pci_fixup_device(pci_fixup_early, dev);
+ /* device class may be changed after fixup */
+ class = dev->class >> 8;
switch (dev->hdr_type) { /* header type */
case PCI_HEADER_TYPE_NORMAL: /* standard header */