blob: 0f984768e9cb96b59075284c8918ec943235fc16 [file] [log] [blame]
Bin Meng2229c4c2015-05-07 21:34:08 +08001/*
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/post.h>
9#include <asm/processor.h>
10
11int arch_cpu_init(void)
12{
13 int ret;
14
15 post_code(POST_CPU_INIT);
16#ifdef CONFIG_SYS_X86_TSC_TIMER
17 timer_set_base(rdtsc());
18#endif
19
20 ret = x86_cpu_init_f();
21 if (ret)
22 return ret;
23
24 return 0;
25}
26
27int print_cpuinfo(void)
28{
29 post_code(POST_CPU_INFO);
30 return default_print_cpuinfo();
31}
32
33void reset_cpu(ulong addr)
34{
35 /* cold reset */
36 x86_full_reset();
37}