Print this page
re #13613 rb4516 Tunables needs volatile keyword

@@ -21,10 +21,13 @@
 /*
  * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  * Use is subject to license terms.
  * Copyright 2011 Joyent, Inc.  All rights reserved.
  */
+/*
+ * Copyright 2013 Nexenta Systems, Inc.  All rights reserved.
+ */
 
 /*
  * Copyright (c) 2016 by Delphix. All rights reserved.
  */
 

@@ -159,12 +162,12 @@
 
 /* Flags for bio_recycle() */
 #define BIO_HEADER      0x01
 #define BIO_MEM         0x02
 
-extern  int bufhwm;             /* User tunable - high water mark for mem  */
-extern  int bufhwm_pct;         /* ditto - given in % of physmem  */
+extern volatile int bufhwm;     /* User tunable - high water mark for mem  */
+extern volatile int bufhwm_pct; /* ditto - given in % of physmem  */
 
 /*
  * The following routines allocate and free
  * buffers with various side effects.  In general the
  * arguments to an allocate routine are a device and