xref: /openbmc/u-boot/arch/x86/cpu/quark/quark.c (revision b1420c81)
1 /*
2  * Copyright (C) 2015, Bin Meng <bmeng.cn@gmail.com>
3  *
4  * SPDX-License-Identifier:	GPL-2.0+
5  */
6 
7 #include <common.h>
8 #include <asm/io.h>
9 #include <asm/pci.h>
10 #include <asm/post.h>
11 #include <asm/processor.h>
12 
13 int arch_cpu_init(void)
14 {
15 	struct pci_controller *hose;
16 	int ret;
17 
18 	post_code(POST_CPU_INIT);
19 #ifdef CONFIG_SYS_X86_TSC_TIMER
20 	timer_set_base(rdtsc());
21 #endif
22 
23 	ret = x86_cpu_init_f();
24 	if (ret)
25 		return ret;
26 
27 	ret = pci_early_init_hose(&hose);
28 	if (ret)
29 		return ret;
30 
31 	return 0;
32 }
33 
34 int print_cpuinfo(void)
35 {
36 	post_code(POST_CPU_INFO);
37 	return default_print_cpuinfo();
38 }
39 
40 void reset_cpu(ulong addr)
41 {
42 	/* cold reset */
43 	outb(0x08, PORT_RESET);
44 }
45