t_io_assist.sh revision 1.1
11.1Smaxv# $NetBSD: t_io_assist.sh,v 1.1 2019/02/05 13:00:03 maxv Exp $ 21.1Smaxv# 31.1Smaxv# Copyright (c) 2019 The NetBSD Foundation, Inc. 41.1Smaxv# All rights reserved. 51.1Smaxv# 61.1Smaxv# Redistribution and use in source and binary forms, with or without 71.1Smaxv# modification, are permitted provided that the following conditions 81.1Smaxv# are met: 91.1Smaxv# 1. Redistributions of source code must retain the above copyright 101.1Smaxv# notice, this list of conditions and the following disclaimer. 111.1Smaxv# 2. Redistributions in binary form must reproduce the above copyright 121.1Smaxv# notice, this list of conditions and the following disclaimer in the 131.1Smaxv# documentation and/or other materials provided with the distribution. 141.1Smaxv# 151.1Smaxv# THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS 161.1Smaxv# ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED 171.1Smaxv# TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 181.1Smaxv# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS 191.1Smaxv# BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 201.1Smaxv# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 211.1Smaxv# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 221.1Smaxv# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 231.1Smaxv# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 241.1Smaxv# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 251.1Smaxv# POSSIBILITY OF SUCH DAMAGE. 261.1Smaxv# 271.1Smaxv 281.1Smaxvatf_test_case io_assist 291.1Smaxvio_assist_head() 301.1Smaxv{ 311.1Smaxv atf_set "descr" "Check the I/O Assist provided in libnvmm" 321.1Smaxv} 331.1Smaxv 341.1Smaxvio_assist_body() 351.1Smaxv{ 361.1Smaxv $(atf_get_srcdir)/h_io_assist 371.1Smaxv 381.1Smaxv exitcode=$? 391.1Smaxv 401.1Smaxv if [ $exitcode -eq 6 ] ; then 411.1Smaxv atf_skip "NVMM driver not loaded" 421.1Smaxv elif [ $exitcode -ne 0 ] ; then 431.1Smaxv atf_fail "I/O Assist failed with errno $exitcode" 441.1Smaxv fi 451.1Smaxv} 461.1Smaxv 471.1Smaxvatf_init_test_cases() 481.1Smaxv{ 491.1Smaxv atf_add_test_case io_assist 501.1Smaxv} 51