coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
ipmi_ocp.h
Go to the documentation of this file.
1
/* SPDX-License-Identifier: GPL-2.0-or-later */
2
3
#ifndef __IPMI_OCP_H
4
#define __IPMI_OCP_H
5
6
#include <
commonlib/bsd/cb_err.h
>
7
8
#define IPMI_NETFN_OEM 0x30
9
#define IPMI_OEM_SET_PPIN 0x77
10
#define IPMI_BMC_SET_POST_START 0x73
11
#define IPMI_OEM_SET_BIOS_BOOT_ORDER 0x52
12
#define IPMI_OEM_GET_BIOS_BOOT_ORDER 0x53
13
14
#define CMOS_BIT (1 << 1)
15
#define VALID_BIT (1 << 7)
16
#define CLEAR_CMOS_AND_VALID_BIT(x) ((x) &= ~(CMOS_BIT | VALID_BIT))
17
#define SET_CMOS_AND_VALID_BIT(x) ((x) |= (CMOS_BIT | VALID_BIT))
18
#define IS_CMOS_AND_VALID_BIT(x) ((x)&CMOS_BIT && (x)&VALID_BIT)
19
20
struct
ppin_req
{
21
uint32_t
cpu0_lo
;
22
uint32_t
cpu0_hi
;
23
uint32_t
cpu1_lo
;
24
uint32_t
cpu1_hi
;
25
}
__packed
;
26
27
struct
boot_order
{
28
uint8_t
boot_mode
;
29
uint8_t
boot_dev0
;
30
uint8_t
boot_dev1
;
31
uint8_t
boot_dev2
;
32
uint8_t
boot_dev3
;
33
uint8_t
boot_dev4
;
34
}
__packed
;
35
36
enum
cb_err
ipmi_set_post_start
(
const
int
port
);
37
enum
cb_err
ipmi_set_cmos_clear
(
void
);
38
#endif
cb_err.h
cb_err
cb_err
coreboot error codes
Definition:
cb_err.h:15
port
port
Definition:
i915.h:29
__packed
struct ppin_req __packed
ipmi_set_post_start
enum cb_err ipmi_set_post_start(const int port)
Definition:
ipmi_ocp_romstage.c:8
ipmi_set_cmos_clear
enum cb_err ipmi_set_cmos_clear(void)
Definition:
ipmi_ocp_romstage.c:31
uint32_t
unsigned int uint32_t
Definition:
stdint.h:14
uint8_t
unsigned char uint8_t
Definition:
stdint.h:8
boot_order
Definition:
ipmi_ocp.h:27
boot_order::boot_dev3
uint8_t boot_dev3
Definition:
ipmi_ocp.h:32
boot_order::boot_dev4
uint8_t boot_dev4
Definition:
ipmi_ocp.h:33
boot_order::boot_dev2
uint8_t boot_dev2
Definition:
ipmi_ocp.h:31
boot_order::boot_dev0
uint8_t boot_dev0
Definition:
ipmi_ocp.h:29
boot_order::boot_mode
uint8_t boot_mode
Definition:
ipmi_ocp.h:28
boot_order::boot_dev1
uint8_t boot_dev1
Definition:
ipmi_ocp.h:30
ppin_req
Definition:
ipmi_ocp.h:20
ppin_req::cpu1_lo
uint32_t cpu1_lo
Definition:
ipmi_ocp.h:23
ppin_req::cpu0_lo
uint32_t cpu0_lo
Definition:
ipmi_ocp.h:21
ppin_req::cpu1_hi
uint32_t cpu1_hi
Definition:
ipmi_ocp.h:24
ppin_req::cpu0_hi
uint32_t cpu0_hi
Definition:
ipmi_ocp.h:22
src
drivers
ipmi
ocp
ipmi_ocp.h
Generated by
1.9.1