diff options
author | John Sonnenschein <johns@joyent.com> | 2012-11-07 22:04:45 +0000 |
---|---|---|
committer | John Sonnenschein <johns@joyent.com> | 2012-11-07 22:04:45 +0000 |
commit | ad2a40e16d2bee59cfe84f89db3ce92b9f15adff (patch) | |
tree | bc8e23c4588b29e4602a54b72dbe2f1d8786468d /usr/src/uts/intel/zfs | |
parent | b5f683274309a9c6f46eea8ce5d0cca514d977a8 (diff) | |
parent | 7c45eec5760d4195b6b85770e7ac51c380adfb8a (diff) | |
download | illumos-joyent-ad2a40e16d2bee59cfe84f89db3ce92b9f15adff.tar.gz |
Illumos sync
Diffstat (limited to 'usr/src/uts/intel/zfs')
-rw-r--r-- | usr/src/uts/intel/zfs/Makefile | 8 | ||||
-rw-r--r-- | usr/src/uts/intel/zfs/spa_boot.c | 25 |
2 files changed, 33 insertions, 0 deletions
diff --git a/usr/src/uts/intel/zfs/Makefile b/usr/src/uts/intel/zfs/Makefile index 669ce93ed3..f106577baa 100644 --- a/usr/src/uts/intel/zfs/Makefile +++ b/usr/src/uts/intel/zfs/Makefile @@ -79,6 +79,14 @@ LINTTAGS += -erroff=E_STATIC_UNUSED LINTTAGS += -erroff=E_PTRDIFF_OVERFLOW LINTTAGS += -erroff=E_ASSIGN_NARROW_CONV +CERRWARN += -_gcc=-Wno-type-limits +CERRWARN += -_gcc=-Wno-switch +CERRWARN += -_gcc=-Wno-parentheses +CERRWARN += -_gcc=-Wno-unused-variable +CERRWARN += -_gcc=-Wno-unused-function +CERRWARN += -_gcc=-Wno-unused-label +CERRWARN += -_gcc=-Wno-uninitialized + # # Default build targets. # diff --git a/usr/src/uts/intel/zfs/spa_boot.c b/usr/src/uts/intel/zfs/spa_boot.c index a6cdb81890..adbcffaef0 100644 --- a/usr/src/uts/intel/zfs/spa_boot.c +++ b/usr/src/uts/intel/zfs/spa_boot.c @@ -24,9 +24,16 @@ * Use is subject to license terms. */ +/* + * Copyright (c) 2012 by Delphix. All rights reserved. + */ + #include <sys/zio.h> #include <sys/spa.h> #include <sys/sunddi.h> +#include <sys/x86_archext.h> + +extern int zfs_deadman_enabled; char * spa_get_bootprop(char *propname) @@ -44,3 +51,21 @@ spa_free_bootprop(char *value) { ddi_prop_free(value); } + +void +spa_arch_init(void) +{ + /* + * Configure the default settings for the zfs deadman unless + * overriden by /etc/system. + */ + if (zfs_deadman_enabled == -1) { + /* + * Disable the zfs deadman logic on VMware deployments. + */ + if (get_hwenv() == HW_VMWARE) + zfs_deadman_enabled = 0; + else + zfs_deadman_enabled = 1; + } +} |