Skip to content

Commit

Permalink
AcpiPlatformDxe: Update BERT size for additional RAS records captured
Browse files Browse the repository at this point in the history
BERT size has increased to capture additional RAS IP error records.
Update the BERT size to accommodate the new entries. This also updates
the current BERT version (CURRENT_BERT_VERION) as the crash dump data
structure has changed.

Signed-off-by: Nhi Pham <npham@amperecomputing.com>
  • Loading branch information
nhivp committed Jul 30, 2021
1 parent 3e9b55d commit 772eb9a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Platform/Ampere/JadePkg/Drivers/AcpiPlatformDxe/AcpiApei.c
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ WrapBertErrorData (
CrashSize = PLAT_CRASH_ITERATOR_SIZE *
GetNumberOfSupportedSockets () *
GetMaximumNumberOfCores ();
CrashSize += 2 * (SMPRO_CRASH_SIZE + PMPRO_CRASH_SIZE);
CrashSize += 2 * (SMPRO_CRASH_SIZE + PMPRO_CRASH_SIZE + RASIP_CRASH_SIZE);
CrashSize += sizeof (WrappedError->Bed.Vendor) + sizeof (WrappedError->Bed.BertRev);

WrappedError->Ges.BlockStatus.ErrorDataEntryCount = 1;
Expand Down
5 changes: 4 additions & 1 deletion Platform/Ampere/JadePkg/Drivers/AcpiPlatformDxe/AcpiApei.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,10 @@
#define PLAT_CRASH_ITERATOR_SIZE 0x398
#define SMPRO_CRASH_SIZE 0x800
#define PMPRO_CRASH_SIZE 0x800
#define RASIP_CRASH_SIZE 0x1000
#define HEST_NUM_ENTRIES_PER_SOC 3

#define CURRENT_BERT_VERSION 0x10
#define CURRENT_BERT_VERSION 0x11
#define BERT_FLASH_OFFSET 0x91B30000ULL
#define BERT_DDR_OFFSET 0x88230000ULL
#define BERT_DDR_LENGTH 0x50000
Expand All @@ -55,8 +56,10 @@ typedef struct {
UINT8 BertRev;
UINT8 S0PmproRegisters[PMPRO_CRASH_SIZE];
UINT8 S0SmproRegisters[SMPRO_CRASH_SIZE];
UINT8 S0RasIpRegisters[RASIP_CRASH_SIZE];
UINT8 S1PmproRegisters[PMPRO_CRASH_SIZE];
UINT8 S1SmproRegisters[SMPRO_CRASH_SIZE];
UINT8 S1RasIpRegisters[RASIP_CRASH_SIZE];
UINT8 AtfDump[PLATFORM_CPU_MAX_NUM_CORES * PLAT_CRASH_ITERATOR_SIZE];
} APEI_CRASH_DUMP_DATA;

Expand Down

0 comments on commit 772eb9a

Please sign in to comment.