Commit Graph

1572 Commits

Author SHA1 Message Date
christos
d1cc87bd78 hook in libexecinfo 2012-05-27 18:52:16 +00:00
christos
5212b5c3e8 add a test for the backtrace function. 2012-05-27 18:47:18 +00:00
martin
3a550d746a Simplify creation of a temporary file slightly, fix sizeof(buf) confusion
when buf is a pointer.
2012-05-23 16:08:32 +00:00
martin
6a653c6635 Typo in comment 2012-05-22 09:23:39 +00:00
martin
6c3cc552c2 Calling _lwp_create() with a bogus ucontext could trigger a kernel
assertion failure (and thus a crash in DIAGNOSTIC kernels). Independently
discovered by YAMAMOTO Takashi and Joel Sing.

To avoid this, introduce a cpu_mcontext_validate() function and move all
sanity checks from cpu_setmcontext() there. Also untangle the netbsd32
compat mess slightly and add a cpu_mcontext32_validate() cousin there.

Add an exhaustive atf test case, based partly on code from Joel Sing.

Should finally fix the remaining open part of PR kern/43903.
2012-05-21 14:15:16 +00:00
jruoho
959e675b20 Make the test pass. It appears that this however does not reproduce the
PR kern/46463, even though the command is exactly the same.
2012-05-19 07:30:37 +00:00
jruoho
63e8388028 Clarify this a little. 2012-05-18 15:36:21 +00:00
jruoho
af62c3b4d8 Add a test case for PR kern/46463. From Richard Hansen. 2012-05-18 15:25:25 +00:00
martin
cfbccd804b mmap_block:
do not use a hardcoded block device list, but query the kernel for attached
disks instead, then try to mmap the raw partition.
2012-05-16 19:12:59 +00:00
jruoho
5c4e704752 Remove also redundant comment (the reference to the PR is already in the
metadata).
2012-05-16 13:54:28 +00:00
martin
7c32638bb1 Simplify the test for PR kern/4645 and make it independend of resource
settings.
2012-05-16 13:48:35 +00:00
wiz
d00eda4ad2 Fix typo in comment. 2012-05-16 11:45:08 +00:00
martin
90aaec5d8a Enable the test for PR kern/46457 now that it does not crash the
kernel any more.
2012-05-16 09:51:58 +00:00
jruoho
b1a7d876eb Add a case for PR kern/46457. This is skipped for the time being, as it
reproduces the panic described in the PR.
2012-05-16 09:06:35 +00:00
alnsn
c5290ad075 Test a bug found by Geza Herman. 2012-05-15 18:46:20 +00:00
riastradh
35d57656cd Adjust t_renamerace now that ext2fs and ffs have good rename. 2012-05-09 00:22:26 +00:00
wiz
4739fc03e4 Adapt to repository move of dist from external/bsd/bzip2 to
external/bsd/bzip2/dist.
2012-05-07 08:51:47 +00:00
wiz
3815d29a7f Finish move of bzip2 from dist/bzip2 to external/bsd/bzip2. 2012-05-07 00:35:25 +00:00
martin
d0518d9cf8 Comment out the expected failure, as it does not trigger anymore. 2012-05-06 17:27:22 +00:00
martin
c06a8560ae Revert previous, si_addr is expected to be the faulting *data* address
(mmm, consistent standards).
Add a few tweaks to prevent the compiler's optimizer outsmarting the test.
2012-04-23 15:07:56 +00:00
martin
51f1919a26 Do not compare si_addr (address of faulting instruction) against the
unaligned data address causing the fault - this will always fail.
If anybody knows a portable way to get the data address involved in the
fault, please fix the test case as originally intended.
2012-04-22 08:52:26 +00:00
jruoho
2ef8e9d811 Avoid harmless compiler (integer) warnings. 2012-04-21 01:15:13 +00:00
manu
ae04a0ba81 Do not set PUFFS_KFLAG_CACHE_FS_TTL for PUFFS tests 2012-04-21 01:03:46 +00:00
jruoho
71224831e0 Add few unit tests for mlock(2), including a case for PR kern/44788. 2012-04-20 12:11:29 +00:00
jruoho
84c32e5f2a For now, skip module tests if modctl(8) fails either with EPERM or ENOSYS. 2012-04-20 05:41:25 +00:00
jruoho
c69613ea1e Close all file descriptors before trying to reason about the number of open
descriptors. Should fix the test failures reported on current users.
2012-04-20 05:15:11 +00:00
jym
c5252d3225 ATF test for SIGBUS => BUS_ADRALN (invalid address alignment).
That one is tedious to test under x86: alignment exceptions are
not reported by this architecture unless you ask for them explicitely (by
setting the PSL_AC bit). The brokenness does not end there: %cr2 should
contain the address where the unaligned access occured, alas, it does not.

I am not aware of other architectures where this could happen. Still, my
knowledge is limited; if there is one, feel free to send me a mail and I
will update the test accordingly.

Adding insult to injury, this test can fail in various funny ways with VMs:
- under x86 QEMU, no trap() happens. As ring 3 code stays almost untouched by
QEMU VMM, I suppose the exception can only be triggered when the host
itself is capable of catching unaligned accesses.
- under Virtual Box with HVM support, i386 works fine, but amd64 fails with a
SIGILL (Illegal instruction) that happens right before entering the
signal handler. No idea why, and trying to debug it with gdb freezes the VM
(including ddb breaks).

Anyway, tested with:
- i386: P4 host, anita, Virtual Box HVM (Mac OS X)
- amd64: anita, Virtual Box HVM (Mac OS X)

XXX I would appreciate if someone could test it under a real amd64 host with
an up-to-date kernel, so I can reasonably assume that the culprit is
Virtual Box and not our amd64 port (my test machine being off line
I cannot do it myself). Results from other arches would be a plus too.

Initial issue reported by Nicolas Joly on port-amd64. Thanks!
2012-04-20 00:40:31 +00:00
jruoho
c7358053ef Add a test case for PR bin/39546. 2012-04-19 18:51:35 +00:00
martin
ca7d70aa58 While we need an absolute path when loading a module (including the .kmod
extension), we want the shortname w/o extension for the unload.
2012-04-17 21:39:19 +00:00
jruoho
f95573c233 Return from main() and use EXIT_FAILURE/EXIT_SUCCESS from stdlib(3). 2012-04-17 09:23:21 +00:00
jruoho
ce711fc79d Avoid zero-length format string. 2012-04-17 06:23:52 +00:00
jruoho
681aa38aee Adjust. 2012-04-17 05:18:54 +00:00
christos
2e74a3b7d6 simplify 2012-04-15 03:05:57 +00:00
jruoho
f03351f948 Add few more NICs. 2012-04-14 15:13:57 +00:00
jruoho
0a7b1257ab Fix RCS string. 2012-04-14 12:43:05 +00:00
jruoho
0953dc8744 Add a test case for PR kern/46328 (tested naively with tcpdump(8)). 2012-04-14 12:21:45 +00:00
pgoyette
d2616fb0aa The k_helper3 program does not need to be (and shouldn't be) installed
in its own subdirectory.
2012-04-14 02:46:17 +00:00
pgoyette
84c6871a07 Let's get it right this time. 2012-04-13 15:02:37 +00:00
pgoyette
bfea36353b Put k_helper3 in the correct location. 2012-04-13 14:54:39 +00:00
njoly
d2c0752725 Do not re-add -mieee option on alpha, it's already set by default. 2012-04-13 12:31:19 +00:00
jruoho
e49dc377ca Add a helper program that loads a module and returns the errno from modctl(8).
XXX: As noted on tech-kern@, the syscall should be modified to fail
     consistently with a given predefined errno on non-MODULAR kernels.
2012-04-13 07:05:32 +00:00
jruoho
144c5468dc Although this does not fail, add a case for the discussion in PR bin/46327. 2012-04-13 06:12:32 +00:00
jruoho
93242fdaae Xfail on qemu unconditionally after all. 2012-04-13 06:10:55 +00:00
jruoho
6c8d572a17 Reduce the number of snprintf(3) invocations, as sparc/qemu timeouts. 2012-04-11 16:21:42 +00:00
jruoho
1fea472283 Flip previous (i386/qemu fails, not the amd64/qemu). 2012-04-11 16:18:39 +00:00
jruoho
a141b66fc2 Revisit the previous: fails on qemu/amd64 but not qemu/i386. 2012-04-11 10:18:25 +00:00
jruoho
3964c8242c As it turned out, the fpsetmask(3) tests were unnecessarily skipped on Qemu.
Thus, remove xfails that do not trigger.
2012-04-11 06:45:16 +00:00
jruoho
fd6c1df52d Do not skip the tests on Qemu, but point to PR misc/44767 instead. 2012-04-10 12:43:06 +00:00
jruoho
97f06f6fb9 Point to port-macppc/46319 when failing on macppc. 2012-04-10 03:59:59 +00:00
jruoho
a74ccce819 Test that sysctl(8) does not segfault, as reported by pgoyette@ on current
users.
2012-04-10 02:39:33 +00:00