| 447 | void pagedaemon_wakeup(int domain); |
| 448 | |
| 449 | static inline void |
| 450 | vm_domain_freecnt_inc(struct vm_domain *vmd, int adj) |
| 451 | { |
| 452 | u_int old, new; |
| 453 | |
| 454 | old = atomic_fetchadd_int(&vmd->vmd_free_count, adj); |
| 455 | new = old + adj; |
| 456 | /* |
| 457 | * Only update bitsets on transitions. Notice we short-circuit the |
| 458 | * rest of the checks if we're above min already. |
| 459 | */ |
| 460 | if (old < vmd->vmd_free_min && (new >= vmd->vmd_free_min || |
| 461 | (old < vmd->vmd_free_severe && new >= vmd->vmd_free_severe) || |
| 462 | (old < vmd->vmd_pageout_free_min && |
| 463 | new >= vmd->vmd_pageout_free_min))) |
| 464 | vm_domain_clear(vmd); |
| 465 | } |
| 466 | |
| 467 | #endif /* _KERNEL */ |
| 468 | #endif /* !_VM_PAGEQUEUE_ */ |
no test coverage detected