Page MenuHomeFreeBSD

intrng: merge separated PIC types
Needs ReviewPublic

Authored by ehem_freebsd_m5p.com on Feb 19 2024, 7:58 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Apr 19, 3:42 PM
Unknown Object (File)
Fri, Apr 19, 3:40 PM
Unknown Object (File)
Feb 22 2024, 8:35 AM
Subscribers

Details

Reviewers
jrtc27
mmel
Summary

"Normal PIC" and "MSI PIC" are not mutually exclusive. Many controllers
perform both tasks, so merge records for both types together.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 56111
Build 52999: arc lint + arc unit

Event Timeline

This is another approach to the issue pointed out in D40474, mainly using ->pic_flags as flags and allowing a pic_list entry to fill both roles.
Another variant of this strategy would be to add a pair of boolean arguments to intr_pic_register() so the caller would indicate which roles they can fill. This variant could be argued to be better as each layer of the implementation could get its own pic_list entry.

Notes: A bunch of the pic_*() functions in INTRNG declare their flags arguments as int which is wrong. Seems overkill to send that commit through Phabricator (could be handed off with patches/commits for D40474/D43980). I also have a cleanup commit which includes merging all those redundant KASSERT() together. This is silly to test pic_lookup() was implemented correctly in so many places.