Page MenuHomeFreeBSD

kern/intr: implement isrc_release_counters()
AbandonedPublic

Authored by ehem_freebsd_m5p.com on Jun 3 2021, 11:29 PM.
Tags
None
Referenced Files
Unknown Object (File)
Jan 22 2024, 12:22 AM
Unknown Object (File)
Dec 23 2023, 7:10 AM
Unknown Object (File)
Dec 1 2023, 8:54 PM
Unknown Object (File)
Sep 3 2023, 7:28 AM
Unknown Object (File)
Aug 17 2023, 1:53 PM
Unknown Object (File)
Jul 4 2023, 8:18 AM
Unknown Object (File)
Feb 15 2023, 9:29 PM
Unknown Object (File)
Dec 26 2022, 11:45 PM
Subscribers

Details

Summary

Finally get this unimplemented function implemented. Primary
observation is distinctions of IPI interrupts means their counters need
distinct handling. Use low portion of array for external interrupts
(which always have 2 counters) and high portion for IPI interrupts
(which have more).

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 39701
Build 36590: arc lint + arc unit

Event Timeline

Theory is to make intr_isrc_deregister() work in the general case. Without this (or a fixed version) isrc_release_counters() is of course a wrapper around panic(). What needs checking is I'm unsure of how the atomic_*() functions are supposed to work, I think I got their use right, but please check. Actual hardware removable interrupt sources aren't common, but software removable ones are quite common (VMs).

Careful review and looks like atomic_store_rel_int() is needed inside isrc_release_counters(). Otherwise stores could move after and that would break. The accesses in isrc_setup_counters() all depend upon "index" which is synchronized.

Obsoleted by several other bits.