On Wed Jul 23, 2025 at 6:18 PM CEST, Daniel Almeida wrote: >> On 23 Jul 2025, at 13:11, Danilo Krummrich <dakr@xxxxxxxxxx> wrote: >> On Wed Jul 23, 2025 at 6:07 PM CEST, Daniel Almeida wrote: >>> On top of that, we can use the >>> words "interior mutability" somewhere in the example as well to make it even >>> clearer. >> >> You *can* have this example and I encourage it, I think it is valuable. You can >> have spinlock or mutex for this purpose in threaded handler, no? > > Right, but then what goes in the hard-irq part for ThreadedHandler? I guess we > can leave that one blank then and only touch the data from the threaded part. > > If that’s the case, then I think it can work too. For instance, yes. It's a very common pattern to only have the threaded handler but not the hard irq handler implemented. IMHO, for ThreadedHandler the hard irq handler should even have a default blank implementation.