Lines Matching defs:kswapd

8  *  kswapd added: 7.1.96  sct
11 * Zone aware kswapd started 02/00, Kanoj Sarcar (kanoj@sgi.com).
1059 * reclaim_congested which affects wait_iff_congested. kswapd
1258 * Only kswapd can writeback filesystem pages
2435 * reclaiming implies that kswapd is not keeping up and it is best to
2465 * For kswapd and memcg, reclaim at least the number of pages
2787 * Once a node is flagged PGDAT_WRITEBACK, kswapd will
2795 /* Allow kswapd to start writing pages during reclaim.*/
2800 * If kswapd scans pages marked for immediate
2824 * and node is congested. Allow kswapd to continue until it
2841 * successful direct reclaim run will revive a dormant kswapd.
3130 /* kswapd must be awake if processes are being throttled */
3144 * depleted. kswapd will continue to make progress and wake the processes
3181 * wait on a queue until kswapd makes progress and wakes them. There
3211 * it is not safe to block on pfmemalloc_wait as kswapd could be
3222 /* Throttle until kswapd wakes the process */
3445 * allocation tries to wake a remote kswapd.
3464 * Prepare kswapd for sleeping. This verifies that there are no processes
3467 * Returns true if kswapd is ready to sleep
3475 * race between when kswapd checks the watermarks and a process gets
3477 * throttled, kswapd wakes, a large process exits thereby balancing the
3478 * zones, which causes kswapd to exit balance_pgdat() before reaching
3479 * the wake up checks. If kswapd is going to sleep, no process should
3481 * the wake up is premature, processes will wake kswapd and get
3501 * kswapd shrinks a node of pages that are at or below the highest usable
3504 * Returns true if kswapd scanned at least the requested number of pages to
3548 * For kswapd, balance_pgdat() will reclaim pages across a node from zones
3552 * Returns the order kswapd finished reclaiming at.
3554 * kswapd scans the zones in the highmem->normal->dma direction. It skips
3585 * stall or direct reclaim until kswapd is finished.
3616 * request are balanced to avoid excessive reclaim from kswapd.
3634 * re-evaluate if boosting is required when kswapd next wakes.
3702 /* Check if kswapd should be suspending */
3760 * Return the order kswapd stopped reclaiming at as
3762 * entered the allocator slow path while kswapd was awake, order will
3770 * be reclaimed by kswapd from the waker. If the value is MAX_NR_ZONES which is
3771 * not a valid index then either kswapd runs for first time or kswapd couldn't
3773 * case return the zone index of the previous kswapd reclaim cycle.
3805 * When kswapd is going to sleep, it is reasonable to assume
3849 * per-cpu vmstat threshold while kswapd is awake and restore
3880 static int kswapd(void *p)
3897 * regardless (see "__alloc_pages()"). "kswapd" should
3942 * reclaim fails then kswapd falls back to reclaiming for
3943 * order-0. If that happens, kswapd will consider sleeping
3972 * kswapd should reclaim (direct reclaim is deferred), wake it up for the zone's
3973 * pgdat. It will wake up kcompactd after reclaiming memory. If kswapd reclaim
4062 * This kswapd start function will be called by init and node-hot-add.
4063 * On node-hot-add, kswapd will moved to proper cpus if cpus are hot-added.
4070 if (pgdat->kswapd)
4073 pgdat->kswapd = kthread_run(kswapd, pgdat, "kswapd%d", nid);
4074 if (IS_ERR(pgdat->kswapd)) {
4077 pr_err("Failed to start kswapd on node %d\n", nid);
4078 ret = PTR_ERR(pgdat->kswapd);
4079 pgdat->kswapd = NULL;
4090 struct task_struct *kswapd = NODE_DATA(nid)->kswapd;
4092 if (kswapd) {
4093 kthread_stop(kswapd);
4094 NODE_DATA(nid)->kswapd = NULL;