Add a kludge to prevent a test run from completely hanging.
Some analysis: 1) p2k_ffs test program opens a socketpair and forks off rump_ffs 2) after mounting the file system, test program decides it wants to skip the test and exits 3) somehow, the puffs event thread of rump_ffs stays in kqueue waiting for activity. fstat+gdb suggests it's waiting for the now-orphaned socketpair (but I didn't fully verify. is there an easy way to dump the state of a kqueue descriptor?). 4) test program is a zombie 5) atf-run waits forever Note: this doesn't trigger always. So, it seems there are at least two bugs: 1) test case doesn't timeout 2) the kevent call in rump_ffs never returns even though the sockerpair is orphaned So, explicitly unmount the file system before skipping the test. Obviously the above bugs needs to be properly fixed, since other skipping test cases can unbeknowingly trigger the issue.
This commit is contained in:
parent
49f1dcc8e5
commit
172587ab09
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: t_full.c,v 1.5 2011/01/07 11:41:54 pooka Exp $ */
|
||||
/* $NetBSD: t_full.c,v 1.6 2011/03/06 10:33:40 pooka Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2010 The NetBSD Foundation, Inc.
|
||||
@ -57,6 +57,13 @@ fillfs(const atf_tc_t *tc, const char *mp)
|
||||
int fd, i = 0;
|
||||
|
||||
if (FSTYPE_P2K_FFS(tc) || FSTYPE_PUFFS(tc) || FSTYPE_RUMPFS(tc)) {
|
||||
/*
|
||||
* XXX: explicitly unmount to prevent some race.
|
||||
* temporary hack, fix properly
|
||||
*/
|
||||
if (FSTYPE_P2K_FFS(tc)) {
|
||||
puffs_fstest_unmount(tc, mp, MNT_FORCE);
|
||||
}
|
||||
atf_tc_skip("fs does not support explicit block allocation "
|
||||
"(GOP_ALLOC)");
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user