| 1 |
|
| 2 |
|
| 3 |
#include <device/smbus_host.h> |
| 4 |
#include <device/pci_ops.h> |
| 5 |
#include "i82801dx.h" |
| 6 |
|
| 7 |
void i82801dx_early_init(void) |
| 8 |
{ |
| 9 |
const pci_devfn_t dev = PCI_DEV(0, 0x1f, 0); |
| 10 |
|
| 11 |
|
| 12 |
pci_write_config32(dev, PMBASE, DEFAULT_PMBASE | 1); |
| 13 |
pci_write_config8(dev, ACPI_CNTL, ACPI_EN); |
| 14 |
|
| 15 |
pci_write_config32(dev, GPIO_BASE, GPIOBASE_ADDR | 1); |
| 16 |
pci_write_config8(dev, GPIO_CNTL, 0x10); |
| 17 |
|
| 18 |
if (ENV_RAMINIT) |
| 19 |
enable_smbus(); |
| 20 |
} |
| 21 |
|
| 22 |
void i82801dx_lpc_setup(void) |
| 23 |
{ |
| 24 |
const pci_devfn_t dev = PCI_DEV(0, 0x1f, 0); |
| 25 |
|
| 26 |
|
| 27 |
|
| 28 |
|
| 29 |
|
| 30 |
|
| 31 |
pci_write_config8(dev, COM_DEC, 0x10); |
| 32 |
pci_write_config16(dev, LPC_EN, 0x300F); |
| 33 |
} |