Re: [RFC] include/linux/make_type.h: Helpers for making u16/u32/u64 values

From: Alexey Dobriyan
Date: Fri Feb 16 2024 - 01:24:01 EST


On Wed, Feb 14, 2024 at 06:55:38PM +0100, Michal Wajdeczko wrote:
>
>
> On 14.02.2024 18:39, Alexey Dobriyan wrote:
> > On Wed, Feb 14, 2024 at 07:32:10PM +0200, Andy Shevchenko wrote:
> >> On Wed, Feb 14, 2024 at 08:20:55PM +0300, Alexey Dobriyan wrote:
>
> ...
>
> >
> > Thirdly, there were no users posted.
>
> for make_u64() there is already one at [1]
> [1]
> https://elixir.bootlin.com/linux/v6.8-rc4/source/drivers/gpu/drm/xe/xe_gt_pagefault.c#L555

OK, this one doesn't truncate too.

Honestly wordpath.h _sucks_ as a name.

I'd go with stdint.h, at least this name is known from userspace.