[PATCH] PCI: unhide SMBus on Compaq Deskpro EP 401963-001 motherboard with i810 chipset

GW <[email protected]>
Newsgroups gmane.linux.usb.devel
Message-ID <[email protected]>
PCI quirk to unhide SMBus on Compaq Deskpro EP 401963-001 (PCA# 010174) motherboard with i810 chipset.

Signed-off-by: GW <[email protected]>

---
Patch is for kernel source 2.6.21 with Debian patches.

Seems to work fine with no conflicts.

Motherboard identification based on host bridge device is a little strange, because there isn't any subsystem information (subvendor id or subdevice id are set to 0x0000).
lspci -v -nn -s 00:00.0
00:00.0 Host bridge [0600]: Intel Corporation 82810 DC-100 GMCH [Graphics Memory Controller Hub] [8086:7122] (rev 02)
        Flags: bus master, fast devsel, latency 0

After implied patch SMBus is present:
lspci -v -nn -s 00:1f.3
00:1f.3 SMBus [0c05]: Intel Corporation 82801AA SMBus [8086:2413] (rev 01)
        Flags: medium devsel, IRQ 11
        I/O ports at fc00 [size=16]


diff -Naur linux-source-2.6.21/drivers/pci/quirks.c linux-source-2.6.21-unhidesmbusoncompaqdeskproep/drivers/pci/quirks.c
--- linux-source-2.6.21/drivers/pci/quirks.c	2007-07-10 18:46:19.000000000 +0200
+++ linux-source-2.6.21-unhidesmbusoncompaqdeskproep/drivers/pci/quirks.c	2007-07-26 14:21:13.000000000 +0200
@@ -1059,6 +1059,12 @@
 			case 0x0058: /* Compaq Evo N620c */
 				asus_hides_smbus = 1;
 			}
+	} else if (unlikely(dev->subsystem_vendor == PCI_CLASS_NOT_DEFINED)) {
+		if (dev->device == PCI_DEVICE_ID_INTEL_82810_MC3)
+			switch(dev->subsystem_device) {
+			case 0x0000: /* Compaq Deskpro EP 401963-001 (PCA# 010174) motherboard with i810 chipset doesn't have subsystem identification */
+				asus_hides_smbus = 1;
+			}
 	}
 }
 DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL,	PCI_DEVICE_ID_INTEL_82845_HB,	asus_hides_smbus_hostbridge );
@@ -1070,6 +1076,7 @@
 DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL,	PCI_DEVICE_ID_INTEL_82855PM_HB,	asus_hides_smbus_hostbridge );
 DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL,	PCI_DEVICE_ID_INTEL_82855GM_HB,	asus_hides_smbus_hostbridge );
 DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL,	PCI_DEVICE_ID_INTEL_82915GM_HB, asus_hides_smbus_hostbridge );
+DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL,	PCI_DEVICE_ID_INTEL_82810_MC3,	asus_hides_smbus_hostbridge );
 
 static void asus_hides_smbus_lpc(struct pci_dev *dev)
 {
@@ -1088,12 +1095,14 @@
 			printk(KERN_INFO "PCI: Enabled i801 SMBus device\n");
 	}
 }
+DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL,	PCI_DEVICE_ID_INTEL_82801AA_0,	asus_hides_smbus_lpc );
 DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL,	PCI_DEVICE_ID_INTEL_82801DB_0,	asus_hides_smbus_lpc );
 DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL,	PCI_DEVICE_ID_INTEL_82801BA_0,	asus_hides_smbus_lpc );
 DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL,	PCI_DEVICE_ID_INTEL_82801CA_0,	asus_hides_smbus_lpc );
 DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL,	PCI_DEVICE_ID_INTEL_82801CA_12,	asus_hides_smbus_lpc );
 DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL,	PCI_DEVICE_ID_INTEL_82801DB_12,	asus_hides_smbus_lpc );
 DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL,	PCI_DEVICE_ID_INTEL_82801EB_0,	asus_hides_smbus_lpc );
+DECLARE_PCI_FIXUP_RESUME(PCI_VENDOR_ID_INTEL,	PCI_DEVICE_ID_INTEL_82801AA_0,	asus_hides_smbus_lpc );
 DECLARE_PCI_FIXUP_RESUME(PCI_VENDOR_ID_INTEL,	PCI_DEVICE_ID_INTEL_82801DB_0,	asus_hides_smbus_lpc );
 DECLARE_PCI_FIXUP_RESUME(PCI_VENDOR_ID_INTEL,	PCI_DEVICE_ID_INTEL_82801BA_0,	asus_hides_smbus_lpc );
 DECLARE_PCI_FIXUP_RESUME(PCI_VENDOR_ID_INTEL,	PCI_DEVICE_ID_INTEL_82801CA_0,	asus_hides_smbus_lpc );


-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
[email protected]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.