Module Name: src Committed By: reinoud Date: Mon Jul 27 13:20:41 UTC 2009
Modified Files: src/sys/fs/udf: udf_vnops.c Log Message: System nodes are not written out on becomming inactive; they should be written out before automatically. However, when dealing with faulty discs that fail to mount, system nodes are of course not written out and thus may still be marked dirty, if only due to access. Especially on sequential media this gave rise to panics on reading trackinfo since the write track section had not yet been initialised. To generate a diff of this commit: cvs rdiff -u -r1.52 -r1.53 src/sys/fs/udf/udf_vnops.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/fs/udf/udf_vnops.c diff -u src/sys/fs/udf/udf_vnops.c:1.52 src/sys/fs/udf/udf_vnops.c:1.53 --- src/sys/fs/udf/udf_vnops.c:1.52 Wed Jul 8 14:46:55 2009 +++ src/sys/fs/udf/udf_vnops.c Mon Jul 27 13:20:41 2009 @@ -1,4 +1,4 @@ -/* $NetBSD: udf_vnops.c,v 1.52 2009/07/08 14:46:55 reinoud Exp $ */ +/* $NetBSD: udf_vnops.c,v 1.53 2009/07/27 13:20:41 reinoud Exp $ */ /* * Copyright (c) 2006, 2008 Reinoud Zandijk @@ -32,7 +32,7 @@ #include <sys/cdefs.h> #ifndef lint -__KERNEL_RCSID(0, "$NetBSD: udf_vnops.c,v 1.52 2009/07/08 14:46:55 reinoud Exp $"); +__KERNEL_RCSID(0, "$NetBSD: udf_vnops.c,v 1.53 2009/07/27 13:20:41 reinoud Exp $"); #endif /* not lint */ @@ -103,8 +103,11 @@ refcnt = udf_rw16(udf_node->efe->link_cnt); } - if ((refcnt == 0) && (vp->v_vflag & VV_SYSTEM)) + if ((refcnt == 0) && (vp->v_vflag & VV_SYSTEM)) { DPRINTF(VOLUMES, ("UDF_INACTIVE deleting VV_SYSTEM\n")); + /* system nodes are not writen out on inactive, so flush */ + udf_node->i_flags = 0; + } *ap->a_recycle = false; if ((refcnt == 0) && ((vp->v_vflag & VV_SYSTEM) == 0)) {