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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 48AB8EB64D9 for ; Sat, 17 Jun 2023 15:37:10 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id C0DDA8E0001; Sat, 17 Jun 2023 11:37:09 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id BBDD16B0075; Sat, 17 Jun 2023 11:37:09 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id AACF78E0001; Sat, 17 Jun 2023 11:37:09 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0014.hostedemail.com [216.40.44.14]) by kanga.kvack.org (Postfix) with ESMTP id 9AA7D6B0072 for ; Sat, 17 Jun 2023 11:37:09 -0400 (EDT) Received: from smtpin07.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay04.hostedemail.com (Postfix) with ESMTP id 72AE21A01E2 for ; Sat, 17 Jun 2023 15:37:09 +0000 (UTC) X-FDA: 80912643378.07.AFC3FF9 Received: from out-20.mta0.migadu.com (out-20.mta0.migadu.com [91.218.175.20]) by imf09.hostedemail.com (Postfix) with ESMTP id B1583140003 for ; Sat, 17 Jun 2023 15:37:06 +0000 (UTC) Authentication-Results: imf09.hostedemail.com; dkim=pass header.d=linux.dev header.s=key1 header.b=bYJe9WRi; spf=pass (imf09.hostedemail.com: domain of kent.overstreet@linux.dev designates 91.218.175.20 as permitted sender) smtp.mailfrom=kent.overstreet@linux.dev; dmarc=pass (policy=none) header.from=linux.dev ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1687016226; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=gkXjdfOcfNeiSkHnMLeI301HhtsXBRoYstWMSEINMeY=; b=cFsO/x6v6vP2du05yPbWHsVddl2NBBX2u4a7ep4ha2agcXEDvVNStg9zjDXWDf1hafaWSX MfzjCmfYtNWsMqQuw8pI+HydR88wKvL7ayaWgi8Xw2lhHmTOilsjSonln4/jtJt26tKvWg n0zxdBHw5nEiVOkxf2o5ng9/Y+VSVtI= ARC-Authentication-Results: i=1; imf09.hostedemail.com; dkim=pass header.d=linux.dev header.s=key1 header.b=bYJe9WRi; spf=pass (imf09.hostedemail.com: domain of kent.overstreet@linux.dev designates 91.218.175.20 as permitted sender) smtp.mailfrom=kent.overstreet@linux.dev; dmarc=pass (policy=none) header.from=linux.dev ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1687016226; a=rsa-sha256; cv=none; b=mKIq+GVqbc8HxzGbUlWCC+63sF6eWFglcRg+RgmCE00GklOxSQUEj+9DaqD4opVMOftzPv GDPNEuVUPleK0sL6Pso2UM7Z7RjEse1Xnb7iebbvrCZrWndvm/UG0HAR3LQTQf9/ajtNyb +XuXeA7d7/7OVWSNriJvzgbXsTN68UE= Date: Sat, 17 Jun 2023 11:36:58 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1687016225; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=gkXjdfOcfNeiSkHnMLeI301HhtsXBRoYstWMSEINMeY=; b=bYJe9WRiSRM7w/M47iLquWHHUju4li/dPcwoEprDi3YlwcaYBjxpWs1nL0UujvT6xyWL/M S2Ghsqn2fpzAD+9R1F0Wx9PyfySyz0oJLdRx0TD6TfwLRge4cekLdS4qLEUtsEWtm6ack0 XRAL5F0yJ/NulC1WuvN1fyiNm3tO1UM= X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Kent Overstreet To: Mike Rapoport Cc: Song Liu , linux-kernel@vger.kernel.org, Andrew Morton , Catalin Marinas , Christophe Leroy , "David S. Miller" , Dinh Nguyen , Heiko Carstens , Helge Deller , Huacai Chen , Luis Chamberlain , Mark Rutland , Michael Ellerman , Nadav Amit , "Naveen N. Rao" , Palmer Dabbelt , Puranjay Mohan , Rick Edgecombe , Russell King , Steven Rostedt , Thomas Bogendoerfer , Thomas Gleixner , Will Deacon , bpf@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mips@vger.kernel.org, linux-mm@kvack.org, linux-modules@vger.kernel.org, linux-parisc@vger.kernel.org, linux-riscv@lists.infradead.org, linux-s390@vger.kernel.org, linux-trace-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, loongarch@lists.linux.dev, netdev@vger.kernel.org, sparclinux@vger.kernel.org, x86@kernel.org Subject: Re: [PATCH v2 07/12] arm64, execmem: extend execmem_params for generated code definitions Message-ID: References: <20230616085038.4121892-1-rppt@kernel.org> <20230616085038.4121892-8-rppt@kernel.org> <20230617065759.GT52412@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230617065759.GT52412@kernel.org> X-Migadu-Flow: FLOW_OUT X-Rspamd-Queue-Id: B1583140003 X-Rspam-User: X-Stat-Signature: jgsk761jhnfm1mfwsf7qd5rrkf5mbkod X-Rspamd-Server: rspam01 X-HE-Tag: 1687016226-814338 X-HE-Meta: U2FsdGVkX19V7esMlz8wXCKJOvu4sboRD99qWBPZm3LDLmrviNio4FKZARIBlwMnGIPWvad/o3XQISKQLIFORx1gX00XvJIwXsONMMoY8KpiLR4FRRt1P9lm5LC/BbuW4+VFbR4MP+qGYKypEEvsTI/6CN3YTW1ASRmnQrE88R/Zc9PvqQ9P4hBVeeDY3A6Tm15eyMUfeakdGUE9MaudRIbMqEU6aCPlXQL32hx1JssW+5XRqR4tz6rHFQGQdJNLzlGp7CpqFX/CdDrfnJUtn4k1lHD9hGaMnxQjPBhy3Ue/2i9LpBcRQggI1903d8Uz1qnnw/nre45jotC3yYUU3wtSFKD6yV3fTo+iCbCAS5FCNu+YQiInWmG2NgtYtAxDRUdB2CXlSm+IGux1rxWsOeDmtbnG0Z6Pf0ZbutV5YW9m09ejbTA0b0p/ksHVPMgxw9/Z3qLWtxqxplwmyWsaxCcd5WHBkd4XOSSSB942gDhCW3mvC5kovIY96Ecck1Fp3eY4feZWihIKsclCZhMnzecVieJUGFnz/MFGDegb9jelZCwoOejxj9iRYNotRmMOIF1Ba8U1QQ/oFhxdgKd8+UrPuKnTOmcJd6eYXNjQrFpwdpyfBYhSJIcJuGM4zv3LNz243037w+CZhbn3kYeMkvuEgMF4V0SFfuBKH1txXUyralCFhEkqTrGlCjOro4RgLgJ3lnTOwB1ioTTrZXFa5QDwY9IlGkcvgw5EjhYmwO6jX1jOjTql6qLxV3CDYhKUE4gWRfFH2CShrL1YYZ0a+dGzVbuSuUNyz9KLEU9wUpyyBIHQxJidK+aCo5gn+82WHjzeEXTD9d5RgnCz4jTdpe//5PJoBQJ17xfHhMfCU/UY21C2rwtqOoBJt28D0KDkkTUWeEshZtNtZpkP/k02D9jWsh6U+5TgD6OTqhCQivB3K3oWOjaNO3hGw2AMnkRZe8A80d8aH9CW9Wb4qUR 00Lq2UiE BPXBVtA3Wryxn6gzlmQVkiTRC0rFll+pT1Ul2FovrjqXieeyLuqOhE3iaJOGxtiggSWlrYIJnSYB3aErcVdsuP5j+Q/yG70dHA5c9TGLkJjP2WZ/JI1gvUXJDRxJHoEDxl9DtaQcwthzDr/AE21SU5WVG+k9uKYeOOatI1l4ApH2vLZI= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Sat, Jun 17, 2023 at 09:57:59AM +0300, Mike Rapoport wrote: > > This is growing fast. :) We have 3 now: text, data, jit. And it will be > > 5 when we split data into rw data, ro data, ro after init data. I wonder > > whether we should still do some type enum here. But we can revisit > > this topic later. > > I don't think we'd need 5. Four at most :) > > I don't know yet what would be the best way to differentiate RW and RO > data, but ro_after_init surely won't need a new type. It either will be > allocated as RW and then the caller will have to set it RO after > initialization is done, or it will be allocated as RO and the caller will > have to do something like text_poke to update it. Perhaps ro_after_init could use the same allocation interface and share pages with ro pages - if we just added a refcount for "this page currently needs to be rw, module is still loading?" text_poke() approach wouldn't be workable, you'd have to audit and fix all module init code in the entire kernel.