diff options
author | David S. Miller <davem@davemloft.net> | 2020-05-15 23:48:59 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-05-15 23:48:59 +0300 |
commit | da07f52d3caf6c24c6dbffb5500f379d819e04bd (patch) | |
tree | 836e51994554f1aeddeebb6cb6ee568944a467e7 /mm/page_alloc.c | |
parent | 93d43e58683efd958a0421b932a273df74e0e008 (diff) | |
parent | f85c1598ddfe83f61d0656bd1d2025fa3b148b99 (diff) | |
download | linux-da07f52d3caf6c24c6dbffb5500f379d819e04bd.tar.xz |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
Move the bpf verifier trace check into the new switch statement in
HEAD.
Resolve the overlapping changes in hinic, where bug fixes overlap
the addition of VF support.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'mm/page_alloc.c')
-rw-r--r-- | mm/page_alloc.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/mm/page_alloc.c b/mm/page_alloc.c index 0c43e9ae5004..b7e1b76284f9 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c @@ -1607,6 +1607,7 @@ void set_zone_contiguous(struct zone *zone) if (!__pageblock_pfn_to_page(block_start_pfn, block_end_pfn, zone)) return; + cond_resched(); } /* We confirm that there is no hole */ @@ -2400,6 +2401,14 @@ static inline void boost_watermark(struct zone *zone) if (!watermark_boost_factor) return; + /* + * Don't bother in zones that are unlikely to produce results. + * On small machines, including kdump capture kernels running + * in a small area, boosting the watermark can cause an out of + * memory situation immediately. + */ + if ((pageblock_nr_pages * 4) > zone_managed_pages(zone)) + return; max_boost = mult_frac(zone->_watermark[WMARK_HIGH], watermark_boost_factor, 10000); |