lkml.org 
[lkml]   [2012]   [Dec]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] kdb: use DIV_ROUND_UP where possible
Date
Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
---
kernel/debug/kdb/kdb_main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/debug/kdb/kdb_main.c b/kernel/debug/kdb/kdb_main.c
index 18ce064..199abdc 100644
--- a/kernel/debug/kdb/kdb_main.c
+++ b/kernel/debug/kdb/kdb_main.c
@@ -1670,7 +1670,7 @@ static int kdb_md(int argc, const char **argv)
num, repeat, phys);
addr += bytesperword * n;
repeat -= n;
- z = (z + num - 1) / num;
+ z = DIV_ROUND_UP(z, num);
if (z > 2) {
int s = num * (z-2);
kdb_printf(kdb_machreg_fmt0 "-" kdb_machreg_fmt0
--
1.8.0


\
 
 \ /
  Last update: 2012-12-20 21:21    [W:0.257 / U:0.992 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site