This doesn't work ;)
kswapd have to clear ZONE_CONGESTED flag before enter sleeping.
otherwise nobody can clear it.
Say, we have to fill below condition.
- All zone are successing zone_watermark_ok(order-0)
- At least one zone are successing zone_watermark_ok(high-order)
I don't think MAX_ORDER is correct ;)
high_zoneidx = pgdat->high_zoneidx;
pgdat->high_zoneidx = pgdat->nr_zones - 1;
And, we have another kswapd_max_order reading place. (after kswapd_try_to_sleep)
We need it too.