diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-08-01 19:48:41 +0000 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-08-01 19:48:41 +0000 |
commit | 3a5d86fcd1ef7eb3617d26046cdffea4245ca987 (patch) | |
tree | 57af7a49484f29e5fa9aee1bba82b6c5a1924932 /linux/drivers/media/dvb/frontends/s5h1411.h | |
parent | 2cf40a2b22144d35374eec8c26aab124bc129818 (diff) | |
download | mediapointer-dvb-s2-3a5d86fcd1ef7eb3617d26046cdffea4245ca987.tar.gz mediapointer-dvb-s2-3a5d86fcd1ef7eb3617d26046cdffea4245ca987.tar.bz2 |
Use DIV_ROUND_CLOSEST
From: Julia Lawall <julia@diku.dk>
The kernel.h macro DIV_ROUND_CLOSEST performs the computation (x + d/2)/d
but is perhaps more readable.
The semantic patch that makes this change is as follows:
(http://www.emn.fr/x-info/coccinelle/)
// <smpl>
@haskernel@
@@
@depends on haskernel@
expression x,__divisor;
@@
- (((x) + ((__divisor) / 2)) / (__divisor))
+ DIV_ROUND_CLOSEST(x,__divisor)
// </smpl>
Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'linux/drivers/media/dvb/frontends/s5h1411.h')
0 files changed, 0 insertions, 0 deletions