Re: [PATCH v2 7/8] x86/kaslr: Clean up slot handling

2020-07-28 Thread Arvind Sankar
On Tue, Jul 28, 2020 at 12:34:45PM -0700, Kees Cook wrote: > On Mon, Jul 27, 2020 at 07:08:00PM -0400, Arvind Sankar wrote: > > The number of slots and slot areas can be unsigned int, since on 64-bit, > > the maximum amount of memory is 2^52, the minimum alignment is 2^21, so > > the slot number ca

Re: [PATCH v2 7/8] x86/kaslr: Clean up slot handling

2020-07-28 Thread Kees Cook
On Mon, Jul 27, 2020 at 07:08:00PM -0400, Arvind Sankar wrote: > The number of slots and slot areas can be unsigned int, since on 64-bit, > the maximum amount of memory is 2^52, the minimum alignment is 2^21, so > the slot number cannot be greater than 2^31. The slot areas are limited > by MAX_SLOT

[PATCH v2 7/8] x86/kaslr: Clean up slot handling

2020-07-27 Thread Arvind Sankar
The number of slots and slot areas can be unsigned int, since on 64-bit, the maximum amount of memory is 2^52, the minimum alignment is 2^21, so the slot number cannot be greater than 2^31. The slot areas are limited by MAX_SLOT_AREA, currently 100. Replace the type used for slot number, which is c