aboutsummaryrefslogtreecommitdiffstats
path: root/resources/libraries/python
diff options
context:
space:
mode:
authorJan Gelety <jgelety@cisco.com>2019-11-30 06:47:45 +0100
committerPeter Mikus <pmikus@cisco.com>2019-12-09 14:44:43 +0000
commit6b893681d1246f90e55b44762dd85f7d9dab1348 (patch)
treef4d0a30ead43f0fc40fab846d952839fd37e71db /resources/libraries/python
parent190462e1f242b59d927eff3e63826fe6343eadbc (diff)
FIX: integer divisions
Change-Id: I28caf62f418bf18601cd379603d03c307e3ba9c8 Signed-off-by: Jan Gelety <jgelety@cisco.com>
Diffstat (limited to 'resources/libraries/python')
-rw-r--r--resources/libraries/python/DUTSetup.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/resources/libraries/python/DUTSetup.py b/resources/libraries/python/DUTSetup.py
index 3544997e55..1a8899f6f6 100644
--- a/resources/libraries/python/DUTSetup.py
+++ b/resources/libraries/python/DUTSetup.py
@@ -826,7 +826,7 @@ class DUTSetup:
# If we want to allocate hugepage dynamically
if allocate:
mem_needed = (mem_size * 1024) - (huge_free * huge_size)
- huge_to_allocate = ((mem_needed / huge_size) * 2) + huge_total
+ huge_to_allocate = ((mem_needed // huge_size) * 2) + huge_total
max_map_count = huge_to_allocate*4
# Increase maximum number of memory map areas a process may have
ret_code, _, _ = ssh.exec_command_sudo(