* Return the largest possible order of a set of pages starting at m. */
| 1124 | * Return the largest possible order of a set of pages starting at m. |
| 1125 | */ |
| 1126 | static int |
| 1127 | max_order(vm_page_t m) |
| 1128 | { |
| 1129 | |
| 1130 | /* |
| 1131 | * Unsigned "min" is used here so that "order" is assigned |
| 1132 | * "VM_NFREEORDER - 1" when "m"'s physical address is zero |
| 1133 | * or the low-order bits of its physical address are zero |
| 1134 | * because the size of a physical address exceeds the size of |
| 1135 | * a long. |
| 1136 | */ |
| 1137 | return (min(ffsl(VM_PAGE_TO_PHYS(m) >> PAGE_SHIFT) - 1, |
| 1138 | VM_NFREEORDER - 1)); |
| 1139 | } |
| 1140 | |
| 1141 | /* |
| 1142 | * Free a contiguous, arbitrarily sized set of physical pages, without |
no test coverage detected