fix(handoff): fix message formatting of hex values

Our implementation of printf does not support flag format specifiers.
Our previous format specification as a result was causing the integer
values to be omitted. This change updates the formatting to ensure
accurate and complete error messages are displayed.

Change-Id: I80cfb5fd7ff26e44cfad4e06803d9e0912488136
Signed-off-by: Harrison Mutai <harrison.mutai@arm.com>
This commit is contained in:
Harrison Mutai 2024-11-28 14:31:41 +00:00
parent f1d9459335
commit 24e1ae2f0e

View file

@ -168,30 +168,29 @@ transfer_list_check_header(const struct transfer_list_header *tl)
}
if (tl->signature != TRANSFER_LIST_SIGNATURE) {
ERROR("Bad transfer list signature %#" PRIx32 "\n",
tl->signature);
ERROR("Bad transfer list signature 0x%x\n", tl->signature);
return TL_OPS_NON;
}
if (!tl->max_size) {
ERROR("Bad transfer list max size %#" PRIx32 "\n",
ERROR("Bad transfer list max size 0x%x\n",
tl->max_size);
return TL_OPS_NON;
}
if (tl->size > tl->max_size) {
ERROR("Bad transfer list size %#" PRIx32 "\n", tl->size);
ERROR("Bad transfer list size 0x%x\n", tl->size);
return TL_OPS_NON;
}
if (tl->hdr_size != sizeof(struct transfer_list_header)) {
ERROR("Bad transfer list header size %#" PRIx32 "\n",
ERROR("Bad transfer list header size 0x%x\n",
tl->hdr_size);
return TL_OPS_NON;
}
if (!transfer_list_verify_checksum(tl)) {
ERROR("Bad transfer list checksum %#" PRIx32 "\n",
ERROR("Bad transfer list checksum 0x%x\n",
tl->checksum);
return TL_OPS_NON;
}