critmonitor: add caller support

Signed-off-by: ligd <liguiding1@xiaomi.com>
This commit is contained in:
ligd
2024-05-30 11:05:24 +08:00
committed by Xiang Xiao
parent e28b311b78
commit 90dcd5edd3
7 changed files with 39 additions and 21 deletions
+4 -4
View File
@@ -383,7 +383,7 @@ try_again_in_irq:
/* Note that we have entered the critical section */
#if CONFIG_SCHED_CRITMONITOR_MAXTIME_CSECTION >= 0
nxsched_critmon_csection(rtcb, true);
nxsched_critmon_csection(rtcb, true, return_address(0));
#endif
#ifdef CONFIG_SCHED_INSTRUMENTATION_CSECTION
sched_note_csection(rtcb, true);
@@ -423,7 +423,7 @@ irqstate_t enter_critical_section(void)
/* Note that we have entered the critical section */
#if CONFIG_SCHED_CRITMONITOR_MAXTIME_CSECTION >= 0
nxsched_critmon_csection(rtcb, true);
nxsched_critmon_csection(rtcb, true, return_address(0));
#endif
#ifdef CONFIG_SCHED_INSTRUMENTATION_CSECTION
sched_note_csection(rtcb, true);
@@ -524,7 +524,7 @@ void leave_critical_section(irqstate_t flags)
/* No.. Note that we have left the critical section */
#if CONFIG_SCHED_CRITMONITOR_MAXTIME_CSECTION >= 0
nxsched_critmon_csection(rtcb, false);
nxsched_critmon_csection(rtcb, false, return_address(0));
#endif
#ifdef CONFIG_SCHED_INSTRUMENTATION_CSECTION
sched_note_csection(rtcb, false);
@@ -578,7 +578,7 @@ void leave_critical_section(irqstate_t flags)
/* Note that we have left the critical section */
#if CONFIG_SCHED_CRITMONITOR_MAXTIME_CSECTION >= 0
nxsched_critmon_csection(rtcb, false);
nxsched_critmon_csection(rtcb, false, return_address(0));
#endif
#ifdef CONFIG_SCHED_INSTRUMENTATION_CSECTION
sched_note_csection(rtcb, false);