mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-01-31 09:51:31 -05:00
fec: Use DIV_ROUND_UP macro
Use the standard DIV_ROUND_UP macro in order to provide better readability. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
committed by
David S. Miller
parent
f83331bab1
commit
ffed61e6fd
@@ -242,7 +242,7 @@ static void *swap_buffer(void *bufaddr, int len)
|
||||
int i;
|
||||
unsigned int *buf = bufaddr;
|
||||
|
||||
for (i = 0; i < (len + 3) / 4; i++, buf++)
|
||||
for (i = 0; i < DIV_ROUND_UP(len, 4); i++, buf++)
|
||||
*buf = cpu_to_be32(*buf);
|
||||
|
||||
return bufaddr;
|
||||
|
||||
Reference in New Issue
Block a user