+ if (base == 0) {
+ /*
+ * Avoid having to deal with the edge case of the
+ * very first possible physical page and the roll-over
+ * to -1; just ignore that page.
+ */
+ kprintf("WARNING: ignoring first page in [0x%llx:0x%llx]\n", (uint64_t) base, (uint64_t) top);
+ base++;
+ }
+ if (top + 1 == 0) {
+ /*
+ * Avoid having to deal with the edge case of the
+ * very last possible physical page and the roll-over
+ * to 0; just ignore that page.
+ */
+ kprintf("WARNING: ignoring last page in [0x%llx:0x%llx]\n", (uint64_t) base, (uint64_t) top);
+ top--;
+ }
+ if (top < base) {
+ /*
+ * That was the only page in that region, so
+ * ignore the whole region.
+ */
+ continue;
+ }
+