[PATCH 01/18] ALSA: core: Use DIV_ROUND_UP() instead of open-coding it

Takashi Iwai tiwai at suse.de
Fri Dec 25 09:16:51 CET 2020


On Wed, 23 Dec 2020 18:22:12 +0100,
Lars-Peter Clausen wrote:
> 
> Use DIV_ROUND_UP() instead of open-coding it. This documents intent
> and makes it more clear what is going on for the casual reviewer.
> 
> Generated using the following the Coccinelle semantic patch.
> 
> // <smpl>
> @@
> expression x, y;
> @@
> -(((x) + (y) - 1) / (y))
> +DIV_ROUND_UP(x, y)
> // </smpl>
> 
> Signed-off-by: Lars-Peter Clausen <lars at metafoo.de>

Thanks, applied now for 5.12 with all 18 patches.


Takashi


More information about the Alsa-devel mailing list