]> granicus.if.org Git - spl/commitdiff
Added btop() and moved ptob() to include/sys/param.h.
authorRicardo M. Correia <Ricardo.M.Correia@Sun.COM>
Sun, 22 Feb 2009 03:05:40 +0000 (03:05 +0000)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Wed, 25 Feb 2009 23:50:50 +0000 (15:50 -0800)
include/sys/param.h
include/sys/vmsystm.h

index f924006efa56e34451eceb3a40920b64a68eb9d9..d6b4f761f3fe64d0f12322a7481cb8deeb2beb52 100644 (file)
@@ -1,4 +1,8 @@
 #ifndef _SPL_PARAM_H
 #define _SPL_PARAM_H
 
+/* Pages to bytes and back */
+#define ptob(pages)                    (pages * PAGE_SIZE)
+#define btop(bytes)                    (bytes / PAGE_SIZE)
+
 #endif /* SPL_PARAM_H */
index 75ae8a9914d788704864d5a83ab9a64c5fc03d29..c75d447d942d30abacf781f5618db5d9526123d7 100644 (file)
@@ -40,7 +40,6 @@
  * memory state and not as direct evidence that page reclaimation
  * is or is not currently in progress.
  */
-#define ptob(pages)                    (pages * PAGE_SIZE)
 #define membar_producer()              smp_wmb()
 
 #define physmem                                num_physpages