aboutsummaryrefslogtreecommitdiff
path: root/zram02.sh
diff options
context:
space:
mode:
Diffstat (limited to 'zram02.sh')
-rwxr-xr-xzram02.sh15
1 files changed, 13 insertions, 2 deletions
diff --git a/zram02.sh b/zram02.sh
index dbb7e51..acb1038 100755
--- a/zram02.sh
+++ b/zram02.sh
@@ -8,18 +8,21 @@
#
# This program is distributed in the hope that it would be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write the Free Software Foundation,
-# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
#
# Test checks that we can create swap zram device.
#
# Author: Alexey Kodanev <alexey.kodanev@oracle.com>
# Modified: Naresh Kamboju <naresh.kamboju@linaro.org>
+TCID="zram02"
+ERR_CODE=0
+
. ./zram_lib.sh
# Test will create the following number of zram devices:
@@ -38,9 +41,17 @@ zram_max_streams="2"
zram_sizes="1048576" # 1M
zram_mem_limits="1M"
+zram_load
zram_max_streams
zram_set_disksizes
zram_set_memlimit
zram_makeswap
zram_swapoff
zram_cleanup
+zram_unload
+
+if [ $ERR_CODE -ne 0 ]; then
+ echo "$TCID : FAIL"
+else
+ echo "$TCID : PASS"
+fi