提交 8b8c8d28 编写于 作者: Y Yu, Luming 提交者: Greg Kroah-Hartman

[PATCH] PCI: reverse pci config space restore order

According to Intel ICH spec, there are several rules that Base Address
should be programmed before IOSE  (PCICMD register ) enabled.

For example ICH7:

12.1.3  SATA : the base address register for the bus master register
               should be programmed before this bit is set.

11.1.3:  PCICMD (USB): The base address register for USB should be
                       programmed before this bit is set.
....

To make sure kernel code follow this rule , and prevent unnecessary
confusion. I proposal this patch.
Signed-off-by: NLuming Yu <luming.yu@intel.com>
Signed-off-by: NAndrew Morton <akpm@osdl.org>
Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
上级 04d9c1a1
......@@ -463,7 +463,11 @@ pci_restore_state(struct pci_dev *dev)
int i;
int val;
for (i = 0; i < 16; i++) {
/*
* The Base Address register should be programmed before the command
* register(s)
*/
for (i = 15; i >= 0; i--) {
pci_read_config_dword(dev, i * 4, &val);
if (val != dev->saved_config_space[i]) {
printk(KERN_DEBUG "PM: Writing back config space on "
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册