Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/miscfs Unfortunately MFS uses v_data of its anonymous de...
details: https://anonhg.NetBSD.org/src/rev/45833daf523e
branches: trunk
changeset: 339169:45833daf523e
user: hannken <hannken%NetBSD.org@localhost>
date: Wed Jul 01 08:13:52 2015 +0000
description:
Unfortunately MFS uses v_data of its anonymous device vnode so
it cannot be used as vcache key. Use v_interlock as key ...
diffstat:
sys/miscfs/deadfs/dead_vfsops.c | 9 ++++-----
sys/miscfs/specfs/spec_vnops.c | 7 +++----
2 files changed, 7 insertions(+), 9 deletions(-)
diffs (58 lines):
diff -r e7ddc7be1ccb -r 45833daf523e sys/miscfs/deadfs/dead_vfsops.c
--- a/sys/miscfs/deadfs/dead_vfsops.c Wed Jul 01 06:48:25 2015 +0000
+++ b/sys/miscfs/deadfs/dead_vfsops.c Wed Jul 01 08:13:52 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: dead_vfsops.c,v 1.6 2015/06/30 06:19:22 hannken Exp $ */
+/* $NetBSD: dead_vfsops.c,v 1.7 2015/07/01 08:13:53 hannken Exp $ */
/*-
* Copyright (c) 2014 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: dead_vfsops.c,v 1.6 2015/06/30 06:19:22 hannken Exp $");
+__KERNEL_RCSID(0, "$NetBSD: dead_vfsops.c,v 1.7 2015/07/01 08:13:53 hannken Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -108,9 +108,8 @@
uvm_vnp_setsize(vp, 0);
spec_node_init(vp, vap->va_rdev);
- vp->v_data = vp;
- *key_len = sizeof(vp->v_data);
- *new_key = &vp->v_data;
+ *key_len = sizeof(vp->v_interlock);
+ *new_key = &vp->v_interlock;
return 0;
}
diff -r e7ddc7be1ccb -r 45833daf523e sys/miscfs/specfs/spec_vnops.c
--- a/sys/miscfs/specfs/spec_vnops.c Wed Jul 01 06:48:25 2015 +0000
+++ b/sys/miscfs/specfs/spec_vnops.c Wed Jul 01 08:13:52 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: spec_vnops.c,v 1.152 2015/06/30 06:19:21 hannken Exp $ */
+/* $NetBSD: spec_vnops.c,v 1.153 2015/07/01 08:13:52 hannken Exp $ */
/*-
* Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -58,7 +58,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: spec_vnops.c,v 1.152 2015/06/30 06:19:21 hannken Exp $");
+__KERNEL_RCSID(0, "$NetBSD: spec_vnops.c,v 1.153 2015/07/01 08:13:52 hannken Exp $");
#include <sys/param.h>
#include <sys/proc.h>
@@ -1097,8 +1097,7 @@
struct vnode *vp = ap->a_vp;
KASSERT(vp->v_mount == dead_rootmount);
- vcache_remove(vp->v_mount, &vp->v_data, sizeof(vp->v_data));
- vp->v_data = NULL;
+ vcache_remove(vp->v_mount, &vp->v_interlock, sizeof(vp->v_interlock));
return 0;
}
Home |
Main Index |
Thread Index |
Old Index