Use long unsigned for CPU socket type
PRIu64 to make compatible with both 32 and 64b
Fix format descriptor for cpu socket.
Change-Id: I1485b89d1d3cf896fc58d067469fd8fcff5bd776
Signed-off-by: Aushim Nagarkatti <anagarkatti@nvidia.com>
diff --git a/sections/cper-section-arm.c b/sections/cper-section-arm.c
index 35d0ef3..b56dc50 100644
--- a/sections/cper-section-arm.c
+++ b/sections/cper-section-arm.c
@@ -8,6 +8,7 @@
#include <stdio.h>
#include <string.h>
#include <json.h>
+#include <inttypes.h>
#include <libcper/base64.h>
#include <libcper/Cper.h>
#include <libcper/cper-utils.h>
@@ -114,7 +115,7 @@
char *node_desc_str = malloc(EFI_ERROR_DESCRIPTION_STRING_LEN);
outstr_len = snprintf(node_desc_str,
EFI_ERROR_DESCRIPTION_STRING_LEN,
- " on CPU %lu", sock);
+ " on CPU %" PRIu64, sock);
if (outstr_len < 0) {
cper_print_log(
"Error: Could not write to node description string\n");