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] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAG48ez2DUgxh3f4N=i60TfHBSTbh2HPMbA8DcBo2g7HSepnzzg@mail.gmail.com>
Date: Tue, 13 Aug 2024 16:35:07 +0200
From: Jann Horn <jannh@...gle.com>
To: Shinichiro Kawasaki <shinichiro.kawasaki@....com>
Cc: Andrey Ryabinin <ryabinin.a.a@...il.com>, Alexander Potapenko <glider@...gle.com>, 
	Andrey Konovalov <andreyknvl@...il.com>, Dmitry Vyukov <dvyukov@...gle.com>, 
	Vincenzo Frascino <vincenzo.frascino@....com>, Andrew Morton <akpm@...ux-foundation.org>, 
	Christoph Lameter <cl@...ux.com>, Pekka Enberg <penberg@...nel.org>, David Rientjes <rientjes@...gle.com>, 
	Joonsoo Kim <iamjoonsoo.kim@....com>, Vlastimil Babka <vbabka@...e.cz>, 
	Roman Gushchin <roman.gushchin@...ux.dev>, Hyeonggon Yoo <42.hyeyoo@...il.com>, 
	Marco Elver <elver@...gle.com>, 
	"kasan-dev@...glegroups.com" <kasan-dev@...glegroups.com>, 
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>, "linux-mm@...ck.org" <linux-mm@...ck.org>, 
	David Sterba <dsterba@...e.cz>, 
	"syzbot+263726e59eab6b442723@...kaller.appspotmail.com" <syzbot+263726e59eab6b442723@...kaller.appspotmail.com>
Subject: Re: [PATCH v8 2/2] slub: Introduce CONFIG_SLUB_RCU_DEBUG

Hi!

On Tue, Aug 13, 2024 at 11:03 AM Shinichiro Kawasaki
<shinichiro.kawasaki@....com> wrote:
> Hello Jann, let me ask a question about this patch. When I tested the
> next-20240808 kernel which includes this patch, I observed that
> slab_free_after_rcu_debug() reports many WARNs. Please find my question in line.

Thanks for testing linux-next.

> On Aug 09, 2024 / 17:36, Jann Horn wrote:
[...]
> > +#ifdef CONFIG_SLUB_RCU_DEBUG
> > +static void slab_free_after_rcu_debug(struct rcu_head *rcu_head)
> > +{
> > +     struct rcu_delayed_free *delayed_free =
> > +                     container_of(rcu_head, struct rcu_delayed_free, head);
> > +     void *object = delayed_free->object;
> > +     struct slab *slab = virt_to_slab(object);
> > +     struct kmem_cache *s;
> > +
> > +     kfree(delayed_free);
> > +
> > +     if (WARN_ON(is_kfence_address(object)))
> > +             return;
>
> With the kernel configs above, I see the many WARNs are reported here.
> When SLUB_RCU_DEBUG is enabled, should I disable KFENCE?

These features are supposed to be compatible.

In the version you tested
(https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next-history.git/tree/mm/slub.c?h=next-20240808#n4550),
I made a mistake and wrote "if (WARN_ON(is_kfence_address(rcu_head)))"
instead of "if (WARN_ON(is_kfence_address(object)))". That issue was
fixed in v6 of the series after syzbot and the Intel test bot ran into
the same issue.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ