OpenBIC
OpenSource Bridge-IC
plat_ipmi.h
Go to the documentation of this file.
1/*
2 * Copyright (c) Meta Platforms, Inc. and affiliates.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17#ifndef PLAT_IPMI_H
18#define PLAT_IPMI_H
19
20#include <stdint.h>
21#include "ipmi.h"
22#include "plat_sensor_table.h"
23
24#define BIC_FW_DATA_LENGTH 7
25#define VR_FW_VERSION_LEN 4
26#define IS_SECTOR_END_MASK 0x80
27#define WITHOUT_SECTOR_END_MASK 0x7F
28#define BIC_UPDATE_MAX_OFFSET 0x50000
29
30#define CC_PEX_NOT_POWER_ON 0xB0
31#define CC_PEX_PRE_READING_FAIL 0xB1
32#define CC_PEX_ACCESS_FAIL 0xB2
33
34#define PCIE_CARD_ID_OFFSET 18
35#define RESERVE_DEFAULT_VALUE 0
36
37#define PCIE_CARD_NOT_PRESENT_BIT BIT(0)
38#define PCIE_CARD_NOT_ACCESSIBLE_BIT BIT(1)
39#define PCIE_CARD_DEVICE_NOT_READY_BIT BIT(2)
40
41#define FREYA_FW_VERSION_LENGTH sizeof(freya_fw_info)
42#define FREYA_READY 0
43#define FREYA_NOT_READY 1
44#define FREYA_SUPPORT_MODULE_IDENTIFIER 0
45#define FREYA_NOT_SUPPORT_MODULE_IDENTIFIER 1
46
47/* switch mux selection */
49 uint8_t device;
50 uint8_t control_gpio;
53};
54
87};
88
91
92#endif
struct SWITCH_MUX_INFO pcie_switch_mux_info[PEX_MAX_NUMBER]
Definition: plat_ipmi.c:44
void pal_construct_ipmi_add_sel_msg(ipmi_msg *msg, common_addsel_msg_t *sel_msg)
Definition: plat_ipmi.c:55
CB_FIRMWARE_COMPONENT
Definition: plat_ipmi.h:56
@ CB_COMPNT_ACCL11_CH1_FREYA
Definition: plat_ipmi.h:82
@ CB_COMPNT_CPLD
Definition: plat_ipmi.h:61
@ CB_COMPNT_PCIE_SWITCH1
Definition: plat_ipmi.h:60
@ CB_COMPNT_ACCL2_CH2_FREYA
Definition: plat_ipmi.h:65
@ CB_COMPNT_ACCL2_CH1_FREYA
Definition: plat_ipmi.h:64
@ CB_COMPNT_BIC
Definition: plat_ipmi.h:58
@ CB_COMPNT_ACCL8_CH2_FREYA
Definition: plat_ipmi.h:77
@ CB_COMPNT_ACCL9_CH2_FREYA
Definition: plat_ipmi.h:79
@ CB_COMPNT_ACCL5_CH1_FREYA
Definition: plat_ipmi.h:70
@ CB_COMPNT_ACCL10_CH1_FREYA
Definition: plat_ipmi.h:80
@ CB_COMPNT_ACCL3_CH1_FREYA
Definition: plat_ipmi.h:66
@ CB_COMPNT_ACCL7_CH1_FREYA
Definition: plat_ipmi.h:74
@ CB_COMPNT_VR_XDPE15284
Definition: plat_ipmi.h:57
@ CB_COMPNT_ACCL9_CH1_FREYA
Definition: plat_ipmi.h:78
@ CB_COMPNT_ACCL1_CH2_FREYA
Definition: plat_ipmi.h:63
@ CB_COMPNT_ACCL10_CH2_FREYA
Definition: plat_ipmi.h:81
@ CB_COMPNT_ACCL4_CH1_FREYA
Definition: plat_ipmi.h:68
@ CB_COMPNT_ACCL1_CH1_FREYA
Definition: plat_ipmi.h:62
@ CB_COMPNT_ACCL8_CH1_FREYA
Definition: plat_ipmi.h:76
@ CB_COMPNT_MAX
Definition: plat_ipmi.h:86
@ CB_COMPNT_ACCL5_CH2_FREYA
Definition: plat_ipmi.h:71
@ CB_COMPNT_ACCL12_CH2_FREYA
Definition: plat_ipmi.h:85
@ CB_COMPNT_ACCL3_CH2_FREYA
Definition: plat_ipmi.h:67
@ CB_COMPNT_PCIE_SWITCH0
Definition: plat_ipmi.h:59
@ CB_COMPNT_ACCL4_CH2_FREYA
Definition: plat_ipmi.h:69
@ CB_COMPNT_ACCL12_CH1_FREYA
Definition: plat_ipmi.h:84
@ CB_COMPNT_ACCL7_CH2_FREYA
Definition: plat_ipmi.h:75
@ CB_COMPNT_ACCL11_CH2_FREYA
Definition: plat_ipmi.h:83
@ CB_COMPNT_ACCL6_CH1_FREYA
Definition: plat_ipmi.h:72
@ CB_COMPNT_ACCL6_CH2_FREYA
Definition: plat_ipmi.h:73
#define PEX_MAX_NUMBER
Definition: plat_sensor_table.h:24
Definition: plat_ipmi.h:48
uint8_t sw_to_flash_value
Definition: plat_ipmi.h:51
uint8_t device
Definition: plat_ipmi.h:49
uint8_t bic_to_flash_value
Definition: plat_ipmi.h:52
uint8_t control_gpio
Definition: plat_ipmi.h:50
Definition: ipmi.h:53
Definition: ipmb.h:165