blob: 25abb27899c6761c7e5fb9f1bdc36a14c161ecca [file] [log] [blame]
Zaolina823f9b2014-05-06 21:31:45 +02001/*
2 * This file is part of the coreboot project.
3 *
4 * Copyright (C) 2007-2009 coresystems GmbH
5 * Copyright (C) 2011-2012 Google Inc.
6 * Copyright (C) 2014 Vladimir Serbinenko
7 *
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; version 2 of the License.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
Zaolina823f9b2014-05-06 21:31:45 +020016 */
17
18#include <types.h>
19#include <string.h>
20#include <device/device.h>
21#include <device/pci_def.h>
22#include <device/pci_ops.h>
23#include <console/console.h>
Vladimir Serbinenkoa2a906e2014-09-01 01:41:37 +020024#include <drivers/intel/gma/int15.h>
Zaolina823f9b2014-05-06 21:31:45 +020025#include <pc80/mc146818rtc.h>
26#include <arch/acpi.h>
27#include <arch/io.h>
28#include <arch/interrupt.h>
29#include <boot/coreboot_tables.h>
Zaolina823f9b2014-05-06 21:31:45 +020030#include <southbridge/intel/bd82x6x/pch.h>
31#include <smbios.h>
32#include <device/pci.h>
33#include <cbfs.h>
34#include <pc80/keyboard.h>
Elyes HAOUAS68a97162014-07-31 10:39:57 +020035#include <ec/lenovo/h8/h8.h>
Zaolina823f9b2014-05-06 21:31:45 +020036
Zaolina823f9b2014-05-06 21:31:45 +020037static void mainboard_init(device_t dev)
38{
39 RCBA32(0x38c8) = 0x00002005;
40 RCBA32(0x38c4) = 0x00802005;
41 RCBA32(0x38c0) = 0x00000007;
Zaolina823f9b2014-05-06 21:31:45 +020042}
43
44/* mainboard_enable is executed as first thing after
45enumerate_buses(). */
46static void mainboard_enable(device_t dev)
47{
48 dev->ops->init = mainboard_init;
Vladimir Serbinenkoa2a906e2014-09-01 01:41:37 +020049 install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS, GMA_INT15_PANEL_FIT_DEFAULT, GMA_INT15_BOOT_DISPLAY_DEFAULT, 0);
Zaolina823f9b2014-05-06 21:31:45 +020050}
51
Zaolina823f9b2014-05-06 21:31:45 +020052void h8_mainboard_init_dock (void)
53{
54 return;
55}
56
57struct chip_operations mainboard_ops = {
58 .enable_dev = mainboard_enable,
59};