2022-10-07 10:01:33 +08:00
|
|
|
/*
|
|
|
|
* Copyright (c) 2006-2021, RT-Thread Development Team
|
|
|
|
*
|
|
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
|
|
*
|
|
|
|
* Change Logs:
|
|
|
|
* Date Author Notes
|
|
|
|
*/
|
|
|
|
#include <rtthread.h>
|
|
|
|
#include "pmu.h"
|
|
|
|
|
2022-12-03 12:07:44 +08:00
|
|
|
#define DBG_TAG "PMU"
|
|
|
|
#define DBG_LVL DBG_WARNING
|
|
|
|
#include <rtdbg.h>
|
|
|
|
|
2022-10-07 10:01:33 +08:00
|
|
|
void rt_hw_pmu_dump_feature(void)
|
|
|
|
{
|
|
|
|
unsigned long reg;
|
|
|
|
|
|
|
|
reg = rt_hw_pmu_get_control();
|
2022-12-03 12:07:44 +08:00
|
|
|
LOG_D("ARM PMU Implementor: %c, ID code: %02x, %d counters\n",
|
|
|
|
reg >> 24, (reg >> 16) & 0xff, (reg >> 11) & 0x1f);
|
2022-10-07 10:01:33 +08:00
|
|
|
RT_ASSERT(ARM_PMU_CNTER_NR == ((reg >> 11) & 0x1f));
|
2024-03-28 23:42:56 +08:00
|
|
|
RT_UNUSED(reg);
|
2022-10-07 10:01:33 +08:00
|
|
|
}
|