Page MenuHomeFreeBSD

[PowerPC] Move pmc_hook out of critical section
ClosedPublic

Authored by luporl on Aug 18 2020, 6:37 PM.
Tags
None
Referenced Files
F171377035: D26111.diff
Thu, Sep 10, 7:10 PM
Unknown Object (File)
Sat, Sep 5, 11:08 PM
Unknown Object (File)
Sat, Sep 5, 9:32 PM
Unknown Object (File)
Sat, Sep 5, 11:54 AM
Unknown Object (File)
Sat, Sep 5, 6:13 AM
Unknown Object (File)
Sat, Sep 5, 5:06 AM
Unknown Object (File)
Thu, Sep 3, 8:57 PM
Unknown Object (File)
Thu, Sep 3, 7:59 PM
Subscribers

Details

Summary

Calling pmc_hook inside a critical section may result in a panic.

This happens when the user callchain is fetched, because it uses pmap_map_user_ptr, that tries to get the (sleepable) pmap lock when the needed vsid is not found.

Judging by the implementation in other platforms, intr_irq_handler in kern/subr_intr.c and what pmc_hook do, it seems safe to move pmc_hook outside the critical section.

Diff Detail

Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 33051
Build 30434: arc lint + arc unit