Re: [PATCH v2 0/2] net: Optimize the qed* allocations inside kdump kernel

From: David Miller
Date: Mon May 11 2020 - 16:25:35 EST


From: Bhupesh Sharma <bhsharma@xxxxxxxxxx>
Date: Mon, 11 May 2020 15:41:40 +0530

...
> Since kdump kernel(s) run under severe memory constraint with the
> basic idea being to save the crashdump vmcore reliably when the primary
> kernel panics/hangs, large memory allocations done by a network driver
> can cause the crashkernel to panic with OOM.
>
> The qed* drivers take up approximately 214MB memory when run in the
> kdump kernel with the default configuration settings presently used in
> the driver. With an usual crashkernel size of 512M, this allocation
> is equal to almost half of the total crashkernel size allocated.
>
> See some logs obtained via memstrack tool (see [1]) below:
> dracut-pre-pivot[676]: ======== Report format module_summary: ========
> dracut-pre-pivot[676]: Module qed using 149.6MB (2394 pages), peak allocation 149.6MB (2394 pages)
> dracut-pre-pivot[676]: Module qede using 65.3MB (1045 pages), peak allocation 65.3MB (1045 pages)
>
> This patchset tries to reduce the overall memory allocation profile of
> the qed* driver when they run in the kdump kernel. With these
> optimization we can see a saving of approx 85M in the kdump kernel:
> dracut-pre-pivot[671]: ======== Report format module_summary: ========
> dracut-pre-pivot[671]: Module qed using 124.6MB (1993 pages), peak allocation 124.7MB (1995 pages)
> <..snip..>
> dracut-pre-pivot[671]: Module qede using 4.6MB (73 pages), peak allocation 4.6MB (74 pages)
...

Series applied to net-next, thanks.