User Details
- User Since
- Jun 4 2014, 6:42 AM (590 w, 4 d)
Thu, Sep 25
Mon, Sep 15
I never really worked with code in this area, but the change looks good to me.
Wed, Sep 10
Aug 26 2025
Aug 21 2025
Maybe we can even retire printm...
I never knew it existed.
Aug 9 2025
Aug 6 2025
Aug 5 2025
Jul 26 2025
Jul 25 2025
Jul 24 2025
Jul 19 2025
LGTM
Jul 7 2025
@zldrobit_gmail.com if you cannot submit the change for review from Git (e.g., using git-arc), can you update it with a diff created with -U999 option?
Jul 4 2025
Jul 3 2025
Jul 2 2025
Jun 27 2025
Jun 23 2025
Jun 20 2025
Here is an example of how I made use of this code in iichid when it still was out-of-tree:
https://github.com/avg-I/iichid/commit/d5c33b243c599fd234685a2cd8ee1bd1fb67e1b0
May 20 2025
May 19 2025
May 14 2025
Thank you very much!
I pointed out this problem to Kirk and Colin back when the change was made.
I had to do the same kind of fix locally (for Panzura) because of live-locks as well.
But I have one small difference, not sure if important, which I'll describe in an inline comment.
Apr 18 2025
Thank you!
Mar 7 2025
Looks good to me.
Feb 21 2025
Feb 7 2025
Still looks good to me.
Feb 6 2025
Feb 5 2025
The change looks good to me.
Thank you.
Jan 14 2025
I think that vmxnet3_isc_txd_credits_update can be made similar to, e.g., igb_isc_txd_credits_update with respect to the array index (tx_rs_cidx and vxcr_next respectively).
That is, we can stash vxcr_next into a local variable and then use the local variable for iteration.
At the end, we can update vxcr_next from the local variable.
This won't fix other potential issues with correctness / concurrency (data races), but at least it will ensure that vxcr_next will not have an out-of-bounds value.
Jan 10 2025
@jhb my personal / private interest in sleepable ithreads is "natural" support for interrupt controllers on slow buses.
Originally, it was assumed that an interrupt controller has fast access and they had.
But imagine something like an I/O expander on an I2C bus.
Let's assume that it supports detecting changes on its I/O inputs and also has a dedicated line to an upstream interrupt controller.
We can configure interrupt modes using I2C transactions and we can also query / mask / etc interrupt lines using I2C.
This is a real interrupt controller from all points of view and if we want to avoid polling (for potentially long time) we need to support sleeping / waiting while communicating with such controller.
At least, that's how I see it.
Jan 2 2025
Nov 27 2024
Looks goof to me.
Thank you!
Also, cv_wmesg is kind of semi-private and it's used only for diagnostics (tracing).
So, I don't think that it's precedent for general access to cv implementation details.
As I noted in the email thread, there is only one consumer outside of condvar implementation.
Nov 15 2024
Nov 14 2024
If you have added this from a diff, could you please re-do the diff with -U 9999 option?
That's to have a lot more context lines which would be useful when reviewing.
Nov 1 2024
Oct 12 2024
Oct 5 2024
Sep 25 2024
Oh, thinking about this triggered some old memories and I've dug up my old musings on this topic.
The code was never really tested and I cannot guarantee that it's correct, but it seemed correct to the younger me and it still seems correct the now me.
https://people.freebsd.org/~avg/wfhandler.v8.h
Another general suggestion is that using CK_SLIST from ConcurrencyKit (included into FreeBSD) might help to make the code more compact and expressive.
But I haven't thought through details, so please feel free to ignore this suggestion if CK does not provide something that could be readily used.
The proposed code is completely good too.
I am not sure that such a OS/ACPI (firmware) mutex is possible.
Sep 19 2024
My only concern with the current deregistration approach is a hypothetical situation where a handler resides in a loadable module and, thus, can be unloaded after deregistration.
I like the clever simplicity of the current code where list elements are never removed and only the head pointer can ever be modified.
But maybe it would be good for nmi_remove_handler to wait for a completion of the handler if it's running.
E.g., we could add an atomic counter to struct nmi_handler which would be incremented when the handler is started and decremented when the handler is done.
Then, nmi_remove_handler could spin-wait on that counter if it's not zero (after having cleared func field to prevent future calls).
Sep 15 2024
LGTM
I like how using t_dtrace_trapframe both eliminates the search for the frame below the trap frame and the assumption on the position of the trap frame.