1 /* $NetBSD: ulfs_snapshot.c,v 1.2 2013/06/08 22:05:15 dholland Exp $ */
2 /* from ffs_snapshot.c,v 1.122 2013/05/07 09:40:54 hannken Exp */
5 * Copyright 2000 Marshall Kirk McKusick. All Rights Reserved.
7 * Further information about snapshots can be obtained from:
9 * Marshall Kirk McKusick http://www.mckusick.com/softdep/
10 * 1614 Oxford Street mckusick@mckusick.com
11 * Berkeley, CA 94709-1608 +1-510-843-9542
14 * Redistribution and use in source and binary forms, with or without
15 * modification, are permitted provided that the following conditions
18 * 1. Redistributions of source code must retain the above copyright
19 * notice, this list of conditions and the following disclaimer.
20 * 2. Redistributions in binary form must reproduce the above copyright
21 * notice, this list of conditions and the following disclaimer in the
22 * documentation and/or other materials provided with the distribution.
24 * THIS SOFTWARE IS PROVIDED BY MARSHALL KIRK MCKUSICK ``AS IS'' AND ANY
25 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
26 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
27 * DISCLAIMED. IN NO EVENT SHALL MARSHALL KIRK MCKUSICK BE LIABLE FOR
28 * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
29 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
30 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
31 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
32 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
33 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
36 * @(#)ffs_snapshot.c 8.11 (McKusick) 7/23/00
38 * from FreeBSD: ffs_snapshot.c,v 1.79 2004/02/13 02:02:06 kuriyama Exp
41 #include <sys/cdefs.h>
42 __KERNEL_RCSID(0, "$NetBSD: ulfs_snapshot.c,v 1.2 2013/06/08 22:05:15 dholland Exp $");
44 #if defined(_KERNEL_OPT)
48 #include <sys/param.h>
49 #include <sys/kernel.h>
50 #include <sys/systm.h>
54 #include <sys/namei.h>
55 #include <sys/sched.h>
57 #include <sys/malloc.h>
58 #include <sys/mount.h>
59 #include <sys/resource.h>
60 #include <sys/resourcevar.h>
61 #include <sys/vnode.h>
62 #include <sys/kauth.h>
63 #include <sys/fstrans.h>
64 #include <sys/wapbl.h>
66 #include <miscfs/specfs/specdev.h>
68 #include <ufs/lfs/ulfs_quotacommon.h>
69 #include <ufs/lfs/ulfsmount.h>
70 #include <ufs/lfs/ulfs_inode.h>
71 #include <ufs/lfs/ulfs_extern.h>
72 #include <ufs/lfs/ulfs_bswap.h>
74 #include <ufs/lfs/lfs.h>
75 #include <ufs/lfs/lfs_extern.h>
80 * Decrement extra reference on snapshot when last name is removed.
81 * It will not be freed until the last open reference goes away.
84 ulfs_snapgone(struct inode
*ip
)
88 panic("reached ulfs_snapgone\n");