Re: [PATCH 6/8] x86/kaslr: Simplify process_gb_huge_pages

From: Ingo Molnar
Date: Tue Jul 28 2020 - 06:58:27 EST



* Arvind Sankar <nivedita@xxxxxxxxxxxx> wrote:

> Short-circuit the whole function on 32-bit.
>
> Replace the loop to determine the number of 1Gb pages with arithmetic.
>
> Fix one minor bug: if the end of the region is aligned on a 1Gb
> boundary, the current code will not use the last available 1Gb page due
> to an off-by-one error.

Please split this up into two patches: first the minor bugfix, and
then the cleanup which will then be an invariant patch, in principle.

Thanks,

Ingo