diff options
author | Uwe Hermann <uwe@hermann-uwe.de> | 2010-11-06 23:36:49 +0000 |
---|---|---|
committer | Uwe Hermann <uwe@hermann-uwe.de> | 2010-11-06 23:36:49 +0000 |
commit | 8c02368e2d2e0574cf3999939f7cd26407cdf93a (patch) | |
tree | 2996402213709670055760e58caa605474a76b44 /src/superio/serverengines | |
parent | 9915944b18847b5e83b664a3e445645a2a4c8578 (diff) | |
download | coreboot-8c02368e2d2e0574cf3999939f7cd26407cdf93a.tar.xz |
Various Super I/O fixes and corrections.
- VIA VT1211:
- Add missing LDNs and respective code to handle them.
- Add some TODOs for other stuff that needs fixing.
- Use VT1211_SP1 instead of hardcoding the LDN number (2).
- Fixup pnp_dev_info[] as per datasheet, but some TODOs remain.
- Various coding style fixes and changes to u8/u16/etc.
- Serverengines Pilot: Various coding style fixes and changes to u8/u16/etc.
Signed-off-by: Uwe Hermann <uwe@hermann-uwe.de>
Acked-by: Uwe Hermann <uwe@hermann-uwe.de>
git-svn-id: svn://svn.coreboot.org/coreboot/trunk@6030 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'src/superio/serverengines')
-rw-r--r-- | src/superio/serverengines/pilot/pilot.h | 2 | ||||
-rw-r--r-- | src/superio/serverengines/pilot/pilot_early_init.c | 4 | ||||
-rw-r--r-- | src/superio/serverengines/pilot/pilot_early_serial.c | 10 |
3 files changed, 9 insertions, 7 deletions
diff --git a/src/superio/serverengines/pilot/pilot.h b/src/superio/serverengines/pilot/pilot.h index de75a94276..de9ec9f832 100644 --- a/src/superio/serverengines/pilot/pilot.h +++ b/src/superio/serverengines/pilot/pilot.h @@ -21,8 +21,8 @@ /* PILOT Super I/O is only based on LPC observation done on factory system. */ -#define PILOT_SP1 0x02 /* Com1 */ #define PILOT_LD1 0x01 /* Logical device 1 */ +#define PILOT_SP1 0x02 /* Com1 */ #define PILOT_LD4 0x04 /* Logical device 4 */ #define PILOT_LD5 0x05 /* Logical device 5 */ #define PILOT_LD7 0x07 /* Logical device 7 */ diff --git a/src/superio/serverengines/pilot/pilot_early_init.c b/src/superio/serverengines/pilot/pilot_early_init.c index f5444ac4f5..e88c5d4198 100644 --- a/src/superio/serverengines/pilot/pilot_early_init.c +++ b/src/superio/serverengines/pilot/pilot_early_init.c @@ -29,7 +29,7 @@ */ static void pilot_early_init(device_t dev) { - unsigned port = dev >> 8; + u16 port = dev >> 8; print_debug("Using port: "); print_debug_hex16(port); @@ -55,6 +55,7 @@ static void pilot_early_init(device_t dev) pnp_set_enable(PNP_DEV(port, 0x3), 0); pnp_exit_ext_func_mode(dev); */ + pnp_enter_ext_func_mode(dev); pnp_set_logical_device(PNP_DEV(port, 0x4)); pnp_exit_ext_func_mode(dev); @@ -95,6 +96,7 @@ static void pilot_early_init(device_t dev) pnp_enter_ext_func_mode(dev); pnp_set_enable(PNP_DEV(port, 0x7), 0); pnp_exit_ext_func_mode(dev); + /* pnp_enter_ext_func_mode(dev); pnp_set_logical_device(PNP_DEV(port, 0x8)); diff --git a/src/superio/serverengines/pilot/pilot_early_serial.c b/src/superio/serverengines/pilot/pilot_early_serial.c index 7890633cfd..a2bbec481e 100644 --- a/src/superio/serverengines/pilot/pilot_early_serial.c +++ b/src/superio/serverengines/pilot/pilot_early_serial.c @@ -25,20 +25,20 @@ #include "pilot.h" /* Pilot uses 0x5A/0xA5 pattern to actiavte deactivate config access. */ -static inline void pnp_enter_ext_func_mode(device_t dev) +static void pnp_enter_ext_func_mode(device_t dev) { - unsigned port = dev >> 8; + u16 port = dev >> 8; outb(0x5A, port); } static void pnp_exit_ext_func_mode(device_t dev) { - unsigned port = dev >> 8; + u16 port = dev >> 8; outb(0xA5, port); } /* Serial config is a fairly standard procedure. */ -static void pilot_enable_serial(device_t dev, unsigned iobase) +static void pilot_enable_serial(device_t dev, u16 iobase) { pnp_enter_ext_func_mode(dev); pnp_set_logical_device(dev); @@ -51,7 +51,7 @@ static void pilot_disable_serial(device_t dev) { pnp_enter_ext_func_mode(dev); pnp_set_logical_device(dev); - pnp_set_iobase(dev, PNP_IDX_IO0, 0x00); + pnp_set_iobase(dev, PNP_IDX_IO0, 0x0000); pnp_set_enable(dev, 0); pnp_exit_ext_func_mode(dev); } |