[PATCH v5 1/4] uapi: Provide DIV_ROUND_CLOSEST()
AngeloGioacchino Del Regno
angelogioacchino.delregno at collabora.com
Tue Jan 27 04:35:27 PST 2026
Il 27/01/26 09:45, Cristian Ciocaltea ha scritto:
> Currently DIV_ROUND_CLOSEST() is only available for the kernel via
> include/linux/math.h.
>
> Expose it to userland as well by adding __KERNEL_DIV_ROUND_CLOSEST() as
> a common definition in uapi.
>
> Additionally, ensure it allows building ISO C applications by switching
> from the 'typeof' GNU extension to the ISO-friendly __typeof__.
>
> Reviewed-by: Nícolas F. R. A. Prado <nfraprado at collabora.com>
> Tested-by: Diederik de Haas <diederik at cknow-tech.com>
> Signed-off-by: Cristian Ciocaltea <cristian.ciocaltea at collabora.com>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno at collabora.com>
More information about the linux-arm-kernel
mailing list