Print this page
3996 want a libzfs_core API to rollback to latest snapshot
Reviewed by: Christopher Siden <christopher.siden@delphix.com>
Reviewed by: Adam Leventhal <ahl@delphix.com>
Reviewed by: George Wilson <george.wilson@delphix.com>

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/fs/zfs/sys/dsl_dataset.h
          +++ new/usr/src/uts/common/fs/zfs/sys/dsl_dataset.h
↓ open down ↓ 257 lines elided ↑ open up ↑
 258  258  
 259  259  void dsl_dataset_remove_from_next_clones(dsl_dataset_t *ds, uint64_t obj,
 260  260      dmu_tx_t *tx);
 261  261  void dsl_dataset_recalc_head_uniq(dsl_dataset_t *ds);
 262  262  int dsl_dataset_get_snapname(dsl_dataset_t *ds);
 263  263  int dsl_dataset_snap_lookup(dsl_dataset_t *ds, const char *name,
 264  264      uint64_t *value);
 265  265  int dsl_dataset_snap_remove(dsl_dataset_t *ds, const char *name, dmu_tx_t *tx);
 266  266  void dsl_dataset_set_refreservation_sync_impl(dsl_dataset_t *ds,
 267  267      zprop_source_t source, uint64_t value, dmu_tx_t *tx);
 268      -int dsl_dataset_rollback(const char *fsname, void *owner);
      268 +int dsl_dataset_rollback(const char *fsname, void *owner, nvlist_t *result);
 269  269  
 270  270  #ifdef ZFS_DEBUG
 271  271  #define dprintf_ds(ds, fmt, ...) do { \
 272  272          if (zfs_flags & ZFS_DEBUG_DPRINTF) { \
 273  273          char *__ds_name = kmem_alloc(MAXNAMELEN, KM_SLEEP); \
 274  274          dsl_dataset_name(ds, __ds_name); \
 275  275          dprintf("ds=%s " fmt, __ds_name, __VA_ARGS__); \
 276  276          kmem_free(__ds_name, MAXNAMELEN); \
 277  277          } \
 278  278  _NOTE(CONSTCOND) } while (0)
 279  279  #else
 280  280  #define dprintf_ds(dd, fmt, ...)
 281  281  #endif
 282  282  
 283  283  #ifdef  __cplusplus
 284  284  }
 285  285  #endif
 286  286  
 287  287  #endif /* _SYS_DSL_DATASET_H */
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX