Re: [PATCH] tcp: use kvmalloc_array() to allocate table_perturb

From: Eric Dumazet
Date: Mon Jun 06 2022 - 12:13:57 EST


On Mon, Jun 6, 2022 at 9:05 AM Eric Dumazet <edumazet@xxxxxxxxxx> wrote:
>
> On Mon, Jun 6, 2022 at 12:08 AM Muchun Song <songmuchun@xxxxxxxxxxxxx> wrote:
> >
> > In our server, there may be no high order (>= 6) memory since we reserve
> > lots of HugeTLB pages when booting. Then the system panic. So use
> > kvmalloc_array() to allocate table_perturb.
> >
> > Signed-off-by: Muchun Song <songmuchun@xxxxxxxxxxxxx>
>
> Please add a Fixes: tag and CC original author ?
>
> Thanks.

Also using alloc_large_system_hash() might be a better option anyway,
spreading pages on multiple nodes on NUMA hosts.