Received: by 2002:a05:6358:c692:b0:131:369:b2a3 with SMTP id fe18csp1389914rwb; Wed, 26 Jul 2023 11:43:02 -0700 (PDT) X-Google-Smtp-Source: APBJJlGbblsTPLtJO87FjdQL7Vb1P0tDtw6BXoFNRo8Hy5ePBSDm8ozhaLIOiupywcPZwVOWgm1+ X-Received: by 2002:a05:6a00:1789:b0:686:a10d:ea21 with SMTP id s9-20020a056a00178900b00686a10dea21mr3061464pfg.27.1690396981847; Wed, 26 Jul 2023 11:43:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690396981; cv=none; d=google.com; s=arc-20160816; b=b8Yc0Rqn6Yjem6cxmUK7qzq/bHsAcd50xgwfOaN16uF+hVn6bSPWa/ih1qpDclTcV1 IMFjunHLspPFcA+bgDtfQ5xlfYLGeTWoNeSeE6gX+Kpzn7TBor/1Q2iSFCvOmwfAXE5a 8zshxf0xV2qKcJRXJwStvRmkncsZPLP4iDtaywSJwTmqWC+6D1QoRaAKjvrp954T0GT0 PMStBN11QMm8xYPkxpg89mbSc2r9fqNx2CE90h8R2dvXjGcVmAoK9WgQ6UT+op++D2Zv ILSTHDPaE16uUGT/lqihsUN6s046huA1W6kGudqTe5lZvNqjvuWg5AcHjcaMlu5mF+BN Ia0Q== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=DVwxJPyF1NYlwGrMQ/sQwTaKDH4Mx/0wzHcHtSNEhTQ=; fh=2AmsHgAxkXvhtq2BfB2hBoQPDQHM9O1rz+6h2hgCO5A=; b=eEEokI2S3RpxtkJxUoaEVqHsMw59ddt8fl4CStjteJOta6s44RJPWfu6eqXpbLdMEp bZybR2W6m4o9+WvJ/gSs6kLjxKwLgBKj4gbiv9zO0MAFFj75t2/cS/vLPnnkFDSsI6nn 15CyVlNMivoPp5IBOTuf7Q4+XuPsqzcnApTR/AsMYxGw3FVSYo58CVcCc0teg6NkvEQE hKERFLvyfu4gqCFP1OFDsW+MR2cmLkw6+RdwGy8XrQrVw174VdfW1IHgYGvRRvzeviGh Vf2kZTDNhAVXViMyaJDYCfjxEl5SUBnvsMG2b9lfrFIiLMUyJVbF0XNKuU66HhzPDDF/ CW6g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=K+M6E067; 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=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id cl6-20020a056a0032c600b00670ab28fac3si13102447pfb.378.2023.07.26.11.42.49; Wed, 26 Jul 2023 11:43:01 -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=@kernel.org header.s=k20201202 header.b=K+M6E067; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231234AbjGZRmI (ORCPT + 99 others); Wed, 26 Jul 2023 13:42:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39324 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230342AbjGZRmF (ORCPT ); Wed, 26 Jul 2023 13:42:05 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 82E7C2685 for ; Wed, 26 Jul 2023 10:42:04 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 19D9F61BE6 for ; Wed, 26 Jul 2023 17:42:04 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 3D2CAC433C8; Wed, 26 Jul 2023 17:42:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1690393323; bh=fOYigNePlsrUb3dRqIC3/Ob7Qzi/aiqzn31+xV+bzaM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=K+M6E067FfjPCZKuJZ9lNLLwnZz6jYodnhLy8yF03C92zX0IDO+m+B0T3XW7vgkWO ohRoqa0nqbgJGOpOmKbL4G/WsqqPzBga43sKWCQuGiNdPONCwZR2FpotNJJF+VoDsG GecnymJv0fJbCrZ8cig1QeUA390l7lo07iri5hS+3Dd+IgmGCQ7+pMhqBTaMwwUqY+ bviq+VCCP4wowizlnlhzQcmp9Jkjq8YeCwvKbxVjEQysKW6NxMCTvnjLSsmtp+3a7g WYuiCHaG+Z9eK1oFo7F+f9RxSRMzM9YMqwuWgzSjTI540Z3RGbmbPFFycCmpgJ2Rgc tJeSD92FmJhXQ== From: Jisheng Zhang To: Paul Walmsley , Palmer Dabbelt , Albert Ou Cc: Andrew Jones , linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/3] riscv: vdso.lds.S: merge .data section into .rodata section Date: Thu, 27 Jul 2023 01:30:23 +0800 Message-Id: <20230726173024.3684-3-jszhang@kernel.org> X-Mailer: git-send-email 2.40.0 In-Reply-To: <20230726173024.3684-1-jszhang@kernel.org> References: <20230726173024.3684-1-jszhang@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 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,T_SCC_BODY_TEXT_LINE 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 The .data section doesn't need to be separate from .rodata section, they are both readonly. Signed-off-by: Jisheng Zhang --- arch/riscv/kernel/vdso/vdso.lds.S | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/arch/riscv/kernel/vdso/vdso.lds.S b/arch/riscv/kernel/vdso/vdso.lds.S index d43fd7c7dd11..671aa21769bc 100644 --- a/arch/riscv/kernel/vdso/vdso.lds.S +++ b/arch/riscv/kernel/vdso/vdso.lds.S @@ -29,7 +29,13 @@ SECTIONS .eh_frame_hdr : { *(.eh_frame_hdr) } :text :eh_frame_hdr .eh_frame : { KEEP (*(.eh_frame)) } :text - .rodata : { *(.rodata .rodata.* .gnu.linkonce.r.*) } + .rodata : { + *(.rodata .rodata.* .gnu.linkonce.r.*) + *(.got.plt) *(.got) + *(.data .data.* .gnu.linkonce.d.*) + *(.dynbss) + *(.bss .bss.* .gnu.linkonce.b.*) + } /* * This linker script is used both with -r and with -shared. @@ -44,13 +50,6 @@ SECTIONS .alternative : { *(.alternative) } - - .data : { - *(.got.plt) *(.got) - *(.data .data.* .gnu.linkonce.d.*) - *(.dynbss) - *(.bss .bss.* .gnu.linkonce.b.*) - } } /* -- 2.40.1