Re: [PATCH v15 1/2] math.h: provide rounddown_ull variant for rounddown MACRO
From: Christian Marangi
Date: Tue Jun 24 2025 - 04:48:19 EST
On Tue, Jun 24, 2025 at 11:44:10AM +0300, Andy Shevchenko wrote:
> On Tue, Jun 24, 2025 at 11:41 AM Andy Shevchenko
> <andriy.shevchenko@xxxxxxxxx> wrote:
> > On Tue, Jun 24, 2025 at 09:45:08AM +0200, Christian Marangi wrote:
> > > On Tue, Jun 24, 2025 at 09:08:32AM +0300, Andy Shevchenko wrote:
> > > > On Tue, Jun 24, 2025 at 12:11 AM Christian Marangi <ansuelsmth@xxxxxxxxx> wrote:
>
> ...
>
> > > > rounddown_ull()
> >
> > Btw, I don't like name for this, it's better to be in math64 with the u64 or similar suffixes like it's used for div/mul variants.
> >
> > Also add a roundup to make the API symmetrical (yes, it's okay that it has no
> > users, it's a macro and doesn't consume memory at run-time).
>
> Ha, there is already roundup_u64() in math64!
>
Ha indeed! I was searching for roundup_64 and I missed the last tiny
function in math64.h. My bad.
--
Ansuel