Print this page
2619 asynchronous destruction of ZFS file systems
2747 SPA versioning with zfs feature flags
Reviewed by: Matt Ahrens <mahrens@delphix.com>
Reviewed by: George Wilson <gwilson@delphix.com>
Reviewed by: Richard Lowe <richlowe@richlowe.net>
Reviewed by: Dan Kruchinin <dan.kruchinin@gmail.com>
Approved by: Dan McDonald <danmcd@nexenta.com>

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/fs/zfs/sys/zap.h
          +++ new/usr/src/uts/common/fs/zfs/sys/zap.h
↓ open down ↓ 12 lines elided ↑ open up ↑
  13   13   * When distributing Covered Code, include this CDDL HEADER in each
  14   14   * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15   15   * If applicable, add the following below this CDDL HEADER, with the
  16   16   * fields enclosed by brackets "[]" replaced with your own identifying
  17   17   * information: Portions Copyright [yyyy] [name of copyright owner]
  18   18   *
  19   19   * CDDL HEADER END
  20   20   */
  21   21  /*
  22   22   * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
       23 + * Copyright (c) 2012 by Delphix. All rights reserved.
  23   24   */
  24   25  
  25   26  #ifndef _SYS_ZAP_H
  26   27  #define _SYS_ZAP_H
  27   28  
  28   29  /*
  29   30   * ZAP - ZFS Attribute Processor
  30   31   *
  31   32   * The ZAP is a module which sits on top of the DMU (Data Management
  32   33   * Unit) and implements a higher-level storage primitive using DMU
↓ open down ↓ 92 lines elided ↑ open up ↑
 125  126   *     regard to case (eg. looking for "foo" can find an entry "Foo").
 126  127   * Eventually, other flags will permit unicode normalization as well.
 127  128   */
 128  129  uint64_t zap_create(objset_t *ds, dmu_object_type_t ot,
 129  130      dmu_object_type_t bonustype, int bonuslen, dmu_tx_t *tx);
 130  131  uint64_t zap_create_norm(objset_t *ds, int normflags, dmu_object_type_t ot,
 131  132      dmu_object_type_t bonustype, int bonuslen, dmu_tx_t *tx);
 132  133  uint64_t zap_create_flags(objset_t *os, int normflags, zap_flags_t flags,
 133  134      dmu_object_type_t ot, int leaf_blockshift, int indirect_blockshift,
 134  135      dmu_object_type_t bonustype, int bonuslen, dmu_tx_t *tx);
      136 +uint64_t zap_create_link(objset_t *os, dmu_object_type_t ot,
      137 +    uint64_t parent_obj, const char *name, dmu_tx_t *tx);
 135  138  
 136  139  /*
 137  140   * Create a new zapobj with no attributes from the given (unallocated)
 138  141   * object number.
 139  142   */
 140  143  int zap_create_claim(objset_t *ds, uint64_t obj, dmu_object_type_t ot,
 141  144      dmu_object_type_t bonustype, int bonuslen, dmu_tx_t *tx);
 142  145  int zap_create_claim_norm(objset_t *ds, uint64_t obj,
 143  146      int normflags, dmu_object_type_t ot,
 144  147      dmu_object_type_t bonustype, int bonuslen, dmu_tx_t *tx);
↓ open down ↓ 148 lines elided ↑ open up ↑
 293  296  int zap_lookup_int(objset_t *os, uint64_t obj, uint64_t value);
 294  297  int zap_increment_int(objset_t *os, uint64_t obj, uint64_t key, int64_t delta,
 295  298      dmu_tx_t *tx);
 296  299  
 297  300  /* Here the key is an int and the value is a different int. */
 298  301  int zap_add_int_key(objset_t *os, uint64_t obj,
 299  302      uint64_t key, uint64_t value, dmu_tx_t *tx);
 300  303  int zap_lookup_int_key(objset_t *os, uint64_t obj,
 301  304      uint64_t key, uint64_t *valuep);
 302  305  
 303      -/*
 304      - * They name is a stringified version of key; increment its value by
 305      - * delta.  Zero values will be zap_remove()-ed.
 306      - */
 307      -int zap_increment_int(objset_t *os, uint64_t obj, uint64_t key, int64_t delta,
 308      -    dmu_tx_t *tx);
 309  306  int zap_increment(objset_t *os, uint64_t obj, const char *name, int64_t delta,
 310  307      dmu_tx_t *tx);
 311  308  
 312  309  struct zap;
 313  310  struct zap_leaf;
 314  311  typedef struct zap_cursor {
 315  312          /* This structure is opaque! */
 316  313          objset_t *zc_objset;
 317  314          struct zap *zc_zap;
 318  315          struct zap_leaf *zc_leaf;
↓ open down ↓ 164 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX