From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755137AbcA1N3q (ORCPT ); Thu, 28 Jan 2016 08:29:46 -0500 Received: from mail-wm0-f44.google.com ([74.125.82.44]:37433 "EHLO mail-wm0-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751400AbcA1N3o convert rfc822-to-8bit (ORCPT ); Thu, 28 Jan 2016 08:29:44 -0500 MIME-Version: 1.0 In-Reply-To: References: <7f497e194053c25e8a3debe3e1e738a187e38c16.1453918525.git.glider@google.com> <20160128074442.GB15426@js1304-P5Q-DELUXE> Date: Thu, 28 Jan 2016 14:29:42 +0100 Message-ID: Subject: Re: [PATCH v1 2/8] mm, kasan: SLAB support From: Alexander Potapenko To: Joonsoo Kim Cc: kasan-dev@googlegroups.com, Christoph Lameter , linux-kernel@vger.kernel.org, Dmitriy Vyukov , Andrey Ryabinin , linux-mm@kvack.org, Andrey Konovalov , Andrew Morton , rostedt@goodmis.org Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8BIT Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jan 28, 2016 at 1:37 PM, Alexander Potapenko wrote: > > On Jan 28, 2016 8:44 AM, "Joonsoo Kim" wrote: >> >> On Wed, Jan 27, 2016 at 07:25:07PM +0100, Alexander Potapenko wrote: >> > This patch adds KASAN hooks to SLAB allocator. >> > >> > This patch is based on the "mm: kasan: unified support for SLUB and >> > SLAB allocators" patch originally prepared by Dmitry Chernenkov. >> > >> > Signed-off-by: Alexander Potapenko >> > --- >> > Documentation/kasan.txt | 5 ++- >> >> ... >> >> > +#ifdef CONFIG_SLAB >> > +struct kasan_alloc_meta *get_alloc_info(struct kmem_cache *cache, >> > + const void *object) >> > +{ >> > + return (void *)object + cache->kasan_info.alloc_meta_offset; >> > +} >> > + >> > +struct kasan_free_meta *get_free_info(struct kmem_cache *cache, >> > + const void *object) >> > +{ >> > + return (void *)object + cache->kasan_info.free_meta_offset; >> > +} >> > +#endif >> >> I cannot find the place to store stack info for free. get_free_info() >> isn't used except print_object(). Plese let me know where. > > This is covered by other patches in this patchset. > >> Thanks. (resending to linux-kernel@ because the previous mail bounced) -- Alexander Potapenko Software Engineer Google Germany GmbH Erika-Mann-Straße, 33 80636 München Geschäftsführer: Matthew Scott Sucherman, Paul Terence Manicle Registergericht und -nummer: Hamburg, HRB 86891 Sitz der Gesellschaft: Hamburg Diese E-Mail ist vertraulich. Wenn Sie nicht der richtige Adressat sind, leiten Sie diese bitte nicht weiter, informieren Sie den Absender und löschen Sie die E-Mail und alle Anhänge. Vielen Dank. This e-mail is confidential. If you are not the right addressee please do not forward it, please inform the sender, and please erase this e-mail including any attachments. Thanks.