From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2B9F2C77B7A for ; Tue, 16 May 2023 19:25:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229756AbjEPTZA (ORCPT ); Tue, 16 May 2023 15:25:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49946 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229764AbjEPTYu (ORCPT ); Tue, 16 May 2023 15:24:50 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AE26A86BD for ; Tue, 16 May 2023 12:24:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=18irUwydotXRePLu/J5DGPoXDnh6CdjdyHmv2dIgPhA=; b=f6f+/5h9YDMqbVc3sEKT02jLDv XwYuG05KyT3JPaDAAoQqDoXsKSXbrBcjhqgB4tOiKCBccSa08EWJF68HG/LFGIMDFi+hr9Tyw2cxz JRLKCawcqb8DoM7MeW0+PrGZYl/BbUC7OGrZAlH/CslxGlcFTUJXQnEeIcGVLlOpF9+EbBXohJ+yF XnsTpGCaLOcOmDEJOYp72RyOd2xBm+I4etyD7WHIAV27x9esZUS04S0gZ1/ZlnXnFFCYke67ezxNc /VmKz6R7+wA/qWu0Xpmq9sa40NjRZk7MkI7Jt4/sMByTJCXrWpb4Z1kzrGsVmzuIgHt76U3XhsVJK SSiYBBMw==; Received: from willy by casper.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1pz0HE-004ULm-Mq; Tue, 16 May 2023 19:24:04 +0000 Date: Tue, 16 May 2023 20:24:04 +0100 From: Matthew Wilcox To: Wander Lairson Costa Cc: Oleg Nesterov , "Russell King (Oracle)" , Brian Cain , Michael Ellerman , Stafford Horne , Kefeng Wang , Andrew Morton , "Liam R. Howlett" , Vlastimil Babka , "Eric W. Biederman" , Andrei Vagin , Peter Zijlstra , "Paul E. McKenney" , Daniel Bristot de Oliveira , Yu Zhao , Alexey Gladkov , Mike Kravetz , Yang Shi , open list , Hu Chunyu , Valentin Schneider , Sebastian Andrzej Siewior , Steven Rostedt , Luis Goncalves Subject: Re: [PATCH v9] kernel/fork: beware of __put_task_struct calling context Message-ID: References: <20230516191441.34377-1-wander@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230516191441.34377-1-wander@redhat.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, May 16, 2023 at 04:14:41PM -0300, Wander Lairson Costa wrote: > +void __put_task_struct_rcu_cb(struct rcu_head *rhp) > +{ > + struct task_struct *task = container_of(rhp, struct task_struct, rcu); > + > + __put_task_struct(task); > +} > +EXPORT_SYMBOL_GPL(__put_task_struct_rcu_cb); Why does this need to be exported when its only caller is within the main kernel and cannot possibly be built as a module?