- improve-pci-config-space-writeback.patch removed from -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled

     Improve PCI config space writeback.

has been removed from the -mm tree.  Its filename is

     improve-pci-config-space-writeback.patch

This patch was probably dropped from -mm because
it has now been merged into a subsystem tree or
into Linus's tree, or because it was folded into
its parent patch in the -mm tree.

------------------------------------------------------
Subject: Improve PCI config space writeback.
From: Dave Jones <davej@xxxxxxxxxx>


At least one laptop blew up on resume from suspend with a black screen due
to a lack of this patch.  By only writing back config space that is
different, we minimise the possibility of accidents like this.

Signed-off-by: Dave Jones <davej@xxxxxxxxxx>
Cc: Greg KH <greg@xxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxx>
---

 drivers/pci/pci.c |   14 ++++++++++++--
 1 files changed, 12 insertions(+), 2 deletions(-)

diff -puN drivers/pci/pci.c~improve-pci-config-space-writeback drivers/pci/pci.c
--- devel/drivers/pci/pci.c~improve-pci-config-space-writeback	2006-04-18 21:06:15.000000000 -0700
+++ devel-akpm/drivers/pci/pci.c	2006-04-18 21:06:17.000000000 -0700
@@ -461,9 +461,19 @@ int 
 pci_restore_state(struct pci_dev *dev)
 {
 	int i;
+	int val;
 
-	for (i = 0; i < 16; i++)
-		pci_write_config_dword(dev,i * 4, dev->saved_config_space[i]);
+	for (i = 0; i < 16; 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 "
+				"device %s at offset %x (was %x, writing %x)\n",
+				pci_name(dev), i,
+				val, (int)dev->saved_config_space[i]);
+			pci_write_config_dword(dev,i * 4,
+				dev->saved_config_space[i]);
+		}
+	}
 	pci_restore_msi_state(dev);
 	pci_restore_msix_state(dev);
 	return 0;
_

Patches currently in -mm which might be from davej@xxxxxxxxxx are

origin.patch
git-acpi.patch
git-agpgart.patch
git-cpufreq.patch
remove-silly-messages-from-input-layer.patch
fix-ide-locking-error.patch
post-halloween-doc.patch
debug-warn-if-we-sleep-in-an-irq-for-a-long-time.patch

-
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux