Re: [PATCH RFC 4/9] io-uring/rw: Use accessor for hrtimer_sleeper ->task field
Jens Axboe <[email protected]> Fri, 31 Jul 2026 09:03:29 -0600
| Newsgroups | org.kernel.vger.io-uring,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <[email protected]> |
On 7/30/26 6:40 PM, Paul E. McKenney wrote: > The hrtimer_sleeper structure's ->task field is used as a flag to indicate > that the associated hrtimer has expired. This means that the hrtimer > handler can be storing to this field while other code is loading from it > to check for expiry. Note that additional races appear for hrtimers that > can be restarted, which could be argued to be a user error. However, that > is no reason to let the compiler introduce additional confusion, and to > this end, the hrtimer_sleeper_task_get() was introduced, use of which also > has the benefit of avoiding open-code access to hrtimer_sleeper innards. > > Therefore, apply this accessor to the io_hybrid_iopoll_delay() function. Seems fine to me, but for some reason you didn't CC all the people on the series. Hence I don't know if each can stand on its own. A quick grep tells me that, no, that is not the case, as hrtimer_sleeper_task_get() isn't a thing in the tree right now. That's a slight nudge to please don't do partial CCs, it's impossible to tell without needing to dig further. -- Jens Axboe