From patchwork Sat Oct 22 07:27:10 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 7689 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4242:0:0:0:0:0 with SMTP id s2csp1109102wrr; Sat, 22 Oct 2022 01:47:16 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4J4FJ42WhfiS1bUrlZ3Mdl5KU6072hQKq0AbBpv5AbTFl4irkO3WYFmkhANOfJv1yauJjU X-Received: by 2002:a17:907:9605:b0:6f5:c66:7c13 with SMTP id gb5-20020a170907960500b006f50c667c13mr19819863ejc.66.1666428436170; Sat, 22 Oct 2022 01:47:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666428436; cv=none; d=google.com; s=arc-20160816; b=O02UL9L7SdkN+zJiDmLdOx90oit8VyytAYZ8CG63bR5ucljDXpOkicCySOmUHihcNq 6cV/7QtLR9NYwTNijPHBGTJm+GCMkO/r+Dxz+UaMo9B/6hvbDdmdIiHt82WBfO83e/X5 9YxRiBIzNNrbE+RulwV1tC0iZ75a/ZaCGVnc+/YUpcwJr/znFoRFaFuK+gfWoftZG3BJ vlw4hH7qFsVxi2y7kW5ysm3IFrOLzBddjVmb+409P1UfPr+Rorh0qTHVo0Xdd/ohEUAa 70d9LZg9iwHgaqQfhtn3S3zEf9wUh3AwbGd76EYG2947uFX/3ghCi4I6UNJ9l9EI2W5w /FfQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=O8rtQZvCK3QrKkEijY70c3BNQMjq20RYlITf+boiZWE=; b=JVUn+MVpJFlA8MPpVs6VWcywftjyWZmykJyIZR4OhDW2uQrTD83WmLNHuAvHrePZCW UFEnP4ChiwHUlYIOuGyyUwanyLx+vSNtElIgilRHhB3o6PvED8asqJ7XKX0t9mTb7/a7 tprSEL4HfFN9NnKt+X/0T3RIK7FpPrsrszthZL4kflKTW2U3xQUJJ8U9qHg2/wKWocP1 u1iqZYO4Q8GtrC6tnl+1P9nvYgxmiz0buIC0EzMUbCyo9oKJl/dlFEMqnoveESg+kdHN NLuOioZRJft2rzTrZaTEJNb5J2BDZdxe4XrP5x+kmMTLk/lKb8fy/LLxJfe1vMWTggo/ PR9Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=EyYMYy0X; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ho19-20020a1709070e9300b0078dcd448f97si26437016ejc.801.2022.10.22.01.46.51; Sat, 22 Oct 2022 01:47:16 -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=@linuxfoundation.org header.s=korg header.b=EyYMYy0X; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234332AbiJVIqC (ORCPT + 99 others); Sat, 22 Oct 2022 04:46:02 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33240 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234831AbiJVIn5 (ORCPT ); Sat, 22 Oct 2022 04:43:57 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 14F772EA957; Sat, 22 Oct 2022 01:07:36 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 708A260B83; Sat, 22 Oct 2022 07:59:56 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 16257C433C1; Sat, 22 Oct 2022 07:59:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1666425595; bh=KJQPpJ32UIqN4u7A8mzjqm34rg4kJPRAbyTUOPAsbIY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=EyYMYy0XiVg2wqEGk118QpqI4Jwj7lUfHboCqgbkndWVHHMad91hfK1qhx/8C803T J38Azsq5Qyb2u3SU3UXJ9TbOs/x46YZxwOHVqoo2OBL1RezjN1hIkQQzpR+alHpdGR 44I2RBx6I1Pur7OL+hdLlIiEUIXj8KpbtOudLbHQ= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, kernel test robot , Russell King , linux-arm-kernel@lists.infradead.org, Kees Cook , Sasha Levin Subject: [PATCH 5.19 551/717] ARM: decompressor: Include .data.rel.ro.local Date: Sat, 22 Oct 2022 09:27:10 +0200 Message-Id: <20221022072522.740344747@linuxfoundation.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221022072415.034382448@linuxfoundation.org> References: <20221022072415.034382448@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 X-Spam-Status: No, score=-7.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1747376863710158284?= X-GMAIL-MSGID: =?utf-8?q?1747376863710158284?= From: Kees Cook [ Upstream commit 1b64daf413acd86c2c13f5443f6b4ef3690c8061 ] The .data.rel.ro.local section has the same semantics as .data.rel.ro here, so include it in the .rodata section of the decompressor. Additionally since the .printk_index section isn't usable outside of the core kernel, discard it in the decompressor. Avoids these warnings: arm-linux-gnueabi-ld: warning: orphan section `.data.rel.ro.local' from `arch/arm/boot/compressed/fdt_rw.o' being placed in section `.data.rel.ro.local' arm-linux-gnueabi-ld: warning: orphan section `.printk_index' from `arch/arm/boot/compressed/fdt_rw.o' being placed in section `.printk_index' Reported-by: kernel test robot Link: https://lore.kernel.org/linux-mm/202209080545.qMIVj7YM-lkp@intel.com Cc: Russell King Cc: linux-arm-kernel@lists.infradead.org Signed-off-by: Kees Cook Signed-off-by: Sasha Levin --- arch/arm/boot/compressed/vmlinux.lds.S | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm/boot/compressed/vmlinux.lds.S b/arch/arm/boot/compressed/vmlinux.lds.S index 1bcb68ac4b01..3fcb3e62dc56 100644 --- a/arch/arm/boot/compressed/vmlinux.lds.S +++ b/arch/arm/boot/compressed/vmlinux.lds.S @@ -23,6 +23,7 @@ SECTIONS *(.ARM.extab*) *(.note.*) *(.rel.*) + *(.printk_index) /* * Discard any r/w data - this produces a link error if we have any, * which is required for PIC decompression. Local data generates @@ -57,6 +58,7 @@ SECTIONS *(.rodata) *(.rodata.*) *(.data.rel.ro) + *(.data.rel.ro.*) } .piggydata : { *(.piggydata)