On Thu, Sep 21, 2023 at 10:14:09PM +0200, Marek Behún wrote: > On Thu, 21 Sep 2023 21:45:57 +0200 > Marek Behún <kabel@xxxxxxxxxx> wrote: > > > I could use ffs(x) instead of ilog2(x) + 1. > > Pardon me, I meant fls(). Or maybe get_bitmask_order() from > linux/bitops.h. In any case it's bitops.h APIs that you will need and I think it's fine and Linus will approve that. -- With Best Regards, Andy Shevchenko