Changeset 3651 for trunk/coreboot-v2

Show
Ignore:
Timestamp:
10/12/08 16:40:23 (3 months ago)
Author:
uwe
Message:

VIA VT8237R cleanups (trivial).

Signed-off-by: Uwe Hermann <uwe@…>
Acked-by: Uwe Hermann <uwe@…>

Location:
trunk/coreboot-v2/src/southbridge/via/vt8237r
Files:
6 modified

Legend:

Unmodified
Added
Removed
  • trunk/coreboot-v2/src/southbridge/via/vt8237r/chip.h

    r3052 r3651  
    5454        int ide1_enable:1; 
    5555 
    56         /* 1 = 80-pin cable */ 
     56        /* 1 = 80-pin cable, 0 = 40-pin cable */ 
    5757        int ide0_80pin_cable:1; 
    5858        int ide1_80pin_cable:1; 
  • trunk/coreboot-v2/src/southbridge/via/vt8237r/vt8237_ctrl.c

    r3567 r3651  
    2929{ 
    3030        u8 regm, regm2, regm3; 
    31  
    3231        device_t devfun3; 
    3332 
    3433        devfun3 = dev_find_device(PCI_VENDOR_ID_VIA, 
    35                                            PCI_DEVICE_ID_VIA_K8T890CE_3, 0); 
     34                                  PCI_DEVICE_ID_VIA_K8T890CE_3, 0); 
     35        if (!devfun3) 
     36                devfun3 = dev_find_device(PCI_VENDOR_ID_VIA, 
     37                                          PCI_DEVICE_ID_VIA_K8M890CE_3, 0); 
     38        if (!devfun3) 
     39                die("Unknown NB"); 
    3640 
    37                 if (!devfun3) 
    38                         devfun3 = dev_find_device(PCI_VENDOR_ID_VIA, 
    39                                            PCI_DEVICE_ID_VIA_K8M890CE_3, 0); 
    40  
    41                 if (!devfun3) 
    42                         die("Unknown NB"); 
    43  
    44         /* CPU to PCI Flow Control 1 & 2, just fill in recommended */ 
     41        /* CPU to PCI Flow Control 1 & 2, just fill in recommended. */ 
    4542        pci_write_config8(dev, 0x70, 0xc2); 
    4643        pci_write_config8(dev, 0x71, 0xc8); 
     
    5552        pci_write_config8(dev, 0x78, 0x01); 
    5653        /* APIC on HT */ 
    57         pci_write_config8(dev, 0x7c, 0x77); //maybe Enable LDT APIC Mode bit3 set to 1 
     54        /* Maybe Enable LDT APIC Mode bit3 set to 1 */ 
     55        pci_write_config8(dev, 0x7c, 0x77); 
    5856 
    5957        /* WARNING: Need to copy some registers from NB (D0F3) to SB (D11F7). */ 
     
    9088 * NB V-Link Receiving Strobe Delay              0xb7  0x02  0x02  0x61  0x01 
    9189 * NB V-Link Compensation Control bit4,0 (b5,b6) 0xb4  0x10  0x10  0x11  0x11 
    92  * SB V-Link Strobe Drive Control                0xb9  0x00  0xa5  0x98  0x98 
     90 * SB V-Link Strobe Drive Control                0xb9  0x00  0xa5  0x98  0x98 
    9391 * SB V-Link Data drive Control????              0xba  0x00  0xbb  0x77  0x77 
    9492 * SB V-Link Receive Strobe Delay????            0xbb  0x04  0x11  0x11  0x11 
     
    9795 * V-Link CKG Control                            0xb1  0x05  0x05  0x01  0x03 
    9896 */ 
    99  
    10097static void vt8237s_vlink_init(struct device *dev) 
    10198{ 
    10299        u8 reg; 
    103  
    104100        device_t devfun7; 
    105101 
    106102        devfun7 = dev_find_device(PCI_VENDOR_ID_VIA, 
    107                                            PCI_DEVICE_ID_VIA_K8T890CE_7, 0); 
    108  
     103                                  PCI_DEVICE_ID_VIA_K8T890CE_7, 0); 
    109104        if (!devfun7) 
    110105                devfun7 = dev_find_device(PCI_VENDOR_ID_VIA, 
    111                                            PCI_DEVICE_ID_VIA_K8M890CE_7, 0); 
    112  
    113         /* no pairing NB found */ 
     106                                          PCI_DEVICE_ID_VIA_K8M890CE_7, 0); 
     107        /* No pairing NB was found. */ 
    114108        if (!devfun7) 
    115109                return; 
     
    133127        pci_write_config8(dev, 0xbb, 0x89); 
    134128 
    135  
    136129        reg = pci_read_config8(dev, 0xbd); 
    137130        reg |= 0x3; 
    138131        pci_write_config8(dev, 0xbd, reg); 
    139132 
    140         /* Program V-link 8X 8bit full duplex, parity disabled FIXME */ 
     133        /* Program V-link 8X 8bit full duplex, parity disabled. FIXME. */ 
    141134        pci_write_config8(dev, 0x48, 0x13); 
    142135} 
    143136 
    144 static void ctrl_enable(struct device *dev) { 
    145          
    146         /* enable the 0:13 and 0:13.1 */ 
     137static void ctrl_enable(struct device *dev) 
     138{ 
     139        /* Enable the 0:13 and 0:13.1. */ 
    147140        /* FIXME */ 
    148141        pci_write_config8(dev, 0x4f, 0x43); 
    149142} 
    150143 
    151  
    152144extern void dump_south(device_t dev); 
    153145 
    154 static void ctrl_init(struct device *dev) { 
     146static void ctrl_init(struct device *dev) 
     147{ 
     148        /* 
     149         * TODO: Fix some ordering issue for V-link set Rx77[6] and 
     150         * PCI1_Rx4F[0] should to 1. 
     151         * FIXME DO you need? 
     152         */ 
    155153 
    156         /* TODO: Fix some ordering issue fo V-link set Rx77[6] and PCI1_Rx4F[0] 
    157            should to 1 FIXME DO you need?*/ 
    158  
    159         /* VT8237R specific configuration  other SB are done in their own directories */ 
    160         /*  add A version */ 
     154        /* 
     155         * VT8237R specific configuration. Other SB are done in their own 
     156         * directories. TODO: Add A version. 
     157         */ 
    161158        device_t devsb = dev_find_device(PCI_VENDOR_ID_VIA, 
    162                                         PCI_DEVICE_ID_VIA_VT8237S_LPC, 0); 
     159                                         PCI_DEVICE_ID_VIA_VT8237S_LPC, 0); 
    163160        if (devsb) { 
    164                 /* FIXME: Skip v-link setup for now */ 
    165 //              vt8237s_vlink_init(dev); 
     161                /* FIXME: Skip v-link setup for now. */ 
     162//              vt8237s_vlink_init(dev); 
    166163        } 
    167164 
    168         /* configure PCI1 and copy mirror registers from D0F3 */ 
     165        /* Configure PCI1 and copy mirror registers from D0F3. */ 
    169166        vt8237_cfg(dev); 
    170167        dump_south(dev); 
  • trunk/coreboot-v2/src/southbridge/via/vt8237r/vt8237r.c

    r3556 r3651  
    6464        for (i = 0; i < 256; i += 16) { 
    6565                printk_debug("%02x: ", i); 
    66                 for (j = 0; j < 16; j++) { 
     66                for (j = 0; j < 16; j++) 
    6767                        printk_debug("%02x ", pci_read_config8(dev, i + j)); 
    68                 } 
    6968                printk_debug("\n"); 
    7069        } 
  • trunk/coreboot-v2/src/southbridge/via/vt8237r/vt8237r_early_smbus.c

    r3567 r3651  
    129129        return val; 
    130130} 
    131 /** 
    132  * Enable the smbus on vt8237r-based systems 
     131 
     132/** 
     133 * Enable the SMBus on VT8237R-based systems. 
    133134 */ 
    134135void enable_smbus(void) 
     
    137138 
    138139        /* Power management controller */ 
    139  
    140140        dev = pci_locate_device(PCI_ID(PCI_VENDOR_ID_VIA, 
    141141                                       PCI_DEVICE_ID_VIA_VT8237R_LPC), 0); 
    142  
    143142        if (dev == PCI_DEV_INVALID) { 
    144143                /* Power management controller */ 
    145144                dev = pci_locate_device(PCI_ID(PCI_VENDOR_ID_VIA, 
    146                                                PCI_DEVICE_ID_VIA_VT8237S_LPC), 0); 
     145                                        PCI_DEVICE_ID_VIA_VT8237S_LPC), 0); 
    147146                if (dev == PCI_DEV_INVALID) 
    148147                        die("Power management controller not found\r\n"); 
    149148        } 
    150149 
    151         /* 7 = SMBus Clock from RTC 32.768KHz 
     150        /* 
     151         * 7 = SMBus Clock from RTC 32.768KHz 
    152152         * 5 = Internal PLL reset from susp 
    153153         */ 
     
    202202         */ 
    203203        for (i = 0; (i < SMBUS_TIMEOUT && ((result < SPD_MEMORY_TYPE_SDRAM) || 
    204                                 (result > SPD_MEMORY_TYPE_SDRAM_DDR3))); i++) { 
     204           (result > SPD_MEMORY_TYPE_SDRAM_DDR3))); i++) { 
    205205 
    206206                if (current_slot > ram_slots) 
     
    219219} 
    220220 
    221 /* fixme better separate the NB and SB, will done once it works */ 
    222  
    223 void vt8237_sb_enable_fid_vid(void) { 
    224         device_t dev; 
    225         device_t devctl; 
     221/* FIXME: Better separate the NB and SB, will be done once it works. */ 
     222 
     223void vt8237_sb_enable_fid_vid(void) 
     224{ 
     225        device_t dev, devctl; 
    226226 
    227227        /* Power management controller */ 
    228228        dev = pci_locate_device(PCI_ID(PCI_VENDOR_ID_VIA, 
    229229                                       PCI_DEVICE_ID_VIA_VT8237R_LPC), 0); 
    230  
    231230        if (dev == PCI_DEV_INVALID) { 
    232                 /* Power management controller */ 
     231                /* Power management controller */ 
    233232                dev = pci_locate_device(PCI_ID(PCI_VENDOR_ID_VIA, 
    234                                                PCI_DEVICE_ID_VIA_VT8237S_LPC), 0); 
     233                                        PCI_DEVICE_ID_VIA_VT8237S_LPC), 0); 
    235234                if (dev == PCI_DEV_INVALID) 
    236235                        return; 
    237236 
    238237                devctl = pci_locate_device(PCI_ID(PCI_VENDOR_ID_VIA, 
    239                                                PCI_DEVICE_ID_VIA_VT8237_VLINK), 0); 
     238                                           PCI_DEVICE_ID_VIA_VT8237_VLINK), 0); 
    240239                if (devctl == PCI_DEV_INVALID) 
    241240                        return; 
    242                  
     241 
     242                /* TODO: Why is this an extra block? */ 
    243243                { 
    244                 u8 tmp; 
    245                 tmp = pci_read_config8(devctl, 0xec); 
    246                 print_debug("EC is "); 
    247                 print_debug_hex8(tmp); 
    248                 print_debug(" E5 is "); 
    249                 tmp = pci_read_config8(dev, 0xe5); 
    250                 print_debug_hex8(tmp); 
    251                  
     244                        u8 tmp; 
     245                        tmp = pci_read_config8(devctl, 0xec); 
     246                        print_debug("EC is "); 
     247                        print_debug_hex8(tmp); 
     248                        print_debug(" E5 is "); 
     249                        tmp = pci_read_config8(dev, 0xe5); 
     250                        print_debug_hex8(tmp); 
    252251                } 
     252 
    253253                /* Set ACPI base address to I/O VT8237R_ACPI_IO_BASE. */ 
    254254                pci_write_config16(dev, 0x88, VT8237R_ACPI_IO_BASE | 0x1); 
     255 
    255256                /* Enable ACPI accessm RTC signal gated with PSON. */ 
    256257                pci_write_config8(dev, 0x81, 0x84); 
    257                 /* Allow SLP# signal to assert LDTSTOP_L. 
     258 
     259                /* 
     260                 * Allow SLP# signal to assert LDTSTOP_L. 
    258261                 * Will work for C3 and for FID/VID change. 
    259262                 */ 
    260263 
    261                 /* fixme */ 
    262                 outb(0xff, VT8237R_ACPI_IO_BASE + 0x50);  //fixme maybe not needed 
    263  
    264 //              outb(0x4, VT8237R_ACPI_IO_BASE + 0x50);  //fixme maybe not needed 
    265  
    266                 /* it seems for AMD LDTSTP is connected not to SLP anymore */ 
    267                 /* enable 0: DPSLP# / DPRSTP# / VRDSLP */ 
    268  
    269                 /* Enable SATA LED, VR timer = 100us 
    270                  * Enable DPSLP# / DPRSTP# / VRDSLP - WARNING LDTSTP connetcs to some of those pins! (and not to SLP as on R ver) 
     264                /* FIXME */ 
     265                outb(0xff, VT8237R_ACPI_IO_BASE + 0x50); /* Maybe unneeded? */ 
     266//              outb(0x4, VT8237R_ACPI_IO_BASE + 0x50);  /* Maybe unneeded? */ 
     267 
     268                /* It seems for AMD LDTSTP is connected not to SLP anymore. */ 
     269                /* Enable 0: DPSLP# / DPRSTP# / VRDSLP */ 
     270 
     271                /* 
     272                 * Enable SATA LED, VR timer = 100us. 
     273                 * Enable DPSLP# / DPRSTP# / VRDSLP - WARNING LDTSTP connetcs 
     274                 * to some of those pins! (and not to SLP as on R ver). 
    271275                 */ 
    272                  //fixme 
    273                 pci_write_config8(dev, 0xe5, 0x69); 
    274          
    275                 /* REQ5 as PCI request input - should be together with INTE-INTH.  
    276                  * Fast VR timer disable - need for LDTSTP signal 
    277                 */ 
     276                pci_write_config8(dev, 0xe5, 0x69);     /* FIXME */ 
     277 
     278                /* 
     279                 * REQ5 as PCI request input - should be together with 
     280                 * INTE-INTH. Fast VR timer disable - need for LDTSTP signal. 
     281                 */ 
    278282                pci_write_config8(dev, 0xe4, 0xa5); 
    279          
    280                 /* reduce further the STPCLK/LDTSTP signal to 5us */ 
    281  
     283 
     284                /* Reduce further the STPCLK/LDTSTP signal to 5us. */ 
    282285                pci_write_config8(dev, 0xec, 0x4); 
    283                 /* Host Bus Power Management Control, maybe not needed */ 
     286 
     287                /* Host Bus Power Management Control, maybe not needed. */ 
    284288                pci_write_config8(dev, 0x8c, 0x5); 
    285289 
    286                 /* so the chip knows we are on AMD */ 
     290                /* So the chip knows we are on AMD. */ 
    287291                pci_write_config8(devctl, 0x7c, 0x77); 
    288292 
    289293                devctl = pci_locate_device(PCI_ID(PCI_VENDOR_ID_VIA, 
    290                                                0x2336), 0); 
     294                                                  0x2336), 0); 
    291295                if (devctl == PCI_DEV_INVALID) 
    292296                        return; 
    293                 /* Enable C2NOW delay to PSTATECTL VID / FID Change Delay to P-State Control */ 
     297 
     298                /* 
     299                 * Enable C2NOW delay to PSTATECTL VID / FID Change Delay 
     300                 * to P-State Control. 
     301                 */ 
    294302                pci_write_config8(devctl, 0xa6, 0x83); 
    295303 
    296                 //return; //FIXME fall through some revs have it old way 
    297         } 
     304                // return; // FIXME: Fall through some revs have it old way. 
     305        } 
     306 
    298307        /* Set ACPI base address to I/O VT8237R_ACPI_IO_BASE. */ 
    299308        pci_write_config16(dev, 0x88, VT8237R_ACPI_IO_BASE | 0x1); 
     309 
    300310        /* Enable ACPI accessm RTC signal gated with PSON. */ 
    301311        pci_write_config8(dev, 0x81, 0x84); 
    302         /* Allow SLP# signal to assert LDTSTOP_L. 
     312 
     313        /* 
     314         * Allow SLP# signal to assert LDTSTOP_L. 
    303315         * Will work for C3 and for FID/VID change. 
    304316         */ 
     
    313325        dev = pci_locate_device(PCI_ID(PCI_VENDOR_ID_VIA, 
    314326                                       PCI_DEVICE_ID_VIA_VT8237R_LPC), 0); 
    315  
    316327        if (dev == PCI_DEV_INVALID) { 
    317                 /* Power management controller */ 
     328                /* Power management controller */ 
    318329                dev = pci_locate_device(PCI_ID(PCI_VENDOR_ID_VIA, 
    319                                                PCI_DEVICE_ID_VIA_VT8237S_LPC), 0); 
     330                                        PCI_DEVICE_ID_VIA_VT8237S_LPC), 0); 
    320331                if (dev == PCI_DEV_INVALID) 
    321332                        return; 
    322333        } 
    323334 
    324         /* ROM decode last 1MB FFC00000 - FFFFFFFF */ 
     335        /* ROM decode last 1MB FFC00000 - FFFFFFFF. */ 
    325336        pci_write_config8(dev, 0x41, 0x7f); 
    326337} 
    327338 
    328 void vt8237_early_spi_init(void) { 
     339void vt8237_early_spi_init(void) 
     340{ 
    329341        device_t dev; 
    330342        volatile u16 *spireg; 
    331343        u32 tmp; 
    332344 
    333         /* Bus Control and Power Management  */ 
     345        /* Bus Control and Power Management */ 
    334346        dev = pci_locate_device(PCI_ID(PCI_VENDOR_ID_VIA, 
    335347                                       PCI_DEVICE_ID_VIA_VT8237S_LPC), 0); 
     
    338350                die("SB not found\r\n"); 
    339351 
    340         /* put SPI base 20 d0 fe */ 
     352        /* Put SPI base 20 d0 fe. */ 
    341353        tmp = pci_read_config32(dev, 0xbc); 
    342         pci_write_config32(dev, 0xbc, (VT8237S_SPI_MEM_BASE >> 8) | (tmp & 0xFF000000)); 
    343  
    344         /* set SPI clock to 33MHz */ 
     354        pci_write_config32(dev, 0xbc, 
     355                           (VT8237S_SPI_MEM_BASE >> 8) | (tmp & 0xFF000000)); 
     356 
     357        /* Set SPI clock to 33MHz. */ 
    345358        spireg = (u16 *) (VT8237S_SPI_MEM_BASE + 0x6c); 
    346         (*spireg) &=  0xff00; 
    347 } 
    348  
    349 /* offset 0x58 
     359        (*spireg) &= 0xff00; 
     360} 
     361 
     362/* 
     363 * Offset 0x58: 
    350364 * 31:20        reserved 
    351365 * 19:16        4 bit position in shadow EEPROM 
    352366 * 15:0         data to write 
    353367 * 
    354  * offset 0x5c 
     368 * Offset 0x5c: 
    355369 * 31:28        reserved 
    356370 * 27           ERDBG - enable read from 0x5c 
    357371 * 26           reserved 
    358372 * 25           SEELD 
    359  * 24           SEEPR - write 1 when done updating, wait until SEELD is set to 1, sticky 
     373 * 24           SEEPR - write 1 when done updating, wait until SEELD is 
     374 *                      set to 1, sticky 
    360375 *              cleared by reset, if it is 1 writing is disabled 
    361376 * 19:16        4 bit position in shadow EEPROM 
    362377 * 15:0         data from shadow EEPROM 
    363378 * 
    364  * after PCIRESET SEELD and SEEPR must be 1 and 1 
    365 */ 
    366  
    367 /* 1 = needs PCI reset, 0 don't reset, network initialized */ 
    368  
    369 /* fixme maybe close the debug register after use? */ 
     379 * After PCIRESET SEELD and SEEPR must be 1 and 1. 
     380 */ 
     381 
     382/* 1 = needs PCI reset, 0 don't reset, network initialized. */ 
     383 
     384/* FIXME: Maybe close the debug register after use? */ 
    370385 
    371386#define LAN_TIMEOUT 0x7FFFFFFF 
    372387 
    373 int vt8237_early_network_init(struct vt8237_network_rom *rom) { 
     388int vt8237_early_network_init(struct vt8237_network_rom *rom) 
     389{ 
    374390        struct vt8237_network_rom n; 
    375         int loops; 
     391        int i, loops; 
    376392        device_t dev; 
    377393        u32 tmp; 
     
    379395        u16 *rom_write; 
    380396        unsigned int checksum; 
    381         int i; 
    382397 
    383398        /* Network adapter */ 
    384399        dev = pci_locate_device(PCI_ID(PCI_VENDOR_ID_VIA, 
    385400                                       PCI_DEVICE_ID_VIA_8233_7), 0); 
    386  
    387401        if (dev == PCI_DEV_INVALID) { 
    388             print_err("Network is disabled, please enable\n"); 
    389             return 0; 
     402                print_err("Network is disabled, please enable\n"); 
     403                return 0; 
    390404        } 
    391405 
    392406        tmp = pci_read_config32(dev, 0x5c); 
    393         /* enable ERDBG */ 
    394         tmp |= 0x08000000; 
     407        tmp |= 0x08000000;      /* Enable ERDBG. */ 
    395408        pci_write_config32(dev, 0x5c, tmp); 
    396          
     409 
    397410        status = ((pci_read_config32(dev, 0x5c) >> 24) & 0x3); 
    398          
    399         if (status == 3) { 
    400             /* network controller OK, EEPROM loaded */ 
    401             return 0; 
    402         } 
    403          
     411 
     412        /* Network controller OK, EEPROM loaded. */ 
     413        if (status == 3) 
     414                return 0; 
     415 
    404416        if (rom == NULL) { 
    405             print_err("No configuration data specified, using default MAC!\n"); 
     417                print_err("No config data specified, using default MAC!\n"); 
    406418                n.mac_address[0] = 0x0; 
    407419                n.mac_address[1] = 0x0; 
     
    432444                rom = &n; 
    433445        } 
    434          
     446 
    435447        rom_write = (u16 *) rom; 
    436448        checksum = 0; 
    437         /* write all data except checksum and second to last byte */ 
    438         tmp &= 0xff000000; /* leave reserved bits in */ 
     449        /* Write all data except checksum and second to last byte. */ 
     450        tmp &= 0xff000000;      /* Leave reserved bits in. */ 
    439451        for (i = 0; i < 15; i++) { 
    440452                pci_write_config32(dev, 0x58, tmp | (i << 16) | rom_write[i]); 
    441                 /* lame code fixme */ 
     453                /* Lame code FIXME */ 
    442454                checksum += rom_write[i] & 0xff; 
    443                 //checksum %= 256; 
     455                /* checksum %= 256; */ 
    444456                checksum += (rom_write[i] >> 8) & 0xff; 
    445                 //checksum %= 256; 
    446         } 
    447          
     457                /* checksum %= 256; */ 
     458        } 
     459 
    448460        checksum += (rom_write[15] & 0xff); 
    449461        checksum = ~(checksum & 0xff); 
    450462        tmp |= (((checksum & 0xff) << 8) | rom_write[15]); 
    451463 
    452         /* write last byte and checksum */ 
    453         pci_write_config32(dev, 0x58, (15 << 16) |  tmp); 
    454          
     464        /* Write last byte and checksum. */ 
     465        pci_write_config32(dev, 0x58, (15 << 16) | tmp); 
     466 
    455467        tmp = pci_read_config32(dev, 0x5c); 
    456         pci_write_config32(dev, 0x5c, tmp | 0x01000000); /* toggle SEEPR */ 
    457          
     468        pci_write_config32(dev, 0x5c, tmp | 0x01000000); /* Toggle SEEPR. */ 
     469 
    458470        /* Yes, this is a mess, but it's the easiest way to do it. */ 
    459         while ( (((pci_read_config32(dev, 0x5c) >> 25) & 1) == 0) 
    460                         && (loops < LAN_TIMEOUT)) 
     471        while ((((pci_read_config32(dev, 0x5c) >> 25) & 1) == 0) 
     472               && (loops < LAN_TIMEOUT)) { 
    461473                ++loops; 
     474        } 
    462475 
    463476        if (loops >= LAN_TIMEOUT) { 
    464             print_err("Timout - LAN controller did not accept configuration\n"); 
    465             return 0; 
    466         } 
    467          
    468         /* we are done, config will be used after PCIRST# */ 
     477                print_err("Timeout - LAN controller didn't accept config\n"); 
     478                return 0; 
     479        } 
     480 
     481        /* We are done, config will be used after PCIRST#. */ 
    469482        return 1; 
    470483} 
  • trunk/coreboot-v2/src/southbridge/via/vt8237r/vt8237r_lpc.c

    r3567 r3651  
    5555        /* IO-APIC virtual wire mode configuration. */ 
    5656        /* mask, trigger, polarity, destination, delivery, vector */ 
    57         {0,  ENABLED | TRIGGER_EDGE | POLARITY_HIGH | PHYSICAL_DEST | 
    58              ExtINT, NONE}, 
     57        {0, ENABLED | TRIGGER_EDGE | POLARITY_HIGH | PHYSICAL_DEST | 
     58                    ExtINT, NONE}, { 
    5959        {1,  DISABLED, NONE}, 
    6060        {2,  DISABLED, NONE}, 
     
    168168        pci_write_config8(dev, 0x93, 0x88); 
    169169 
    170         /* 7 = SMBus clock from RTC 32.768KHz 
     170        /* 
     171         * 7 = SMBus clock from RTC 32.768KHz 
    171172         * 5 = Internal PLL reset from susp 
    172173         * 2 = GPO2 is GPIO 
     
    174175        pci_write_config8(dev, 0x94, 0xa4); 
    175176 
    176         /* 7 = stp to sust delay 1msec 
     177        /* 
     178         * 7 = stp to sust delay 1msec 
    177179         * 6 = SUSST# Deasserted Before PWRGD for STD 
    178180         * 4 = PWRGOOD reset on VT8237A/S 
     
    217219        /* SCI is generated for RTC/pwrBtn/slpBtn. */ 
    218220        outw(0x001, VT8237R_ACPI_IO_BASE + 0x04); 
    219  
    220 } 
    221  
    222  
    223 static void vt8237r_init(struct device *dev) { 
     221} 
     222 
     223static void vt8237r_init(struct device *dev) 
     224{ 
    224225        u8 enables; 
    225