blob: 53aa176b3881cc7e1350394c031391faef1421a1 [file] [log] [blame]
Arthur Heymans15412562018-07-18 11:48:47 +02001/*
2 * This file is part of the coreboot project.
3 *
4 * Copyright (C) 2018 Arthur Heymans <arthur@aheymans.xyz>
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 */
16
Arthur Heymans15412562018-07-18 11:48:47 +020017#include <southbridge/intel/i82801jx/i82801jx.h>
Arthur Heymans15412562018-07-18 11:48:47 +020018#include <northbridge/intel/x4x/x4x.h>
Arthur Heymans15412562018-07-18 11:48:47 +020019#include <superio/winbond/w83667hg-a/w83667hg-a.h>
20#include <superio/winbond/common/winbond.h>
Arthur Heymans15412562018-07-18 11:48:47 +020021
22#define SERIAL_DEV PNP_DEV(0x2e, W83667HG_A_SP1)
Arthur Heymans15412562018-07-18 11:48:47 +020023
Arthur Heymansbf53acc2019-11-11 21:14:39 +010024void mb_lpc_setup(void)
Arthur Heymans15412562018-07-18 11:48:47 +020025{
Arthur Heymans15412562018-07-18 11:48:47 +020026 /* TODO? */
27 RCBA32(RCBA_CG) = 0xbf7f001f;
28 RCBA32(0x3430) = 0x00000002;
29 RCBA32(0x3f00) = 0x00000038;
Arthur Heymansbf53acc2019-11-11 21:14:39 +010030
31 winbond_enable_serial(SERIAL_DEV, CONFIG_TTYS0_BASE);
Arthur Heymans15412562018-07-18 11:48:47 +020032}
33
Arthur Heymansbf53acc2019-11-11 21:14:39 +010034void mb_get_spd_map(u8 spd_map[4])
Arthur Heymans15412562018-07-18 11:48:47 +020035{
Arthur Heymansbf53acc2019-11-11 21:14:39 +010036 spd_map[0] = 0x50;
37 spd_map[1] = 0x51;
38 spd_map[2] = 0x52;
39 spd_map[3] = 0x53;
Arthur Heymans15412562018-07-18 11:48:47 +020040}