Module Name: src
Committed By: jruoho
Date: Fri Apr 20 05:41:26 UTC 2012
Modified Files:
src/tests/modules: t_abi_uvm.sh t_modload.sh
Log Message:
For now, skip module tests if modctl(8) fails either with EPERM or ENOSYS.
To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/tests/modules/t_abi_uvm.sh
cvs rdiff -u -r1.12 -r1.13 src/tests/modules/t_modload.sh
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/tests/modules/t_abi_uvm.sh
diff -u src/tests/modules/t_abi_uvm.sh:1.2 src/tests/modules/t_abi_uvm.sh:1.3
--- src/tests/modules/t_abi_uvm.sh:1.2 Tue Mar 20 05:50:11 2012
+++ src/tests/modules/t_abi_uvm.sh Fri Apr 20 05:41:25 2012
@@ -1,4 +1,4 @@
-# $NetBSD: t_abi_uvm.sh,v 1.2 2012/03/20 05:50:11 jruoho Exp $
+# $NetBSD: t_abi_uvm.sh,v 1.3 2012/04/20 05:41:25 jruoho Exp $
#
# Copyright (c) 2012 The NetBSD Foundation, Inc.
# All rights reserved.
@@ -32,11 +32,12 @@ PAGE_SIZE_head() {
}
PAGE_SIZE_body() {
- # XXX: There should be a reliable way to detect MODULAR.
+ # XXX: Adjust when modctl(8) fails consistently.
#
- sysctl machdep.xen > /dev/null 2>&1
+ $(atf_get_srcdir)/k_helper3 \
+ "%s/k_helper/k_helper.kmod" $(atf_get_srcdir)
- if [ $? -eq 0 ]; then
+ if [ $? -eq 1 ] || [ $? -eq 78 ]; then
atf_skip "host does not support modules"
fi
Index: src/tests/modules/t_modload.sh
diff -u src/tests/modules/t_modload.sh:1.12 src/tests/modules/t_modload.sh:1.13
--- src/tests/modules/t_modload.sh:1.12 Sat Apr 14 02:46:17 2012
+++ src/tests/modules/t_modload.sh Fri Apr 20 05:41:25 2012
@@ -1,4 +1,4 @@
-# $NetBSD: t_modload.sh,v 1.12 2012/04/14 02:46:17 pgoyette Exp $
+# $NetBSD: t_modload.sh,v 1.13 2012/04/20 05:41:25 jruoho Exp $
#
# Copyright (c) 2008 The NetBSD Foundation, Inc.
# All rights reserved.
@@ -42,7 +42,7 @@ plain_body() {
$(atf_get_srcdir)/k_helper3 \
"%s/k_helper/k_helper.kmod" $(atf_get_srcdir)
- if [ $? -eq 78 ]; then
+ if [ $? -eq 1 ] || [ $? -eq 78 ]; then
atf_skip "host does not support modules"
fi
@@ -115,7 +115,7 @@ iflag_body() {
$(atf_get_srcdir)/k_helper3 \
"%s/k_helper/k_helper.kmod" $(atf_get_srcdir)
- if [ $? -eq 78 ]; then
+ if [ $? -eq 1 ] || [ $? -eq 78 ]; then
atf_skip "host does not support modules"
fi
@@ -169,7 +169,7 @@ sflag_body() {
$(atf_get_srcdir)/k_helper3 \
"%s/k_helper/k_helper.kmod" $(atf_get_srcdir)
- if [ $? -eq 78 ]; then
+ if [ $? -eq 1 ] || [ $? -eq 78 ]; then
atf_skip "host does not support modules"
fi