lkml.org 
[lkml]   [2020]   [Nov]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH v9 10/44] kasan: define KASAN_GRANULE_PAGE
On Wed, Nov 11, 2020 at 8:05 PM Marco Elver <elver@google.com> wrote:
>
> On Wed, 11 Nov 2020 at 19:48, Andrey Konovalov <andreyknvl@google.com> wrote:
> >
> > On Wed, Nov 11, 2020 at 3:13 PM Alexander Potapenko <glider@google.com> wrote:
> > >
> > > On Tue, Nov 10, 2020 at 11:11 PM Andrey Konovalov <andreyknvl@google.com> wrote:
> > > >
> > > > Define KASAN_GRANULE_PAGE as (KASAN_GRANULE_SIZE << PAGE_SHIFT), which is
> > > > the same as (KASAN_GRANULE_SIZE * PAGE_SIZE), and use it across KASAN code
> > > > to simplify it.
> > >
> > > What's the physical sense behind KASAN_GRANULE_PAGE? Is it something
> > > more than just a product of two constants?
> >
> > No, just a product.
> >
> > > The name suggests it might be something page-sized, but in reality it is not.
> >
> > What name would you prefer?
>
> Is it actually KASAN_GRANULES_PER_SHADOW_PAGE ? AFAIK we're trying
> to calculate the granules that we can fit into a page of shadow
> memory.

Not exactly, it's the amount of memory, not the number of granules.

Will name it KASAN_MEMORY_PER_SHADOW_PAGE in v10.

\
 
 \ /
  Last update: 2020-11-12 02:37    [W:0.082 / U:0.256 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site