aboutsummaryrefslogtreecommitdiff
path: root/huge_page_setup_helper.py
diff options
context:
space:
mode:
authorAnton Arapov <anton@redhat.com>2010-10-20 12:49:22 +0200
committerEric B Munson <emunson@mgebm.net>2010-10-20 10:49:25 -0500
commit1f07d1dd1d4b494e03de26e9af9945ad7a654e78 (patch)
tree17db786230e5a747c5af8ec6fe281d9bae7a3228 /huge_page_setup_helper.py
parent26c93da32943f6fee017d5b63488dc21789aace5 (diff)
downloadlibhugetlbfs-1f07d1dd1d4b494e03de26e9af9945ad7a654e78.tar.gz
setup_helper: fix the minor arithmetic issue.
we do want compare MiB with MiB. Reported-by: CAI Qian <caiqian@redhat.com> Signed-off-by: Anton Arapov <anton@redhat.com> Signed-off-by: Eric B Munson <emunson@mgebm.net>
Diffstat (limited to 'huge_page_setup_helper.py')
-rwxr-xr-xhuge_page_setup_helper.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/huge_page_setup_helper.py b/huge_page_setup_helper.py
index 737b3d9..b8545ed 100755
--- a/huge_page_setup_helper.py
+++ b/huge_page_setup_helper.py
@@ -109,7 +109,7 @@ while not userIn:
if userHugePageReqMB > (memTotal - 128):
userIn = None
print "Refusing to allocate %d, you must leave at least 128MB for the system" % userHugePageReqMB
- elif userHugePageReqMB < (hugePageSize / 1024):
+ elif userHugePageReqMB < (hugePageSize / (1024 * 1024)):
userIn = None
print "Sorry, allocation must be at least a page's worth!"
else: