diff options
author | Sebastian Andrzej Siewior <bigeasy@linutronix.de> | 2024-07-04 20:03:36 +0300 |
---|---|---|
committer | Peter Zijlstra <peterz@infradead.org> | 2024-07-09 14:26:34 +0300 |
commit | 466e4d801cd438a1ab2c8a2cce1bef6b65c31bbb (patch) | |
tree | 4608ba4395cb65142ba8974a900a0b9f85bded78 /tools/perf/scripts/python/exported-sql-viewer.py | |
parent | 058244c683111d44a5de16ac74f19a1754dd7a0c (diff) | |
download | linux-466e4d801cd438a1ab2c8a2cce1bef6b65c31bbb.tar.xz |
task_work: Add TWA_NMI_CURRENT as an additional notify mode.
Adding task_work from NMI context requires the following:
- The kasan_record_aux_stack() is not NMU safe and must be avoided.
- Using TWA_RESUME is NMI safe. If the NMI occurs while the CPU is in
userland then it will continue in userland and not invoke the `work'
callback.
Add TWA_NMI_CURRENT as an additional notify mode. In this mode skip
kasan and use irq_work in hardirq-mode to for needed interrupt. Set
TIF_NOTIFY_RESUME within the irq_work callback due to k[ac]san
instrumentation in test_and_set_bit() which does not look NMI safe in
case of a report.
Suggested-by: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lore.kernel.org/r/20240704170424.1466941-3-bigeasy@linutronix.de
Diffstat (limited to 'tools/perf/scripts/python/exported-sql-viewer.py')
0 files changed, 0 insertions, 0 deletions