Skip to content
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

Fixes to1363 problems #1431

Open
wants to merge 6 commits into
base: main
Choose a base branch
from
Open

Fixes to1363 problems #1431

wants to merge 6 commits into from

Conversation

ehem
Copy link
Contributor

@ehem ehem commented Sep 22, 2024

This is kind of urgent as I had been wanting some of this with #1363. Finally spotted the overt assembly to C bridge and that works better for things meant to be shared.

Hopefully got the headers right. Turned out to need LINT-ACPI to find the combination which actually triggered the one condition.

This is kind of urgent-ish.

@ehem ehem mentioned this pull request Sep 22, 2024
@bsdimp
Copy link
Member

bsdimp commented Sep 22, 2024

It's late here and I'm off to bed. I'm on travel tomorrow and may be jet lagged tuesday, and I'll look at it first of the pull requests. We have a lot of time before the branch to refine and I spent time at EuroBSDCon recruiting reviwers. I wanted to let you know quickly my schedule.

@ehem
Copy link
Contributor Author

ehem commented Sep 23, 2024

On review seems the one which had been in the middle really needed to be first. Dunno about others, but there seems a phenomenon the first commit usually needs to be last and the last commit needs to be first.

@ehem
Copy link
Contributor Author

ehem commented Sep 23, 2024

I'm unsure the last one really needs to be part of this. Simply a fragment of where I think things are going, simply illustrating what I was thinking of.

@ehem
Copy link
Contributor Author

ehem commented Nov 4, 2024

While I'm not too hopeful about the latter two right now, I hope the two at the front can go in now.

@ehem ehem force-pushed the fix1363 branch 5 times, most recently from f7717dc to cbb96fc Compare November 7, 2024 20:16
Switch to INTR_ROOT_COUNT as this better matches the purpose of the
value.

Remove the default from the core.  Better to require the architectures
to declare the type since they will routinely deviate and a default
chosen now will likely be suboptimal.
… type to enum""

This partially reverts commit 4b01a7f.

Some extra non-reverting hunks were added to 4b01a7f.  Remove two
of these.
This reverts commit 4f12b52.

Unfortunately having the unusual #include direction serves a high-value
purpose.  The <machine/intr.h> headers almost serve as a standard point
to retrieve architecture interrupt headers.  This is far more valuable.

Leave the move of #include <sys/bus.h> in riscv/trap.c intact.  That is
a reasonable move unrelated to the purpose of this revert.

Move the #include of sys/intr.h earlier in arm/include and
riscv/include.  There was likely a historical reason for this being
towards the end, but there appears no reason now and this matches arm64.
Various files #including INTRNG interrupt headers were inconsistent
in whether they #include'd sys/intr.h or machine/intr.h.  Since there is
a need to work with other architectures, move to #include of
machine/intr.h.  Modify sys/intr.h to #error if machine headers are
included first and future uses match this.

Remove #include of intr.h where possible.

Sort of fixes c85855a.  The breakage was out too long.
Having two distinct names for the interrupt headers serves to interfere
with most efforts to converge the interrupt frameworks.  Simply rename
all of them to "machine/interrupt.h".

Define __MACHINE_INTERRUPT_H__ in i386/include/interrupt.h in order to
be consistent with other platforms.  This is otherwise silly, but
consistency is important.

Remove the #ifdefs in subr_bus.c as a precursor to making c85855a
useful on other platforms.

Do some sorting of #include order.  Notably a bunch involving
resource.h.

Differential Revision: https://reviews.freebsd.org/D35559
For code which doesn't care about the underlying structure and simply
needs to have a common name.

Differential Revision: https://reviews.freebsd.org/D39178
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants