Page MenuHomeFreeBSD

ehem_freebsd_m5p.com (Elliott Mitchell)
User

Projects

User does not belong to any projects.

User Details

User Since
Feb 20 2021, 4:27 AM (158 w, 20 h)

Recent Activity

Fri, Feb 23

ehem_freebsd_m5p.com updated the diff for D35386: intr/x86: replace use of vector in interface with intsrc.

Update to better reflect current state of FreeBSD tree. My repository had several patches, one of which had modified intr_describe(). As such this better reflects current state.

Fri, Feb 23, 6:06 PM

Tue, Feb 20

ehem_freebsd_m5p.com added inline comments to D40166: intrng: allocate event during isrc setup.
Tue, Feb 20, 8:45 PM
ehem_freebsd_m5p.com updated the diff for D40166: intrng: allocate event during isrc setup.

Splitting D40166 back up. While I like the second part, it is lower value. This would serve to make all architectures noticably more similar.

Tue, Feb 20, 8:37 PM
ehem_freebsd_m5p.com updated the diff for D35406: intr/x86: remove ->pic_vector() from x86 interrupt framework.

Change the approach and use ->is_event->ie_irq for places besides intr_register_source(). Since D35386 is now a parent, the vector value can disappear from xen_arch_isrc_t. msi_irq can also disappear, but that is more involved.

Tue, Feb 20, 8:25 PM
ehem_freebsd_m5p.com updated the diff for D35386: intr/x86: replace use of vector in interface with intsrc.

Due to D36901 getting in first, intr_bind() disappeared. As threatened, I really like intr_add_handler()'s first two arguments being in the opposite order. Not only does this seem more consistent with the rest of the interface, but this also matches INTRNG (the domain argument is now the only difference).

Tue, Feb 20, 8:14 PM

Mon, Feb 19

ehem_freebsd_m5p.com added reviewers for D43980: intrng: merge separated PIC types: jrtc27, mmel.

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.

Mon, Feb 19, 8:13 PM
ehem_freebsd_m5p.com requested review of D43980: intrng: merge separated PIC types.
Mon, Feb 19, 7:58 PM
ehem_freebsd_m5p.com added a comment to D43928: x86/xen: fix out of bounds access to the event channel masks on resume.

Depending on where xen_intr_disable_source() and xen_intr_disable_intr() were being called from, this is fixing both 1797ff962769 and some other commit. Certainly 1797ff962769 may have exposed this, but the is_valid_evtchn() call was needed earlier (could be rG76acc41fb7c7, or even before).

Mon, Feb 19, 7:56 PM

Thu, Feb 15

ehem_freebsd_m5p.com added a comment to D40474: intrng: call pic_init_secondary on all registered PICs.

I'm really struggling to understand what the source of confusion here is.

Thu, Feb 15, 11:48 PM
ehem_freebsd_m5p.com added a comment to D40474: intrng: call pic_init_secondary on all registered PICs.

@jrtc27 not being on intimate terms with the GICv3 implementation and lacking hardware to confirm how things work, I've got no idea what to do. What I do know is the extra PIC for this device never gets into sc->gic_children and therefore the loop in gic_v3_init_secondary() doesn't work for this device.

Thu, Feb 15, 10:30 PM

Tue, Feb 6

ehem_freebsd_m5p.com added a comment to D40474: intrng: call pic_init_secondary on all registered PICs.

@jrtc27 I was hoping for an answer to my question before doing anything.

Tue, Feb 6, 8:06 PM
ehem_freebsd_m5p.com updated the diff for D40474: intrng: call pic_init_secondary on all registered PICs.

Uploading the obvious SLIST->STAILQ adjustment.

Tue, Feb 6, 8:03 PM
ehem_freebsd_m5p.com added a comment to D43764: x86/xen: implement early init hook.

Guess I had it easy as I had a system running Linux and arcanist was available as a package.

Tue, Feb 6, 7:54 PM · x86

Jan 23 2024

ehem_freebsd_m5p.com added a comment to D40474: intrng: call pic_init_secondary on all registered PICs.

You want if (dev != intr_irq_root_dev) return; added to every preexisting pic_init_secondary() implementation? Luckily this is simple as there are very few implementation (bcm2836 is the only one which wasn't mentioned).

That's neither necessary nor sufficient, so no.

Jan 23 2024, 9:11 PM
ehem_freebsd_m5p.com added a comment to D40474: intrng: call pic_init_secondary on all registered PICs.

Whilst this looks like the right thing to do for the core framework, I believe our GICv2 driver won't like this in some edge cases, as for the FDT case it supports being a non-root PIC yet has an arm_gic_init_secondary which currently only runs for the root PIC, probably by design?

Jan 23 2024, 2:12 AM

Dec 9 2023

ehem_freebsd_m5p.com updated subscribers of D42797: LinuxKPI: Add xen/xen.h header.
Dec 9 2023, 11:08 PM
ehem_freebsd_m5p.com added a comment to D31261: Add arm64 pointer authentication support.

If in the "Accepted" state (someone selects "Accept Revision") the option "Close Revision" appears underneath "Revision Actions". I'm unsure whether there are other ways to get that to appear. Isn't available here since no reviewer ever marked it as such.

Dec 9 2023, 9:36 PM
ehem_freebsd_m5p.com added a comment to D37688: kern/intr: remove support for passing trap frame as argument.

The only remaining usage of this is sys/arm/arm/pmu.c. If that can get removed then it become possible to use NULL as a handler argument. I can turn that removal into a review/differential if someone desires, but seems trivial enough to simply commit if someone has a chance.

Dec 9 2023, 9:27 PM

Nov 7 2023

ehem_freebsd_m5p.com added a comment to D42343: xen: improve shutdown hook.

My opinion is that halt should behave equally on bare metal than when virtualized, otherwise it's just going to confuse users. If we believe that halt should behave differently (iow: do power off) it should be changed uniformly.

Nov 7 2023, 1:58 AM

Nov 5 2023

ehem_freebsd_m5p.com abandoned D35418: intrng: convert to using resource manager for interrupt numbers.

I think I've found a better way to address this. Alas tis a bunch of commits and the throughput for non-sponsored patches is atrocious.

Nov 5 2023, 4:20 PM
ehem_freebsd_m5p.com added a comment to D42343: xen: improve shutdown hook.

I mostly concur with D42343, I've noticed the behavior and found it suboptimal. Only trick is after a fair bit of time not looking at this I found a small issue which needs to be addressed.

Nov 5 2023, 4:15 PM

Oct 23 2023

ehem_freebsd_m5p.com abandoned D32632: intrng: allow specifying an interrupt number during allocation.

Marking D32632 as abandoned. I've got something which approaches the same goal, but is distinct enough to not take over D32632.

Oct 23 2023, 8:50 PM
ehem_freebsd_m5p.com updated the summary of D32504: kern/intr: remove "irq" from kernel event API.
Oct 23 2023, 8:22 PM

Oct 10 2023

ehem_freebsd_m5p.com updated the diff for D38599: intrng: destroy event when deregistering source.

Hmm, lost the mention of isrc_event_destroy(). I suppose if one wants to have that function, things could look like this instead.

Oct 10 2023, 4:37 PM
ehem_freebsd_m5p.com added a comment to D35386: intr/x86: replace use of vector in interface with intsrc.

Due to D36901 getting in first, intr_bind() has disappeared and the portion of D35386 adjusting the interface disappears.

Oct 10 2023, 4:30 PM

Sep 9 2023

ehem_freebsd_m5p.com added a comment to D32504: kern/intr: remove "irq" from kernel event API.

When it comes down to it, since I'm more concerned with getting rid of sys/kern/kern_intr.c:intr_lookup() it is acceptable to continue having intr_{get|set}affinity() using numeric interrupt numbers. This will require sys/kern/kern_intr.c to #include the architecture interrupt headers. I was reluctant to propose that due to how distinct they are, but this doesn't actually contradict my goals and is nominally acceptable to me.

Sep 9 2023, 1:29 AM
ehem_freebsd_m5p.com updated the summary of D32504: kern/intr: remove "irq" from kernel event API.
Sep 9 2023, 1:18 AM

Sep 5 2023

ehem_freebsd_m5p.com updated the diff for D39178: Working on commonizing standard interrupt functionality.

Tiny adjustment, split the NULL-check to a separate step. Just in case a use does the NULL-check itself and simply wants the appropriate field name. Hopefully common-subexpression elimination would take care of this, but it might not.

Sep 5 2023, 10:37 PM

Sep 2 2023

ehem_freebsd_m5p.com added a comment to D38599: intrng: destroy event when deregistering source.

All of these should be obvious from what INTRNG does. Failing that, an example was provided. So, a few call sequences:

Sep 2 2023, 2:23 AM

Sep 1 2023

ehem_freebsd_m5p.com added a comment to D40474: intrng: call pic_init_secondary on all registered PICs.

I'm unsure whether the call to child devices during gic_v3_init_secondary() should be removed. The only user of this is the GIVv3 ITS (550d01a2117f). Will most child devices need this called after the parent PIC is fully initialized? Do child devices merely need this called during processor bring-up?

Sep 1 2023, 1:42 AM

Aug 24 2023

ehem_freebsd_m5p.com added reviewers for D39333: intrng: expose lower-level device interface for INTRNG: Core Team, mw.

Looks like sys/arm/mv/gpio.c has a situation similar to what I'm looking at. The approach of doing local calls to intr_event_create() has been tested and functions, but this seemed unlikely to be accepted by a reviewer. Yet this makes me the second person to run into troubles with INTRNG due to assumptions in its interface.

Aug 24 2023, 3:59 AM
ehem_freebsd_m5p.com added a comment to D36610: kern/intr: implement intrcnt/intrnames sysctl from event counters.

This wasn't my goal, but it looks like this series, D38451 in particular fixes the intr_isrc_dispatch() call in sys/arm/mv/gpio.c. Since the counters get moved to the event, it ends up with functioning counters, plus no uninitialized counters get incremented (the function mv_gpio_intr_handler()).

Aug 24 2023, 3:55 AM
ehem_freebsd_m5p.com added a reviewer for D38451: intrng: remove normal interrupts from intrcnt/intrnames: mw.

This appears to partially fix the intr_isrc_dispatch() call in sys/arm/mv/gpio.c, since it removes the increment of the counters which have never been initialized.

Aug 24 2023, 3:52 AM
ehem_freebsd_m5p.com added a comment to D33479: kern_intr: Check for NULL event in intr_destroy().

Alas this came to my attention way to late to address on-time. Callers of intr_event_destroy() want to know whether everything has been appropriately released or not. If the event is NULL this likely something failed very early during setup. In such case the event doesn't need to be released since it was never allocated. As such 0 should be the return instead.

Aug 24 2023, 3:49 AM
ehem_freebsd_m5p.com abandoned D33818: Add __smpused.
In D33818#771982, @kib wrote:

So provide the patch that fixes that 'many' places.

Aug 24 2023, 3:36 AM

Aug 23 2023

ehem_freebsd_m5p.com updated the diff for D40166: intrng: allocate event during isrc setup.

Squash review, adding removal of ->isrc_irq. This is one reason why allocating the event earlier has value, ->ie_irq can then substitute everywhere. If reviewers want this split back off, that can be done.

Aug 23 2023, 10:55 PM
ehem_freebsd_m5p.com updated the diff for D35607: intrng: purge INTR_SOLO.

Hmm, no that isn't really so elegant so keep to the smaller diff.

Aug 23 2023, 9:58 PM
ehem_freebsd_m5p.com updated the diff for D35607: intrng: purge INTR_SOLO.

Hmm, spotted this a while ago, but didn't get Phabricator updated. The test in isrc_event_create() was wrong, this appears to be the correct action.

Aug 23 2023, 9:31 PM
ehem_freebsd_m5p.com added a comment to D35406: intr/x86: remove ->pic_vector() from x86 interrupt framework.

Having examined things more, an appropriate place to store the value already exists, but has been underutilized. Mainly isrc->is_event->ie_irq.

Aug 23 2023, 4:42 AM

Aug 22 2023

ehem_freebsd_m5p.com added a comment to D32504: kern/intr: remove "irq" from kernel event API.

D40166 heads in the opposite direction with regards to the interrupt number. Instead of removing it from intr_event and pushing it back to the architectures, D40166 allows removing it from the architecture and only having it on intr_event.

Aug 22 2023, 7:41 PM
ehem_freebsd_m5p.com updated the diff for D40166: intrng: allocate event during isrc setup.

Move the setting line to isrc_alloc_irq(). This would allow keeping the interrupt number strictly on the event and removing it from intr_irqsrc.

Aug 22 2023, 7:32 PM
ehem_freebsd_m5p.com added a reviewer for D40166: intrng: allocate event during isrc setup: mw.
Aug 22 2023, 1:54 AM
ehem_freebsd_m5p.com added a comment to D40166: intrng: allocate event during isrc setup.

One extra may be needed for this. The file sys/arm/mv/gpio.c has a call to intr_event_create(). Unfortunately this isn't setup for INTRNG allocating events early. Interestingly it seems ad2be10ff043 is exactly the same issue I'm running into.

Aug 22 2023, 1:50 AM
ehem_freebsd_m5p.com added a comment to D32504: kern/intr: remove "irq" from kernel event API.

I'm not sure what the point of this is. To simplify use cases like hotplug by giving intr API consumers a way to call intr_foo() functions without keeping track of the vector?

Aug 22 2023, 1:38 AM
ehem_freebsd_m5p.com retitled D40166: intrng: allocate event during isrc setup from intrng: add flag requesting early event allocation to intrng: allocate event during isrc setup.
Aug 22 2023, 1:16 AM
ehem_freebsd_m5p.com updated the diff for D40166: intrng: allocate event during isrc setup.

I've been concerned over whether the initial version of D40166 would pass. The use case was too specialized. As such an update, remove the lazy interrupt allocation.

Aug 22 2023, 1:15 AM

Aug 18 2023

ehem_freebsd_m5p.com added a comment to D38599: intrng: destroy event when deregistering source.

Absent some examples grounded in a specific driver to motivate the discussion, my view is that it's better not to bother thinking about this at all. If intr_event_destroy() returns EBUSY in a particular scenario, then the caller should be fixed.

Aug 18 2023, 12:58 AM
ehem_freebsd_m5p.com added a comment to D38602: kern/intr: have intr_event_destroy() return success on NULL event.

A handy example is D38599. It could test isrc->isrc_event before calling intr_event_destroy(), but if intr_event_destroy() will gracefully handle ie == NULL then it is easier not to bother. If you prefer to have a panic() sooner rather than later, the

if (ie == NULL)
        return (EINVAL);

should be taken out and hopefully a panic() will ensue on line 539. If intr_event_destroy() is going to check for ie == NULL then it should do something useful if that occurs. Returning EINVAL is almost certain not to be useful and thus returning 0 seems more sensible.

Aug 18 2023, 12:55 AM
ehem_freebsd_m5p.com updated the diff for D41462: intrng: switch from MAXCPU to mp_ncpus.

Errf, then find the goof after push.

Aug 18 2023, 12:27 AM
ehem_freebsd_m5p.com updated the diff for D41462: intrng: switch from MAXCPU to mp_ncpus.

Update to get things right. Though this is almost a fix on commit situation.

Aug 18 2023, 12:20 AM

Aug 16 2023

ehem_freebsd_m5p.com updated the diff for D41462: intrng: switch from MAXCPU to mp_ncpus.

Update as per comments.

Aug 16 2023, 10:31 PM

Aug 15 2023

ehem_freebsd_m5p.com added a comment to D41462: intrng: switch from MAXCPU to mp_ncpus.

I believe CPU IDs are not guaranteed to be contiguous and mp_maxid is what should be used instead

Aug 15 2023, 3:55 AM
ehem_freebsd_m5p.com added a comment to D41462: intrng: switch from MAXCPU to mp_ncpus.

In light of D41319 and the issues of what was observed when similar was done there. Presently this is untested, but I'm reasonably sure this is correct.

Aug 15 2023, 3:46 AM
ehem_freebsd_m5p.com requested review of D41462: intrng: switch from MAXCPU to mp_ncpus.
Aug 15 2023, 3:41 AM
ehem_freebsd_m5p.com added a comment to D38448: kern/intr: add flags for multi-processor interrupts.

I hadn't realized there was an actual sys/arm/arm/generic_timer.c which appears to be used for ARM64. As such I've identified 3 places on ARM where a single intr_event structure is used for interrupts which occur on multiple processors. I now fear this could be all over ARM and this may already have been endorsed by fiat.

Aug 15 2023, 3:01 AM

Aug 14 2023

ehem_freebsd_m5p.com added a comment to D41447: x86: restore intr_bind.

I'm unsure whether it works well as part of any existing differential, but it was suggested there should be a cpu_t type definition. That didn't fit as part of D36901, but does seem worthwhile. That would likely address the breakage which was found.

Aug 14 2023, 5:49 PM
ehem_freebsd_m5p.com added a comment to D38602: kern/intr: have intr_event_destroy() return success on NULL event.

"My kingdom for a review"?

Aug 14 2023, 4:20 PM
ehem_freebsd_m5p.com added a comment to D41439: netfront: fix the support for disabling LRO at boot time.

This looks plausible. Likely it mostly amounts to a debugging tool since you would basically never want this in anything approximating a real world situation.

Aug 14 2023, 4:12 PM

Aug 11 2023

ehem_freebsd_m5p.com added a comment to D32504: kern/intr: remove "irq" from kernel event API.

When it comes down to it, 9b33b154b53 was pretty much a simple hack to allow architectures without a proper interrupt table implementation to do simple interrupt number lookup. Thing is, MIPS was the last architecture lacking such a table, therefore this is now fully redundant with architecture functionality. As such this is effectively cleaning out yet another MIPS remainder.

Aug 11 2023, 8:34 PM
ehem_freebsd_m5p.com added a comment to D41430: kern/intr: add interrupt counters to intr_isrc.

Unfortunately see D38448 for most comments so far.

Aug 11 2023, 8:29 PM
ehem_freebsd_m5p.com added inline comments to D38448: kern/intr: add flags for multi-processor interrupts.
Aug 11 2023, 8:23 PM
ehem_freebsd_m5p.com retitled D38448: kern/intr: add flags for multi-processor interrupts from kern/intr: add interrupt counters to intr_isrc to kern/intr: add flags for multi-processor interrupts.
Aug 11 2023, 8:15 PM
ehem_freebsd_m5p.com updated the diff for D38448: kern/intr: add flags for multi-processor interrupts.

Updating D38448 to split off the counter addition. At this point I'm under the suspicion the core team needs to consider this, and say "yay" or "nay". Whether interrupts which occur on multiple processors should share an intr_event structure is a real question. So far several places appear to be saying "yes", but I would like a core team review.

Aug 11 2023, 8:04 PM
ehem_freebsd_m5p.com added a comment to D41430: kern/intr: add interrupt counters to intr_isrc.

This is splitting the counter add commit off the flag add commit. Originally these seemed like a single task, but seems further consideration is needed for the flags.

Aug 11 2023, 7:52 PM
ehem_freebsd_m5p.com requested review of D41430: kern/intr: add interrupt counters to intr_isrc.
Aug 11 2023, 7:50 PM

Aug 9 2023

ehem_freebsd_m5p.com added a reviewer for D40474: intrng: call pic_init_secondary on all registered PICs: andrew.

Uhm, this would be kind of useful to have. Any chance this can get a review?

Aug 9 2023, 8:17 PM
ehem_freebsd_m5p.com added a comment to D41354: ath(4): Remove MIPS AHB frontend and join PCI one w/ main support again.

Missed it when looking for a fix in recent history. Most recent build succeeded, so looks like this was the fix.

Aug 9 2023, 6:57 PM
ehem_freebsd_m5p.com added a comment to D41354: ath(4): Remove MIPS AHB frontend and join PCI one w/ main support again.

Latest build attempt failed. This is my current suspect.

Aug 9 2023, 4:21 PM

Aug 8 2023

ehem_freebsd_m5p.com added a comment to D41320: tests: Add stack grows tests.

Rebuild with 8920c5f2a11 reverted succeeded. Looks like D41320. The host is FreeBSD 13.2p2 with minimal extras.

Aug 8 2023, 9:37 PM
ehem_freebsd_m5p.com added a comment to D38448: kern/intr: add flags for multi-processor interrupts.

I'm starting to think the flag addition to he lower layers should be broken into a separate review. Issue is that has some effects all over the place.

Aug 8 2023, 8:25 PM
ehem_freebsd_m5p.com added a comment to D41320: tests: Add stack grows tests.

At the end of a full build which just terminated:

ld: error: unable to find library -lsoxstack
clang: error: linker command failed with exit code 1 (use -v to see invocation)
--- stack_dt_need_exec_test.full ---
*** [stack_dt_need_exec_test.full] Error code 1

Looks like this broke the build.

Aug 8 2023, 8:12 PM
ehem_freebsd_m5p.com updated the diff for D38448: kern/intr: add flags for multi-processor interrupts.

Updating to re-add a commit which got dropped.

Aug 8 2023, 7:44 PM
ehem_freebsd_m5p.com updated the diff for D38448: kern/intr: add flags for multi-processor interrupts.

Updating, spreading the proposed flag further. Still need an answer for whether multi-processor interrupts should share an intr_event structure though.

Aug 8 2023, 2:25 AM

Aug 5 2023

ehem_freebsd_m5p.com updated the diff for D38448: kern/intr: add flags for multi-processor interrupts.

Appears INTRNG isn't the only thing tending to push multi-processor interrupts onto single intr_event structures. At D25754 a multi-processor soft interrupt was created. As such it would need to share this.

Aug 5 2023, 6:22 AM

Jul 11 2023

ehem_freebsd_m5p.com added reviewers for D37688: kern/intr: remove support for passing trap frame as argument: jhb, jhibbits, kib, jrtc27.

Alerting everyone this is on the horizon. A check 3 weeks ago showed there are 3 remaining places where this is utilized. I've got patches out trying to get them nuked while bypassing Phabricator (they're trivial), but am presently waiting on news. Those are in the files sys/arm/arm/pmu.c and sys/x86/xen/xen_apic.c.

Jul 11 2023, 1:07 AM

Jun 29 2023

ehem_freebsd_m5p.com added a comment to D35976: sys: rename linker scripts to .lds.

We seem to use ldscript as either an extension or base for the filename, e.g. sys/conf/ldscript.arm64 or lib/libc/libc.ldscript.

Jun 29 2023, 8:48 PM

Jun 28 2023

ehem_freebsd_m5p.com updated the diff for D30996: xen/arm64: add aarch64 hypercall interface.

Huh, I was so focused on interactions with @royger I missed that I've done rather substantial changes to what was D30996.

Jun 28 2023, 9:58 PM

Jun 27 2023

ehem_freebsd_m5p.com added a comment to D40776: kern: remove clk_intr_event from non-ACPI.

Unfortunately there are several overlapping issues interwoven here and choices need to be made.

Jun 27 2023, 7:23 PM
ehem_freebsd_m5p.com requested review of D40776: kern: remove clk_intr_event from non-ACPI.
Jun 27 2023, 6:53 PM

Jun 24 2023

ehem_freebsd_m5p.com added a comment to D35898: intrng: Extract arm/arm64 IPI->PIC glue code.

Note on this. Should this perhaps be a separate file in sys/kern instead of mixed in with INTRNG/subr_intr.c?

Jun 24 2023, 12:05 AM

Jun 23 2023

ehem_freebsd_m5p.com added a comment to D38599: intrng: destroy event when deregistering source.

With no activity, hopefully doing an update will provoke activity.

Most of the kernel appears to treat NULL as unallocated and not an error.

Are you referring to functions like free()? It depends. free() is called very frequently in error handling paths, so having free(NULL) be a no-op is a convenience. Most rarely used allocators do not have such an affordance. uma_zdestroy(NULL) is a bug, as is kmem_free(NULL). I think this is the right tradeoff, since the permissive behaviour can hide bugs, and calls to free() or m_free() are a lot more common than uma_zdestroy() or kmem_free().

Jun 23 2023, 8:47 PM

Jun 17 2023

ehem_freebsd_m5p.com updated the diff for D38599: intrng: destroy event when deregistering source.

With no activity, hopefully doing an update will provoke activity.

Jun 17 2023, 12:14 AM

Jun 15 2023

ehem_freebsd_m5p.com updated the diff for D40474: intrng: call pic_init_secondary on all registered PICs.

Pulling the intr_irq_root_dev == NULL check. There are similar checks elsewhere and that won't directly effect this spot.

Jun 15 2023, 9:12 PM

Jun 14 2023

ehem_freebsd_m5p.com added a comment to D40474: intrng: call pic_init_secondary on all registered PICs.

In case anyone is wondering, to answer the comment "QQQ: Only root PIC is aware of other CPUs ???". That is indeed the way this was implemented. The more important issue is are PICs besides the root PIC interested in being informed when processors are brought on-line.

Jun 14 2023, 4:41 AM
ehem_freebsd_m5p.com planned changes to D35406: intr/x86: remove ->pic_vector() from x86 interrupt framework.

Having considered things in various places I'm no longer so sure of this being a good idea. There is merit, but due to a certain case I could see this being reused for major gain. As such marking this as on hold.

Jun 14 2023, 4:28 AM

Jun 9 2023

ehem_freebsd_m5p.com updated the diff for D40474: intrng: call pic_init_secondary on all registered PICs.

Check the build and naturally find oversights from the quick implementation. Tiny fix. One item is whether the pic_list_lock should in fact be held...

Jun 9 2023, 6:32 AM
ehem_freebsd_m5p.com requested review of D40475: arm/mpic: remove empty pic_init_secondary() hook.
Jun 9 2023, 5:45 AM
ehem_freebsd_m5p.com requested review of D40474: intrng: call pic_init_secondary on all registered PICs.
Jun 9 2023, 5:44 AM

May 22 2023

ehem_freebsd_m5p.com added a comment to D40211: intrng: adjust IPI interrupts to match driver_filter_t.

Theory is to start making IPI interrupts look more like normal device interrupts. Combined with D35898 could make sense to have PPI interrupts merged with IPI interrupts instead of device interrupts.

May 22 2023, 5:38 PM
ehem_freebsd_m5p.com requested review of D40211: intrng: adjust IPI interrupts to match driver_filter_t.
May 22 2023, 5:34 PM
ehem_freebsd_m5p.com added a comment to D38448: kern/intr: add flags for multi-processor interrupts.
In D38448#886009, @mjg wrote:

All this is with the assumption that it makes sense to share one intr_event struct between different cpus.

all that said, I would have to dig into what the code is doing and what makes sense to do, which I can't at the moment due to already big backlog.

May 22 2023, 5:33 PM
ehem_freebsd_m5p.com added a comment to D40166: intrng: allocate event during isrc setup.

Appears intr_isrc_register()/intr_isrc_deregister() would need to be after isrc_event_create(). I'm unsure whether to move the former down versus the latter up. Right now I'm mostly interested in whether this seems reasonable.

May 22 2023, 5:24 PM

May 19 2023

ehem_freebsd_m5p.com added reviewers for D38602: kern/intr: have intr_event_destroy() return success on NULL event: jhb, kib.

Trying for other reviewers since this has already been sitting around for months with no action.

May 19 2023, 8:42 PM
ehem_freebsd_m5p.com added reviewers for D40166: intrng: allocate event during isrc setup: markj, imp.

Seems pretty reasonable to do lazy allocation of struct intr_event, but there are circumstances where it could be a disadvantage. The other likely allocation time is during the setup step, so using a flag seems appropriate. The question which comes to mind is, which flag value should be used? Should this use a high flag number since this could be discarded after the setup step? Be strictly sequential?

May 19 2023, 8:39 PM
ehem_freebsd_m5p.com requested review of D40166: intrng: allocate event during isrc setup.
May 19 2023, 8:13 PM

May 11 2023

ehem_freebsd_m5p.com added a comment to D32504: kern/intr: remove "irq" from kernel event API.

Can you rebase this patch?

And there are some compile issues (AMD64):

May 11 2023, 8:39 PM
ehem_freebsd_m5p.com added a comment to D39178: Working on commonizing standard interrupt functionality.

One concern I've got. What is the range of supported compilers? I believe some older compilers won't accept typedef struct foo type_t; as an incomplete declaration of struct foo. Those would need separate incomplete declarations, but I'm unsure whether those are included in the support window for this.

May 11 2023, 8:39 PM

May 10 2023

ehem_freebsd_m5p.com added a comment to D32504: kern/intr: remove "irq" from kernel event API.

I'm really impressed at just how slow reviews for things meant to be simple are.

May 10 2023, 1:18 AM
ehem_freebsd_m5p.com added a comment to D39333: intrng: expose lower-level device interface for INTRNG.

I am in fact taking inspiration from x86 since the general idea was to fully split the layers apart (move the outermost functions to perhaps sys/kern/subr_nexus.c). Then it might also match x86's needs and push architectures closer together. In particular, D35559 plus D39178 greatly help with merging.

May 10 2023, 1:09 AM

May 6 2023

ehem_freebsd_m5p.com requested review of D39991: RELNOTES: fix consistency.
May 6 2023, 8:56 PM