summaryrefslogtreecommitdiff
path: root/scripts/create-binary-archive.sh
diff options
context:
space:
mode:
authorAtish Patra <[email protected]>2021-07-10 09:18:06 -0700
committerAnup Patel <[email protected]>2021-07-11 10:14:26 +0530
commit9c9b4ad24bf5891272679a6e994c64463db8ca03 (patch)
treec16842683e501f499693201a4884c338bb81c558 /scripts/create-binary-archive.sh
parent0829f2bc284c07576a0dc9a569beea2a2d68dc3d (diff)
lib: sbi: Disable m/scounteren & enable mcountinhibit
Currently, all bits in mcountern are enabled unconditionally at boot time. With SBI PMU extension, all the programmable counters should enabled only during performance monitoring for a particular event. However, this is done only if mcountinhibit is implemented because the supervisor mode can not start/stop any event without mcountinhibit. Similarly, supervisor should take care enabling scounteren which allows U-mode to access programmable pmu counters. All the non-programmable ones (CY, TM, IR) should be enabled in M-mode because some userspace may rely on builtins such as __builtin_readcyclecounter. Supervisor OS can still disable them during initial configuration. Reviewed-by: Anup Patel <[email protected]> Signed-off-by: Atish Patra <[email protected]>
Diffstat (limited to 'scripts/create-binary-archive.sh')
0 files changed, 0 insertions, 0 deletions