[PATCH v2 01/20] lib: sbi: print hartid in hex

Vladimir Kondratiev vladimir.kondratiev at mobileye.com
Sun Jan 18 03:37:43 PST 2026


Hartid is better represented by hex number since it is likely
a combination of bits representing various elements in the
platform hierarchy

Signed-off-by: Vladimir Kondratiev <vladimir.kondratiev at mobileye.com>
---
 lib/sbi/sbi_domain.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/sbi/sbi_domain.c b/lib/sbi/sbi_domain.c
index 4f458ac0f56169d47598a8d0b93140bf0d2f8974..7030848dca1af58ed120de13a8c0deaa378af8dc 100644
--- a/lib/sbi/sbi_domain.c
+++ b/lib/sbi/sbi_domain.c
@@ -541,7 +541,7 @@ void sbi_domain_dump(const struct sbi_domain *dom, const char *suffix)
 	sbi_printf("Domain%d HARTs       %s: ", dom->index, suffix);
 	sbi_hartmask_for_each_hartindex(i, dom->possible_harts) {
 		j = sbi_hartindex_to_hartid(i);
-		sbi_printf("%s%d%s", (k++) ? "," : "",
+		sbi_printf("%s0x%x%s", (k++) ? "," : "",
 			   j, sbi_domain_is_assigned_hart(dom, i) ? "*" : "");
 	}
 	sbi_printf("\n");

-- 
2.43.0




More information about the opensbi mailing list