+/* Allocates and return A times B bytes initialized to zeroes.
+ Panics if memory is not available. It is unacceptable for the
+ kernel to panic in normal operation, so this function should
+ only be used during kernel initialization. */
+void *
+xcalloc (size_t a, size_t b)
+{
+ void *p = calloc (a, b);
+ if (p == NULL && a > 0 && b > 0)
+ PANIC ("memory exhausted");
+ return p;
+}
+