From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 96C2A1FECB0; Wed, 8 Jan 2025 15:43:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736351039; cv=none; b=nsJwqVmJaQ0nbVg0QJfbnFXlbVzVvrOP0dzHfNWVR1DHIiFWAe4duIc83YeeyLyGgRkrvMdJloxOtEo2aJjWwDztqFJ+tHMnSkw2oWgsNwi5tpeuEv75vCAVEbT/aRlQv/lpND+Tjb8tGVbBzdHsBmI4p8xmljr14aXDrDq/MUs= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736351039; c=relaxed/simple; bh=iAQ4x0/oizKfpSM1ZOfEKhrwcrgnRVCuoCpheJdwODk=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=dI3W3eYENF+u8wj8PdcPuCB2DujFGq7VXxKAGbR3qQx9aZftFzSc86dyjUN/IZBkgTCC1Uso8UgAOM5mdFnKY1RwnTloS9bLKdr3j1D1cgSe5YG33eWvDW8FMCP1MmHoNw79j2Mp0BAXRq0hh+QXDlCexkwfoXX/9CJc5aNYbdg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=cPJm0Ekh; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="cPJm0Ekh" Received: by smtp.kernel.org (Postfix) with ESMTPSA id C0593C4CED3; Wed, 8 Jan 2025 15:43:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1736351039; bh=iAQ4x0/oizKfpSM1ZOfEKhrwcrgnRVCuoCpheJdwODk=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=cPJm0EkhpbVJZIRwKv38+KZr4RI6JAKZRMgSJAUilwa/dgEkob3GpPO+TLNtRiZCT DEWJDBRDzGsOiVUJ+Ljb7+Zn631cx7upT+JgUKWUOxWPdyfc0Rv/VXd92XMheafcRO HwTLae87NP1aV9jSsgjH8i80uyHv2fYQqRxRTS+9d/osRLJHpv7Z+BDIRhOLlXadBp ZyTfw0YbeI9/Tk1NMDXKp+ISKT72FLunUeqjvZM2LA81L2wBEkbl0Wz1SR/Zrf3sG0 DbpdPhUNKkmhlmzyHl1UUxz72wsi01z2Ht4x5xPDXSJRrWhFFXhn0nULlTfoL308Ir jxj7j8IS15+bA== Date: Wed, 8 Jan 2025 15:43:48 +0000 From: Daniel Thompson To: Mike Rapoport Cc: Andrew Morton , Andy Lutomirski , Anton Ivanov , Borislav Petkov , Brendan Higgins , Daniel Gomez , Dave Hansen , David Gow , Douglas Anderson , Ingo Molnar , Jason Wessel , Jiri Kosina , Joe Lawrence , Johannes Berg , Josh Poimboeuf , "Kirill A. Shutemov" , Luis Chamberlain , Mark Rutland , Masami Hiramatsu , Miroslav Benes , "H. Peter Anvin" , Peter Zijlstra , Petr Mladek , Petr Pavlu , Rae Moar , Richard Weinberger , Sami Tolvanen , Shuah Khan , Song Liu , Steven Rostedt , Thomas Gleixner , kgdb-bugreport@lists.sourceforge.net, kunit-dev@googlegroups.com, linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, linux-mm@kvack.org, linux-modules@vger.kernel.org, linux-trace-kernel@vger.kernel.org, linux-um@lists.infradead.org, live-patching@vger.kernel.org, x86@kernel.org Subject: Re: [PATCH 5/8] module: introduce MODULE_STATE_GONE Message-ID: References: <20241227072825.1288491-1-rppt@kernel.org> <20241227072825.1288491-6-rppt@kernel.org> Precedence: bulk X-Mailing-List: linux-trace-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20241227072825.1288491-6-rppt@kernel.org> On Fri, Dec 27, 2024 at 09:28:22AM +0200, Mike Rapoport wrote: > From: "Mike Rapoport (Microsoft)" > > In order to use execmem's API for temporal remapping of the memory > allocated from ROX cache as writable, there is a need to distinguish > between the state when the module is being formed and the state when it is > deconstructed and freed so that when module_memory_free() is called from > error paths during module loading it could restore ROX mappings. > > Replace open coded checks for MODULE_STATE_UNFORMED with a helper > function module_is_formed() and add a new MODULE_STATE_GONE that will be > set when the module is deconstructed and freed. > > Signed-off-by: Mike Rapoport (Microsoft) I've seen the rest of the discussion about this patch... but in case I forget, and from an extremely myopic kgdb/kdb point of view: Acked-by: Daniel Thompson (RISCstar) Daniel.