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
F150345741: D26111.id.diff
Tue, Mar 31, 9:47 AM
Unknown Object (File)
Mon, Mar 30, 3:03 AM
Unknown Object (File)
Thu, Mar 26, 9:55 AM
Unknown Object (File)
Wed, Mar 25, 1:07 AM
Unknown Object (File)
Wed, Mar 18, 2:47 AM
Unknown Object (File)
Wed, Mar 18, 2:37 AM
Unknown Object (File)
Tue, Mar 17, 7:37 AM
Unknown Object (File)
Tue, Mar 17, 3:27 AM
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