Rudolf Marek wrote:
> Hi,
>
> I think following is not true. The VT8237A has something else at 0x50, so 
> vt8237_sb_enable_fid_vid should not be neccessary to call. Do you call it 
> or not? If not then we either need to fix it for the "old" location 0x11 
> iirc or not to put there any test for A version.
>>
>> +static const struct device_operations vt8237r_lpc_ops_a = {
>> +    .read_resources         = vt8237r_read_resources,
>> +    .set_resources          = pci_dev_set_resources,
>> +    .enable_resources       = pci_dev_enable_resources,
>> +    .init                   = vt8237r_init,
>> +    .scan_bus               = scan_static_bus,
>> +};
>> +
>
>
> I think you dont need this for now, if you use "r" init version you can 
> cange it directly:
>
>
>> +static const struct pci_driver lpc_driver_a __pci_driver = {
>> +    .ops    =&vt8237r_lpc_ops_a,

Updated patch:

This adds the VT8237A LPC device id and corresponding pci_locate_device
calls in vt8237r_early_smbus.c plus the pci_driver struct in
vt8237r_lpc.c

Signed-off-by: Tobias Diedrich <[email protected]>

---

Index: src/southbridge/via/vt8237r/vt8237r_early_smbus.c
===================================================================
--- src/southbridge/via/vt8237r/vt8237r_early_smbus.c.orig      2010-11-03 
15:15:02.000000000 +0100
+++ src/southbridge/via/vt8237r/vt8237r_early_smbus.c   2010-11-03 
15:15:25.000000000 +0100
@@ -146,6 +146,11 @@
 
        dev = pci_locate_device(PCI_ID(PCI_VENDOR_ID_VIA,
                                PCI_DEVICE_ID_VIA_VT8237S_LPC), 0);
+       if (dev != PCI_DEV_INVALID)
+               return dev;
+
+       dev = pci_locate_device(PCI_ID(PCI_VENDOR_ID_VIA,
+                               PCI_DEVICE_ID_VIA_VT8237A_LPC), 0);
        return dev;
 }
 
Index: src/southbridge/via/vt8237r/vt8237r_lpc.c
===================================================================
--- src/southbridge/via/vt8237r/vt8237r_lpc.c.orig      2010-11-03 
14:54:54.000000000 +0100
+++ src/southbridge/via/vt8237r/vt8237r_lpc.c   2010-11-03 15:16:35.000000000 
+0100
@@ -543,6 +543,12 @@
        .device = PCI_DEVICE_ID_VIA_VT8237R_LPC,
 };
 
+static const struct pci_driver lpc_driver_a __pci_driver = {
+       .ops    = &vt8237r_lpc_ops_r,
+       .vendor = PCI_VENDOR_ID_VIA,
+       .device = PCI_DEVICE_ID_VIA_VT8237A_LPC,
+};
+
 static const struct pci_driver lpc_driver_s __pci_driver = {
        .ops    = &vt8237r_lpc_ops_s,
        .vendor = PCI_VENDOR_ID_VIA,
Index: src/include/device/pci_ids.h
===================================================================
--- src/include/device/pci_ids.h.orig   2010-11-03 14:54:54.000000000 +0100
+++ src/include/device/pci_ids.h        2010-11-03 15:14:49.000000000 +0100
@@ -1226,6 +1226,7 @@
 #define PCI_DEVICE_ID_VIA_K8T890CE_BR  0xb188
 #define PCI_DEVICE_ID_VIA_VT6420_SATA  0x3149
 #define PCI_DEVICE_ID_VIA_VT8237R_LPC  0x3227
+#define PCI_DEVICE_ID_VIA_VT8237A_LPC  0x3337
 #define PCI_DEVICE_ID_VIA_VT8237S_LPC  0x3372
 #define PCI_DEVICE_ID_VIA_VT8237_SATA  0x5372
 #define PCI_DEVICE_ID_VIA_VT8237_VLINK 0x287e


-- 
coreboot mailing list: [email protected]
http://www.coreboot.org/mailman/listinfo/coreboot

Reply via email to