coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
cpu.h
Go to the documentation of this file.
1
/* SPDX-License-Identifier: GPL-2.0-only */
2
3
#ifndef _SOC_CPU_H_
4
#define _SOC_CPU_H_
5
6
#include <
device/device.h
>
7
8
/* Latency times in units of 1024ns. */
9
#define C_STATE_LATENCY_CONTROL_0_LIMIT 0x4e
10
#define C_STATE_LATENCY_CONTROL_1_LIMIT 0x76
11
#define C_STATE_LATENCY_CONTROL_2_LIMIT 0x94
12
#define C_STATE_LATENCY_CONTROL_3_LIMIT 0xfa
13
#define C_STATE_LATENCY_CONTROL_4_LIMIT 0x14c
14
#define C_STATE_LATENCY_CONTROL_5_LIMIT 0x3f2
15
16
/* Power in units of mW */
17
#define C1_POWER 0x3e8
18
#define C3_POWER 0x1f4
19
#define C6_POWER 0x15e
20
#define C7_POWER 0xc8
21
#define C8_POWER 0xc8
22
#define C9_POWER 0xc8
23
#define C10_POWER 0xc8
24
25
#define C_STATE_LATENCY_MICRO_SECONDS(limit, base) \
26
(((1 << ((base)*5)) * (limit)) / 1000)
27
#define C_STATE_LATENCY_FROM_LAT_REG(reg) \
28
C_STATE_LATENCY_MICRO_SECONDS(C_STATE_LATENCY_CONTROL_ ##reg## _LIMIT, \
29
(IRTL_1024_NS >> 10))
30
31
/* CPU identification */
32
u32
cpu_family_model
(
void
);
33
u32
cpu_stepping
(
void
);
34
int
cpu_is_ult
(
void
);
35
36
#endif
device.h
cpu_is_ult
int cpu_is_ult(void)
cpu_stepping
u32 cpu_stepping(void)
cpu_family_model
u32 cpu_family_model(void)
u32
uint32_t u32
Definition:
stdint.h:51
src
soc
intel
skylake
include
soc
cpu.h
Generated by
1.9.1