-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove ->*_handlers fields #1357
Open
ehem
wants to merge
7
commits into
freebsd:main
Choose a base branch
from
ehem:handlers
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
INTRNG will call the enable/disable functions immediately after the first handler is added, or the last is removed. As a result there is no need for setup/teardown functions to handle this task. The teardown functions were doing nothing else. Remove the PCIe teardown function, the GPIO teardown function can be repurposed. The PCIe setup function might still have some value in a debugging kernel.
Create invalid value constants for intr_polarity and GPIO pin/interrupts. These are meant for internal use by drivers.
…nals Using PIC-private variables is superior as it keeps the PIC implementation better separated from INTRNG's internals. In turn this eases changes to INTRNG.
Add macros for future development. Instead of always using `== 0` everywhere, create a macro for testing for existance of handler(s).
We most certainly don't want the shared interrupt system to mask IPI interrupts. As such report them to `dmesg` and indicate they're being handled.
The information is already available on the event, via a different means. Therefore retrieve it from there, rather than duplicating the information. Should be mild space savings, perhaps trivial speed due to cache savings. Should improve in future due to increasing numbers of interrupts on recent systems.
Use of the macro CK_SLIST_EMPTY() on ->is_event->ie_handlers readily substitues for the value ->is_handlers. While only minor shrinkage of struct intsrc, small reductions do accumulate. Update the i8254 hack to work with this setup.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Both INTRNG and x86 have counters for the number of handlers attached to an interrupt. These may have been retrievable somewhere in the past, but now they're only being used as truth values for whether any handler is present. The
CK_SLIST_EMPTY()
can now fully substitute for this functionality, so reduce the space usage of interrupt structures.One minor note, nominally a race could cause two threads to see
startempty
as false. The effect would simply be duplicate enabling of an interrupt which should be harmless.