]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
MFV r298471: 6052 decouple lzc_create() from the implementation details
authorAndriy Gapon <avg@FreeBSD.org>
Fri, 22 Apr 2016 13:00:27 +0000 (13:00 +0000)
committerAndriy Gapon <avg@FreeBSD.org>
Fri, 22 Apr 2016 13:00:27 +0000 (13:00 +0000)
commitdbbcddb4268d3bfeffede9711a6a5d06a4f0862c
treef4347ef540d8c19c2261ad1fe498b5813025285a
parent8ad8cdc95f52fc48ae3c6d3a48d5cb36294ece89
parent0efd880fa0671e7771ae22dd2bb2172ed933b679
MFV r298471: 6052 decouple lzc_create() from the implementation details

illumos/illumos-gate@26455f9efcf9b1e44937d4d86d1ce37b006f25a9
https://github.com/illumos/illumos-gate/commit/26455f9efcf9b1e44937d4d86d1ce37b006f25a9

https://www.illumos.org/issues/6052
  At the moment type parameter of lzc_create() is of dmu_objset_type_t type.
  That exposes an implementation detail and requires sys/fs/zfs.h to be included
  in libzfs_core.h creating unnecessary coupling between libzfs_core interface
  and ZFS internals.
  I think that dmu_objset_type_t should be replaced with a libzfs_core
  enumeration of supported dataset types.
  For ABI reasons the new enumeration could be bit-compatible with
  dmu_objset_type_t.
  For example:
      typedef enum {
          LZC_DST_ZFS = 2,
          LZC_DST_ZVOL
      } lzc_dataset_type_t;

Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Approved by: Richard Lowe <richlowe@richlowe.net>
Author: Andriy Gapon <andriy.gapon@clusterhq.com>

MFC after: 2 weeks
Sponsored by: ClusterHQ
cddl/contrib/opensolaris/lib/libzfs/common/libzfs_dataset.c
cddl/contrib/opensolaris/lib/libzfs_core/common/libzfs_core.c
cddl/contrib/opensolaris/lib/libzfs_core/common/libzfs_core.h
sys/cddl/contrib/opensolaris/uts/common/sys/fs/zfs.h