From 4565aea8fbb114f65ecce7bdaaa538f80c382599 Mon Sep 17 00:00:00 2001 From: Edward O'Callaghan Date: Sun, 7 Jun 2015 19:42:47 +1000 Subject: southbridge/amd/{agesa,pi}/hudson/lpc.c: Sync together Resync together, backporting a fix for the initialization of 8254 and 8259, as in commit 8d9a1bd5. Also fix a typo and reduce out useless whitespace differences. Change-Id: I9a9b1fb9083c5417a8d061f90a89074f2a601ddf Signed-off-by: Edward O'Callaghan Reported-by: Paul Menzel Reviewed-on: http://review.coreboot.org/10453 Tested-by: build bot (Jenkins) Reviewed-by: Stefan Reinauer --- src/southbridge/amd/agesa/hudson/lpc.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'src/southbridge/amd/agesa/hudson') diff --git a/src/southbridge/amd/agesa/hudson/lpc.c b/src/southbridge/amd/agesa/hudson/lpc.c index 65cb955047..c727fa9fa1 100644 --- a/src/southbridge/amd/agesa/hudson/lpc.c +++ b/src/southbridge/amd/agesa/hudson/lpc.c @@ -30,6 +30,8 @@ #include #include #include +#include +#include #include "hudson.h" static void lpc_init(device_t dev) @@ -79,6 +81,12 @@ static void lpc_init(device_t dev) * 1 tells cmos_init to always initialize the CMOS. */ cmos_init(0); + + /* Initialize i8259 pic */ + setup_i8259 (); + + /* Initialize i8254 timers */ + setup_i8254 (); } static void hudson_lpc_read_resources(device_t dev) @@ -320,7 +328,6 @@ unsigned long acpi_fill_mcfg(unsigned long current) return current; } - static struct pci_operations lops_pci = { .set_subsystem = pci_dev_set_subsystem, }; @@ -328,10 +335,10 @@ static struct pci_operations lops_pci = { static struct device_operations lpc_ops = { .read_resources = hudson_lpc_read_resources, .set_resources = hudson_lpc_set_resources, + .enable_resources = hudson_lpc_enable_resources, #if IS_ENABLED(CONFIG_HAVE_ACPI_TABLES) .write_acpi_tables = acpi_write_hpet, #endif - .enable_resources = hudson_lpc_enable_resources, .init = lpc_init, .scan_bus = scan_lpc_bus, .ops_pci = &lops_pci, -- cgit v1.2.3