dsl_dir.h revision 0b383af75dbdbe45ccf120c8dcf38acb3b24ae03
/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* Copyright 2008 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#ifndef _SYS_DSL_DIR_H
#define _SYS_DSL_DIR_H
#include <sys/dsl_pool.h>
#include <sys/dsl_synctask.h>
#include <sys/refcount.h>
#include <sys/zfs_context.h>
#ifdef __cplusplus
extern "C" {
#endif
struct dsl_dataset;
typedef enum dd_used {
} dd_used_t;
#define DD_FLAG_USED_BREAKDOWN (1<<0)
typedef struct dsl_dir_phys {
/*
* how much space our children are accounting for; for leaf
* datasets, == physical space used by fs + snaps
*/
/* Administrative quota setting */
/* Administrative reservation setting */
struct dsl_dir {
/* These are immutable; no lock needed: */
/* protected by lock on pool's dp_dirty_dirs list */
/* protected by dp_config_rwlock */
/* Protected by dd_lock */
/* gross estimate of space used by in-flight tx's */
/* amount of space we expect to write; == amount of dirty data */
/* protected by dd_lock; keep at end of struct for better locality */
char dd_myname[MAXNAMELEN];
};
const char **tailp);
/* internal reserved dir name */
#define MOS_DIR_NAME "$MOS"
#define ORIGIN_DIR_NAME "$ORIGIN"
#ifdef ZFS_DEBUG
if (zfs_flags & ZFS_DEBUG_DPRINTF) { \
KM_SLEEP); \
} \
#else
#endif
#ifdef __cplusplus
}
#endif
#endif /* _SYS_DSL_DIR_H */