On Thu, 2025-12-25 at 08:58 +0700, Nam Cao wrote: > Nam Cao <[email protected]> writes: > > There are some helper functions that I am a bit uncomfortable with > > (e.g. pi_of, is_dl_boosted, dl_is_implicit, ...) because they are > > relying on implementation details of deadline scheduler which can be > > changed. So ideally this patch should have an Ack from the scheduler people.
Thanks for the review! I'm going to ping scheduler guys some time after the holidays. > Think about this again, perhaps we should move all these helpers to > include/linux/sched/deadline.h instead? The scheduler people must be > aware of these functions, and maintain them. I don't want a situation > where the scheduler people make changes, and something else (which they > do not know exist) breaks. That's a fair point, I just copied those functions from kernel/sched/deadline.c but that's dirty indeed. Going to try exporting them to deadline.h and see if no one complains. > Ideally, non-scheduler code should not look at private fields of > scheduler's structs. Yeah, one may argue those modules shouldn't be doing what they're doing with the deadline entities. To be fair those modules are quite dependant on the data structure implementation, but the alternative would be to maintain a set of getter functions which might as well break. Or at least I don't see a better way. Thanks, Gabriele
