Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/lib/libp2k Implement abortop.
details: https://anonhg.NetBSD.org/src/rev/2377c88f267b
branches: trunk
changeset: 748235:2377c88f267b
user: pooka <pooka%NetBSD.org@localhost>
date: Sat Oct 17 23:20:15 2009 +0000
description:
Implement abortop.
diffstat:
lib/libp2k/p2k.c | 26 +++++++++++++++++++++++++-
1 files changed, 25 insertions(+), 1 deletions(-)
diffs (47 lines):
diff -r 6689eb64be7d -r 2377c88f267b lib/libp2k/p2k.c
--- a/lib/libp2k/p2k.c Sat Oct 17 23:19:52 2009 +0000
+++ b/lib/libp2k/p2k.c Sat Oct 17 23:20:15 2009 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: p2k.c,v 1.24 2009/10/15 16:41:08 pooka Exp $ */
+/* $NetBSD: p2k.c,v 1.25 2009/10/17 23:20:15 pooka Exp $ */
/*
* Copyright (c) 2007, 2008, 2009 Antti Kantee. All Rights Reserved.
@@ -300,6 +300,7 @@
PUFFSOP_SET(pops, p2k, node, inactive);
PUFFSOP_SET(pops, p2k, node, reclaim);
+ PUFFSOP_SET(pops, p2k, node, abortop);
dodaemon = true;
if (getenv("P2K_DEBUG") != NULL) {
@@ -889,6 +890,29 @@
return rv;
}
+int
+p2k_node_abortop(struct puffs_usermount *pu, puffs_cookie_t opc,
+ const struct puffs_cn *pcn)
+{
+ struct p2k_node *p2n_dir = opc;
+ struct componentname *cnp;
+
+ if ((cnp = p2n_dir->p2n_cn) != NULL) {
+ freecn(cnp, 0);
+ p2n_dir->p2n_cn = NULL;
+ }
+ if ((cnp = p2n_dir->p2n_cn_ren_src) != NULL) {
+ freecn(cnp, RUMPCN_FORCEFREE);
+ p2n_dir->p2n_cn_ren_src = NULL;
+ }
+ if ((cnp = p2n_dir->p2n_cn_ren_targ) != NULL) {
+ freecn(cnp, RUMPCN_FORCEFREE);
+ p2n_dir->p2n_cn_ren_targ = NULL;
+ }
+
+ return 0;
+}
+
static int
do_nukenode(struct p2k_node *p2n_dir, struct p2k_node *p2n,
const struct puffs_cn *pcn,
Home |
Main Index |
Thread Index |
Old Index