diff options
author | Aaron Lu <aaron.lu@intel.com> | 2016-02-17 09:54:25 +0800 |
---|---|---|
committer | Fengguang Wu <fengguang.wu@intel.com> | 2016-02-17 09:54:25 +0800 |
commit | 94d0f324adbf33e85e891ac89d7c743a2e2cebb9 (patch) | |
tree | a068f94d2eed430b4b9fdb2b1454d995c7d3d66c | |
parent | b143340d6d812ab591c8a3c1669cd8f64bc69537 (diff) | |
download | vm-scalability-94d0f324adbf33e85e891ac89d7c743a2e2cebb9.tar.gz |
swap: give user the ability to control size
User can specify a value in the job file. This is mostly useful to do
various testing, where the written size(pass_size) can play a role.
Signed-off-by: Aaron Lu <aaron.lu@intel.com>
-rwxr-xr-x | case-swap-w-seq | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/case-swap-w-seq b/case-swap-w-seq index 351c6c7..6ad7c1e 100755 --- a/case-swap-w-seq +++ b/case-swap-w-seq @@ -7,7 +7,7 @@ if [ "$SwapTotal" -eq 0 ]; then exit 1 fi -pass_size=$(( ((MemAvailable + SwapTotal) << 10) * 3 / 4)) +[ -n "$pass_size" ] || pass_size=$(( ((MemAvailable + SwapTotal) << 10) * 3 / 4)) testcase=$(basename $0) if [ "${testcase%-mt}" != "$testcase" ]; then |