Received: by 2002:a05:6602:2086:0:0:0:0 with SMTP id a6csp4177506ioa; Tue, 26 Apr 2022 19:45:28 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxwbHNzytM4k1JFCyVTFIlb1Gn+vx0o2D1M+e8kzyrk6OctSJFuBQXeux1V5eBgeEAiJV8J X-Received: by 2002:a17:902:d4cc:b0:15d:5246:e4de with SMTP id o12-20020a170902d4cc00b0015d5246e4demr1070904plg.68.1651027528683; Tue, 26 Apr 2022 19:45:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1651027528; cv=none; d=google.com; s=arc-20160816; b=EtgVgMEb74VxsfpGB0hLBRqSlCVzO3ZQWlkUOxBfzPblr9jqGQGMLzGxtjeQkAEaQB XMlmX0Jxj95X8hEMIFI34VZUzrtm4kw2XPvNn90/Zx3scOF247aaGulwu37FJuXwlTBp Z3WVeuCAf7CutgygfWNl8T9mPbXxrNoz3TAXHSRNXKp0UVl8wdSM7f7Xi0MsPTCr87ld wZ2ReeIKuMeE4CHy8zSIlBv48vYYq+3jWKuZJxgF5S4nUOyo7qQXnTQnMfFiF62jRDE5 DqtU5Rvg6v181WiT1v8m6BIJWg6W2Tkq3pA3cmBVD9W0ECJVg3xWSPjE8g7wFXo646v/ g6Ow== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature:dkim-signature; bh=8wMRNEkRXBcwjzWPrzRFYMfY+IW7Tel+Il+dGf7fXs8=; b=pERGYKuMchQvlt1zrzOHwsRX35CenmKRhNT7ntFrygKq21cA099IPdmoZPcVxbEOhv PB84NSv+VqR/09aADozpNpBK3sIqBjdc3sYeBG+iPYaQatVysNFM17QCQEMYx9MS19C9 aYw/JuhiVRnZvTf+amweWt5gLbxyd6TaCjR4mgoUNK/oCHKXe499OAICufq434reVZy/ W8u7iHoq0Wt3IsOPx4vJif6vRi2DYQaClUz4zbpVevjWonKPCZgr4aMvMf6F2uySjPe9 +XKcI0cWsBkBjuzX8OmVwDU/T8BnlxZEw/mK7xoTGBfrf+xDN2xpzkU0csbhIHco6LOu Yvlw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=DknrYBFW; dkim=neutral (no key) header.i=@suse.cz; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k4-20020a056a00134400b004fe215ae62bsi145593pfu.67.2022.04.26.19.45.13; Tue, 26 Apr 2022 19:45:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=DknrYBFW; dkim=neutral (no key) header.i=@suse.cz; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1352527AbiDZPwT (ORCPT + 99 others); Tue, 26 Apr 2022 11:52:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48446 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1348927AbiDZPwS (ORCPT ); Tue, 26 Apr 2022 11:52:18 -0400 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 696A91353B8 for ; Tue, 26 Apr 2022 08:49:10 -0700 (PDT) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 0B51F1F38D; Tue, 26 Apr 2022 15:49:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1650988149; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=8wMRNEkRXBcwjzWPrzRFYMfY+IW7Tel+Il+dGf7fXs8=; b=DknrYBFWIY1jQuF+BTp/oNZkmwnJC5H5Os2A5VpXk0TRor8m4ey41YtnaDEhqCxkWkCHD9 +AjW5TQm265xVSU5vWVuC03NTA1EtDuc7wn7McHG1NKUNX/kRvWxR/deIme0jMdMpKkdG2 ZtjQhzYiiweHOcjODqXIegU6zkmiBpo= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1650988149; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=8wMRNEkRXBcwjzWPrzRFYMfY+IW7Tel+Il+dGf7fXs8=; b=etdjeOWkhdYJtzAhO6Rwnz9kba5tpfQKl62Z29KYv/hzEq+KcZ2QFaCtLhS3+LAg4j7jKD 33iNNRvSyk1gLUAg== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id D7CD313AD5; Tue, 26 Apr 2022 15:49:08 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id tAoPNHQUaGJKcAAAMHmgww (envelope-from ); Tue, 26 Apr 2022 15:49:08 +0000 Message-ID: Date: Tue, 26 Apr 2022 17:49:08 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.7.0 Subject: Re: [PATCH v2 04/23] mm/slab_common: cleanup kmalloc_track_caller() Content-Language: en-US To: Hyeonggon Yoo <42.hyeyoo@gmail.com> Cc: Marco Elver , Matthew WilCox , Christoph Lameter , Pekka Enberg , David Rientjes , Joonsoo Kim , Andrew Morton , Roman Gushchin , linux-mm@kvack.org, linux-kernel@vger.kernel.org References: <20220414085727.643099-1-42.hyeyoo@gmail.com> <20220414085727.643099-5-42.hyeyoo@gmail.com> From: Vlastimil Babka In-Reply-To: <20220414085727.643099-5-42.hyeyoo@gmail.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-6.3 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 4/14/22 10:57, Hyeonggon Yoo wrote: > Make kmalloc_track_caller() wrapper of kmalloc_node_track_caller(). > > Signed-off-by: Hyeonggon Yoo <42.hyeyoo@gmail.com> > --- > include/linux/slab.h | 17 ++++++++--------- > mm/slab.c | 6 ------ > mm/slob.c | 6 ------ > mm/slub.c | 22 ---------------------- > 4 files changed, 8 insertions(+), 43 deletions(-) > > diff --git a/include/linux/slab.h b/include/linux/slab.h > index a3b9d4c20d7e..acdb4b7428f9 100644 > --- a/include/linux/slab.h > +++ b/include/linux/slab.h > @@ -639,6 +639,12 @@ static inline __alloc_size(1, 2) void *kcalloc(size_t n, size_t size, gfp_t flag > return kmalloc_array(n, size, flags | __GFP_ZERO); > } > > +extern void *__kmalloc_node_track_caller(size_t size, gfp_t flags, int node, > + unsigned long caller) __alloc_size(1); Update: in v3 remove the extern, it's not necessary and the kernel is slowly getting rid of them.