diff mbox series

[v1,7/7] lib: sbi: Print number of debug triggers found

Message ID 20231219112856.3865827-8-hchauhan@ventanamicro.com
State Superseded
Headers show
Series Introduce support for SBI Debug Trigger Extension | expand

Commit Message

Himanshu Chauhan Dec. 19, 2023, 11:28 a.m. UTC
Print the total number of triggers found on the boot hart.

Signed-off-by: Himanshu Chauhan <hchauhan@ventanamicro.com>
---
 lib/sbi/sbi_init.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

Anup Patel Jan. 5, 2024, 4:19 p.m. UTC | #1
On Tue, Dec 19, 2023 at 4:59 PM Himanshu Chauhan
<hchauhan@ventanamicro.com> wrote:
>
> Print the total number of triggers found on the boot hart.
>
> Signed-off-by: Himanshu Chauhan <hchauhan@ventanamicro.com>
> ---
>  lib/sbi/sbi_init.c | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/lib/sbi/sbi_init.c b/lib/sbi/sbi_init.c
> index 0dcde27..061c5f2 100644
> --- a/lib/sbi/sbi_init.c
> +++ b/lib/sbi/sbi_init.c
> @@ -114,6 +114,8 @@ static void sbi_boot_print_general(struct sbi_scratch *scratch)
>         cppc_dev = sbi_cppc_get_device();
>         sbi_printf("Platform CPPC Device      : %s\n",
>                    (cppc_dev) ? cppc_dev->name : "---");
> +       sbi_printf("Platform Debug Triggers   : %d trigger(s) found.\n",
> +                  sbi_dbtr_get_total_triggers());

This should be part of sbi_boot_print_hart()

>
>         /* Firmware details */
>         sbi_printf("Firmware Base             : 0x%lx\n", scratch->fw_start);
> --
> 2.34.1
>
>
> --
> opensbi mailing list
> opensbi@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/opensbi

Regards,
Anup
diff mbox series

Patch

diff --git a/lib/sbi/sbi_init.c b/lib/sbi/sbi_init.c
index 0dcde27..061c5f2 100644
--- a/lib/sbi/sbi_init.c
+++ b/lib/sbi/sbi_init.c
@@ -114,6 +114,8 @@  static void sbi_boot_print_general(struct sbi_scratch *scratch)
 	cppc_dev = sbi_cppc_get_device();
 	sbi_printf("Platform CPPC Device      : %s\n",
 		   (cppc_dev) ? cppc_dev->name : "---");
+	sbi_printf("Platform Debug Triggers   : %d trigger(s) found.\n",
+		   sbi_dbtr_get_total_triggers());
 
 	/* Firmware details */
 	sbi_printf("Firmware Base             : 0x%lx\n", scratch->fw_start);