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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 00A27C3ABAD for ; Tue, 29 Apr 2025 14:13:07 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=lmzJbT/zv3N9O0/8n+UDbFmAxVoJNo1SifnjPsro9dA=; b=lAUZm3iRjbrZWz /R4nsjaPpJ5n8VUt29khKfUxadNzggN+dxZnxhgLwpZ8ZIQL5r5s1ouR0yWqf7LTnFijFQN1QpTq5 ghSWJOzF4XtRlzqBHdiB83hQkyo6Mddv4wXlL1ZZzN+EjRi56DBMM9Rb1+umWQTH5Eqrv0gLLB9jL +Y9/Xuqo0tbVecujnHNaJQ11xdCAGIsMyhFRR0LwUk3uq1mL1pMzUuMo9cLGL5YPVtXaqrtKL4ipK +aljloWFWqvTnk29Gpv4mvhE6RUX0d4ktbrA3zdaF+MFWzk5EAk1+WZaT3+efbor3Hu9WyNH+bOSo 8V8OW91DdoWaNak0OlZg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98.2 #2 (Red Hat Linux)) id 1u9lhk-00000009rrm-2rbr; Tue, 29 Apr 2025 14:13:00 +0000 Received: from desiato.infradead.org ([2001:8b0:10b:1:d65d:64ff:fe57:4e05]) by bombadil.infradead.org with esmtps (Exim 4.98.2 #2 (Red Hat Linux)) id 1u9jOY-00000009XaI-3Cl5 for linux-riscv@bombadil.infradead.org; Tue, 29 Apr 2025 11:45:02 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=Content-Transfer-Encoding:MIME-Version :References:In-Reply-To:Message-ID:Date:Subject:Cc:To:From:Sender:Reply-To: Content-Type:Content-ID:Content-Description; bh=o3MWKB0E6r0DhQH09qIedKGJMSXQAuEZVGL4WDfC1H0=; b=QwYDrySqmeyJr2Q96bWUysldEq nNmtax0Z8lYJ8LUuwCUXO+XyDdK/zDvOIUyHu+K1hJboJu/fzRPV1ol9opi+Age3aK8tOWWrF9fec bO25bZtcpYMJaEqCKksPGy+mcXnS9587cmVNtWmkW4E763dySAu/KFYQOXKvO3XHi/jbo4LvW7Sja IGA9wGTsp+M+Cjk+s0j0M9IlTnnuEDl3ZwYr9Fb8eVkzzvYtzdJVeNS41E4TTiUK8R2ssH0uYpsca O5T6QXmCNEJYyBbVG91fwjMb5CTYl0YT2DrM48ZjyUy35DpZ/x8tc+Q5kzsXyI6k6ugVRZqdv4yZQ TZCVQscQ==; Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]) by desiato.infradead.org with esmtps (Exim 4.98.1 #2 (Red Hat Linux)) id 1u9jOV-0000000DHuX-498R for linux-riscv@lists.infradead.org; Tue, 29 Apr 2025 11:45:01 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1745927098; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=o3MWKB0E6r0DhQH09qIedKGJMSXQAuEZVGL4WDfC1H0=; b=GqRXkN/20vwMZr2tcyQD1jrexU0DfNGLaQPVXWgULCdS2+6RfbQijjn5ypN2Lxgo2vmlXe IITVOPjzmwB6Fuw5vC9OkFPpTm20z7PlEQbbe8C/Mf+JzGsnR2zyP4P3dYwuH9PFgkAQ6c V2s38Z4qXOPTeqpZKxH4SpYvkXEwL24= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1745927098; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=o3MWKB0E6r0DhQH09qIedKGJMSXQAuEZVGL4WDfC1H0=; b=GqRXkN/20vwMZr2tcyQD1jrexU0DfNGLaQPVXWgULCdS2+6RfbQijjn5ypN2Lxgo2vmlXe IITVOPjzmwB6Fuw5vC9OkFPpTm20z7PlEQbbe8C/Mf+JzGsnR2zyP4P3dYwuH9PFgkAQ6c V2s38Z4qXOPTeqpZKxH4SpYvkXEwL24= Received: from mx-prod-mc-02.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-484-ayQLBPO2OPy26KvLe-FVSg-1; Tue, 29 Apr 2025 07:44:56 -0400 X-MC-Unique: ayQLBPO2OPy26KvLe-FVSg-1 X-Mimecast-MFC-AGG-ID: ayQLBPO2OPy26KvLe-FVSg_1745927091 Received: from mx-prod-int-04.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-04.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.40]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-02.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 97FC31956089; Tue, 29 Apr 2025 11:44:51 +0000 (UTC) Received: from vschneid-thinkpadt14sgen2i.remote.csb (unknown [10.45.225.102]) by mx-prod-int-04.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 8F03619560A3; Tue, 29 Apr 2025 11:44:21 +0000 (UTC) From: Valentin Schneider To: linux-kernel@vger.kernel.org, virtualization@lists.linux.dev, linux-arm-kernel@lists.infradead.org, loongarch@lists.linux.dev, linux-riscv@lists.infradead.org, linux-perf-users@vger.kernel.org, kvm@vger.kernel.org, linux-arch@vger.kernel.org, linux-modules@vger.kernel.org, linux-trace-kernel@vger.kernel.org, rcu@vger.kernel.org, linux-hardening@vger.kernel.org, linux-kselftest@vger.kernel.org, bpf@vger.kernel.org Cc: Juri Lelli , Marcelo Tosatti , Yair Podemsky , Josh Poimboeuf , Daniel Wagner , Petr Tesarik , Nicolas Saenz Julienne , Frederic Weisbecker , "Paul E. McKenney" , Dave Hansen , Sean Christopherson , Juergen Gross , Ajay Kaher , Alexey Makhalov , Broadcom internal kernel review list , Russell King , Catalin Marinas , Will Deacon , Huacai Chen , WANG Xuerui , Paul Walmsley , Palmer Dabbelt , Albert Ou , Alexandre Ghiti , Thomas Gleixner , Ingo Molnar , Borislav Petkov , x86@kernel.org, "H. Peter Anvin" , Peter Zijlstra , Arnaldo Carvalho de Melo , Namhyung Kim , Mark Rutland , Alexander Shishkin , Jiri Olsa , Ian Rogers , Adrian Hunter , "Liang, Kan" , Pawan Gupta , Paolo Bonzini , Arnd Bergmann , Jason Baron , Steven Rostedt , Ard Biesheuvel , Luis Chamberlain , Petr Pavlu , Sami Tolvanen , Daniel Gomez , Naveen N Rao , Anil S Keshavamurthy , "David S. Miller" , Masami Hiramatsu , Neeraj Upadhyay , Joel Fernandes , Josh Triplett , Boqun Feng , Uladzislau Rezki , Mathieu Desnoyers , Lai Jiangshan , Zqiang , Vincent Guittot , Dietmar Eggemann , Ben Segall , Mel Gorman , Kees Cook , Shuah Khan , Masahiro Yamada , Alice Ryhl , Miguel Ojeda , "Mike Rapoport (Microsoft)" , Rong Xu , Rafael Aquini , Song Liu , Andrii Nakryiko , Dan Carpenter , Brian Gerst , "Kirill A. Shutemov" , Benjamin Berg , Vishal Annapurve , Randy Dunlap , John Stultz , Tiezhu Yang Subject: [PATCH v5 22/25] module: Remove outdated comment about text_size Date: Tue, 29 Apr 2025 13:32:39 +0200 Message-ID: <20250429113242.998312-23-vschneid@redhat.com> In-Reply-To: <20250429113242.998312-1-vschneid@redhat.com> References: <20250429113242.998312-1-vschneid@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.0 on 10.30.177.40 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20250429_124500_203802_A8E74399 X-CRM114-Status: GOOD ( 16.58 ) X-BeenThere: linux-riscv@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-riscv" Errors-To: linux-riscv-bounces+linux-riscv=archiver.kernel.org@lists.infradead.org The text_size bit referred to by the comment has been removed as of commit ac3b43283923 ("module: replace module_layout with module_memory") and is thus no longer relevant. Remove it and comment about the contents of the masks array instead. Signed-off-by: Valentin Schneider --- kernel/module/main.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/kernel/module/main.c b/kernel/module/main.c index a2859dc3eea66..b9f010daaa4c7 100644 --- a/kernel/module/main.c +++ b/kernel/module/main.c @@ -1562,12 +1562,11 @@ static void __layout_sections(struct module *mod, struct load_info *info, bool i { unsigned int m, i; + /* + * { Mask of required section header flags, + * Mask of excluded section header flags } + */ static const unsigned long masks[][2] = { - /* - * NOTE: all executable code must be the first section - * in this array; otherwise modify the text_size - * finder in the two loops below - */ { SHF_EXECINSTR | SHF_ALLOC, ARCH_SHF_SMALL }, { SHF_ALLOC, SHF_WRITE | ARCH_SHF_SMALL }, { SHF_RO_AFTER_INIT | SHF_ALLOC, ARCH_SHF_SMALL }, -- 2.49.0 _______________________________________________ linux-riscv mailing list linux-riscv@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-riscv