aboutsummaryrefslogtreecommitdiffstats
path: root/include/sys/dmu_objset.h
diff options
context:
space:
mode:
authorSaso Kiselkov <[email protected]>2013-08-01 13:02:10 -0700
committerBrian Behlendorf <[email protected]>2013-08-08 13:27:21 -0700
commit3a17a7a99a1a6332d0999f9be68e2b8dc3933de1 (patch)
tree6f926bc52a8ae98a69d4b258e66bde381fa691fa /include/sys/dmu_objset.h
parentc11a12bc3b2e5ee9a6bd74e26f1a396b6025fbd4 (diff)
Illumos #3137 L2ARC compression
3137 L2ARC compression Reviewed by: George Wilson <[email protected]> Reviewed by: Matthew Ahrens <[email protected]> Approved by: Dan McDonald <[email protected]> References: illumos/illumos-gate@aad02571bc59671aa3103bb070ae365f531b0b62 https://www.illumos.org/issues/3137 http://wiki.illumos.org/display/illumos/L2ARC+Compression Notes for Linux port: A l2arc_nocompress module option was added to prevent the compression of l2arc buffers regardless of how a dataset's compression property is set. This allows the legacy behavior to be preserved. Ported by: James H <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Closes #1379
Diffstat (limited to 'include/sys/dmu_objset.h')
-rw-r--r--include/sys/dmu_objset.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/sys/dmu_objset.h b/include/sys/dmu_objset.h
index 013b6ec34..f42474429 100644
--- a/include/sys/dmu_objset.h
+++ b/include/sys/dmu_objset.h
@@ -20,6 +20,7 @@
*/
/*
* Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013 by Saso Kiselkov. All rights reserved.
*/
/* Portions Copyright 2010 Robert Milkowski */
@@ -129,6 +130,8 @@ struct objset {
((os)->os_secondary_cache == ZFS_CACHE_ALL || \
(os)->os_secondary_cache == ZFS_CACHE_METADATA)
+#define DMU_OS_IS_L2COMPRESSIBLE(os) ((os)->os_compress != ZIO_COMPRESS_OFF)
+
/* called from zpl */
int dmu_objset_hold(const char *name, void *tag, objset_t **osp);
int dmu_objset_own(const char *name, dmu_objset_type_t type,