blob: 17dcedfd7e58a958fc677bd1a8a20d839b6b068b [file] [log] [blame]
Lawrence Tangd7e8ca32022-07-07 10:25:53 +01001#ifndef CPER_SECTION_CXL_COMPONENT_H
2#define CPER_SECTION_CXL_COMPONENT_H
3
4#include "json.h"
5#include "../edk/Cper.h"
6
7///
8/// CXL Generic Component Error Section
9///
10typedef struct {
11 UINT64 VendorId : 16;
12 UINT64 DeviceId : 16;
13 UINT64 FunctionNumber : 8;
14 UINT64 DeviceNumber : 8;
15 UINT64 BusNumber : 8;
16 UINT64 SegmentNumber : 16;
17 UINT64 Resv1 : 3;
18 UINT64 SlotNumber : 13;
19 UINT64 Resv2 : 8;
20} EFI_CXL_DEVICE_ID_INFO;
21
22typedef struct {
23 UINT32 Length;
24 UINT64 ValidBits;
25 EFI_CXL_DEVICE_ID_INFO DeviceId;
26 UINT64 DeviceSerial;
27} EFI_CXL_COMPONENT_EVENT_HEADER;
28
29typedef struct {
30 //todo: What is the structure for this? The UEFI spec is a bit vague.
31} EFI_CXL_COMPONENT_COMMON_RECORD_HEAD;
32
33json_object* cper_section_cxl_component_to_ir(void* section, EFI_ERROR_SECTION_DESCRIPTOR* descriptor);
34
35#endif