git.samba.org
/
sfrench
/
cifs-2.6.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
(from parent 1:
16a2164
)
Merge branch 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git...
author
Linus Torvalds
<torvalds@linux-foundation.org>
Sat, 15 May 2010 04:28:23 +0000
(21:28 -0700)
committer
Linus Torvalds
<torvalds@linux-foundation.org>
Sat, 15 May 2010 04:28:23 +0000
(21:28 -0700)
* 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
x86, mrst: Don't blindly access extended config space
arch/x86/pci/mrst.c
patch
|
blob
|
history
diff --git
a/arch/x86/pci/mrst.c
b/arch/x86/pci/mrst.c
index 8bf2fcb88d0427ff5c63e37fab736355ecbc8332..1cdc02cf8fa49e159cdd4696766abad56b50c13b 100644
(file)
--- a/
arch/x86/pci/mrst.c
+++ b/
arch/x86/pci/mrst.c
@@
-247,6
+247,10
@@
static void __devinit pci_fixed_bar_fixup(struct pci_dev *dev)
u32 size;
int i;
+ /* Must have extended configuration space */
+ if (dev->cfg_size < PCIE_CAP_OFFSET + 4)
+ return;
+
/* Fixup the BAR sizes for fixed BAR devices and make them unmoveable */
offset = fixed_bar_cap(dev->bus, dev->devfn);
if (!offset || PCI_DEVFN(2, 0) == dev->devfn ||