Lawrence Tang | 214a154 | 2022-07-06 14:11:28 +0100 | [diff] [blame] | 1 | #ifndef CPER_SECTION_PCI_BUS_H |
| 2 | #define CPER_SECTION_PCI_BUS_H |
| 3 | |
Lawrence Tang | 5202bbb | 2022-08-12 14:54:36 +0100 | [diff] [blame] | 4 | #include <json.h> |
Lawrence Tang | 214a154 | 2022-07-06 14:11:28 +0100 | [diff] [blame] | 5 | #include "../edk/Cper.h" |
| 6 | |
John Chung | f8fc705 | 2024-05-03 20:05:29 +0800 | [diff] [blame] | 7 | #define PCI_BUS_ERROR_VALID_BITFIELD_NAMES \ |
| 8 | (const char *[]) \ |
| 9 | { \ |
| 10 | "errorStatusValid", "errorTypeValid", "busIDValid", \ |
| 11 | "busAddressValid", "busDataValid", "commandValid", \ |
| 12 | "requestorIDValid", "completerIDValid", \ |
| 13 | "targetIDValid" \ |
| 14 | } |
| 15 | #define PCI_BUS_ERROR_TYPES_KEYS \ |
| 16 | (int[]) \ |
| 17 | { \ |
| 18 | 0, 1, 2, 3, 4, 5, 6, 7 \ |
| 19 | } |
| 20 | #define PCI_BUS_ERROR_TYPES_VALUES \ |
| 21 | (const char *[]) \ |
| 22 | { \ |
| 23 | "Unknown/OEM Specific Error", "Data Parity Error", \ |
| 24 | "System Error", "Master Abort", \ |
| 25 | "Bus Timeout/No Device Present (No DEVSEL#)", \ |
| 26 | "Master Data Parity Error", "Address Parity Error", \ |
| 27 | "Command Parity Error" \ |
| 28 | } |
Lawrence Tang | 214a154 | 2022-07-06 14:11:28 +0100 | [diff] [blame] | 29 | |
John Chung | f8fc705 | 2024-05-03 20:05:29 +0800 | [diff] [blame] | 30 | json_object *cper_section_pci_bus_to_ir(void *section); |
| 31 | void ir_section_pci_bus_to_cper(json_object *section, FILE *out); |
Lawrence Tang | 214a154 | 2022-07-06 14:11:28 +0100 | [diff] [blame] | 32 | |
John Chung | f8fc705 | 2024-05-03 20:05:29 +0800 | [diff] [blame] | 33 | #endif |