lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20230621141850.GE2934656@google.com>
Date:   Wed, 21 Jun 2023 23:18:50 +0900
From:   Sergey Senozhatsky <senozhatsky@...omium.org>
To:     Alexey Romanov <AVRomanov@...rdevices.ru>,
        Minchan Kim <minchan@...nel.org>
Cc:     Sergey Senozhatsky <senozhatsky@...omium.org>,
        "akpm@...ux-foundation.org" <akpm@...ux-foundation.org>,
        "linux-mm@...ck.org" <linux-mm@...ck.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        kernel <kernel@...rdevices.ru>
Subject: Re: [PATCH v1 1/2] zsmalloc: add allocated objects counter for
 subpage

On (23/06/21 13:59), Alexey Romanov wrote:
> On Wed, Jun 21, 2023 at 10:55:18PM +0900, Sergey Senozhatsky wrote:
> > On (23/06/21 13:41), Alexey Romanov wrote:
> > [..]
> > > > +static bool zspage_empty(struct zspage *zspage)
> > > > +{
> > > > +	return get_zspage_inuse(zspage) == 0;
> > > > +}
> > > > +
> > > >  /**
> > > >   * zs_lookup_class_index() - Returns index of the zsmalloc &size_class
> > > >   * that hold objects of the provided size.
> > > > @@ -1787,6 +1792,10 @@ static void migrate_zspage(struct zs_pool *pool, struct size_class *class,
> > > >  		obj_idx++;
> > > >  		record_obj(handle, free_obj);
> > > >  		obj_free(class->size, used_obj, NULL);
> > > > +
> > > > +		/* Stop if there are no more objects to migrate */
> > > > +		if (zspage_empty(get_zspage(s_page)))
> > > > +			break;
> > > >  	}
> > > 
> > > Yes it seems my version is not as good as I thought. Looks bad for an
> > > architecturally dependent PAGE_SIZE. [..]
> > 
> > Well, we are looking for a solution that is both reasonable (perf wise)
> > and is maintainable.
> > 
> > > I can implement this option. I'll test this and send patch this week.
> > 
> > Either that or, if Suggested-by: Alexey Romanov <AVRomanov@...rdevices.ru>
> > is good enough for you, then I can send a series tonight or tomorrow (after
> > some testing). I have two more patches on top of that one.
> 
> Yeah, Suggested-by is OK. Let's send a patch. Thank you.

Got it.

Let's hear from Minchan first, just to make sure that Minchan is OK
with that.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ