mirror_zfs/include
Serapheim Dimitropoulos 9f3c72a2a8 Name anonymous enum of KMC_BIT constants
Giving a name to this enum makes it discoverable from
debugging tools like DRGN and SDB. For example, with
the name proposed on this patch we can iterate over
these values in DRGN:
```
>>> prog.type('enum kmc_bit').enumerators
(('KMC_BIT_NOTOUCH', 0), ('KMC_BIT_NODEBUG', 1),
('KMC_BIT_NOMAGAZINE', 2), ('KMC_BIT_NOHASH', 3),
('KMC_BIT_QCACHE', 4), ('KMC_BIT_KMEM', 5),
('KMC_BIT_VMEM', 6), ('KMC_BIT_SLAB', 7),
...
```
This enables SDB to easily pretty-print the flags of
the spl_kmem_caches in the system like this:
```
> spl_kmem_caches -o "name,flags,total_memory"
name                                       flags total_memory
------------------------ ----------------------- ------------
abd_t                    KMC_NOMAGAZINE|KMC_SLAB        4.5MB
arc_buf_hdr_t_full       KMC_NOMAGAZINE|KMC_SLAB       12.3MB
... <cropped> ...
ddt_cache                               KMC_VMEM      583.7KB
ddt_entry_cache          KMC_NOMAGAZINE|KMC_SLAB         0.0B
... <cropped> ...
zio_buf_1048576             KMC_NODEBUG|KMC_VMEM         0.0B
... <cropped> ...
```

Reviewed-by: Matt Ahrens <matt@delphix.com>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Serapheim Dimitropoulos <serapheim@delphix.com>
Closes #9478
2019-10-18 13:25:44 -04:00
..
os Name anonymous enum of KMC_BIT constants 2019-10-18 13:25:44 -04:00
sys OpenZFS restructuring - ARC memory pressure 2019-10-18 13:23:19 -04:00
.gitignore OpenZFS restructuring - move platform specific sources 2019-09-06 11:26:26 -07:00
libnvpair.h Add JSON output support to channel programs 2018-03-19 12:40:58 -07:00
libuutil_common.h Support custom build directories and move includes 2010-09-08 12:38:56 -07:00
libuutil_impl.h Support custom build directories and move includes 2010-09-08 12:38:56 -07:00
libuutil.h Correct cppcheck errors 2017-09-19 12:17:29 -07:00
libzfs_core.h Add subcommand to wait for background zfs activity to complete 2019-09-13 18:09:06 -07:00
libzfs_impl.h OpenZFS restructuring - libzfs 2019-10-03 10:33:16 -07:00
libzfs.h Fix encryption hierarchy issues with zfs recv -d 2019-09-25 17:02:32 -07:00
libzutil.h OpenZFS restructuring - libzutil 2019-10-03 10:20:44 -07:00
Makefile.am OpenZFS restructuring - move platform specific headers 2019-09-05 09:34:54 -07:00
thread_pool.h Add libtpool (thread pools) 2017-08-09 15:31:08 -07:00
zfeature_common.h Fast Clone Deletion 2019-07-26 10:54:14 -07:00
zfs_comutil.h Fix pool creation with feature@allocation_classes disabled 2019-10-10 16:39:41 -07:00
zfs_deleg.h Remove code for zfs remap 2019-06-24 16:44:01 -07:00
zfs_fletcher.h DLPX-44812 integrate EP-220 large memory scalability 2016-11-29 14:34:27 -08:00
zfs_namecheck.h Restrict filesystem creation if name referred either '.' or '..' 2019-06-13 08:56:15 -07:00
zfs_prop.h Add zfs module feature and property info to sysfs 2018-09-02 12:09:53 -07:00