Received: by 2002:a05:7412:419a:b0:f3:1519:9f41 with SMTP id i26csp383631rdh; Thu, 23 Nov 2023 06:35:05 -0800 (PST) X-Google-Smtp-Source: AGHT+IHbr3jhO4UzmbvB8StHhHfAVapPp9ZGL1p7kKPUsj6IJ6lV6iW9+TwRw3TRruBlrUcmUWQs X-Received: by 2002:a17:90b:3e85:b0:280:29d0:2c6e with SMTP id rj5-20020a17090b3e8500b0028029d02c6emr6439362pjb.11.1700750105527; Thu, 23 Nov 2023 06:35:05 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700750105; cv=none; d=google.com; s=arc-20160816; b=F8WAJxUCAS9RAwxyh2vnr7kEhwI7PxNl3H3EjEwAruDkhgyO5UU12LMnGkkJ5H7b1h 8mvnGiMDCoSXaGje/bRKkeLlw4wnKPqFJBwlv/ZaxF+gCcVQmWD3LghmhghJ/6NiDYB/ lO1lph/iz7Uml3UlSa8kZdNKJV6PWaFdM1jDuABOTwALfwzUrxixc5TKTDeJ0jaw6FAg R7xn1HyB3f02wwarnZMrjeypXK3IC3GysaJiizmxQEI4y7CmfPgQiJ8cnfccj20aFxGL AQegXpMG6FXrPvy70hu+YU6eJdIZLALRXdO4H5CC4OQ79tgdZPNH54bt37NPoOY+Z3uo 8C7w== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=uglfTe0Egc8Jkl82nTwLHSi9SWhGa6GHJYy5P642824=; fh=YQ0kC7zgtAKyXXyoETEQxaA3RExZYcHwesAg1wId/VU=; b=WPCcdttoywzFNCdcP8GuS/cZfAfJD6VfR9bzpJmQwF2yHmyEz/mIGo1/dA3Pt5EZ4j 5hY8HxtOTh+IEvdS0pCLR6a3Ei+CHONsTfgb9I5E+ij7zQvzwsE/T5eivyAV3ji/b9Hd WQTJmnWoZOqo7uRqtFWXS1sAQyXfpgViG9L/yJNp9/VBrdVPbH/lv0vyg70M06B+f0ia 55CZUV8mxq1eLbEJ22aYSljLX2ucatH61nZAbnryRQkeg9sOnIBpuJO3EnQ7jFR8hJkY Q0uCsMur722XwIG1k9k+7cXCQjBrirUWP9dBAKGfOChV/8ZGr4Z6XCOoAAZO6M7tPQ5m VdAw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=aQdNthO7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 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 fry.vger.email (fry.vger.email. [23.128.96.38]) by mx.google.com with ESMTPS id ob2-20020a17090b390200b0028525c8810esi1938067pjb.129.2023.11.23.06.35.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Nov 2023 06:35:05 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) client-ip=23.128.96.38; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=aQdNthO7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id 645CD808726F; Thu, 23 Nov 2023 06:35:03 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345850AbjKWOem (ORCPT + 99 others); Thu, 23 Nov 2023 09:34:42 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57188 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345842AbjKWOek (ORCPT ); Thu, 23 Nov 2023 09:34:40 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E994DD4F for ; Thu, 23 Nov 2023 06:34:46 -0800 (PST) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 28243C433C7; Thu, 23 Nov 2023 14:34:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1700750086; bh=2IIUNX5jKc+M5fhmvdUI02XyPwbOQktGxlJKInijJuI=; h=From:To:Cc:Subject:Date:From; b=aQdNthO7a7rwwou48QT1q4YfT21UDqnVCR72Ffa/4PegDCV/DHufmlm8pB2rgHGcQ irZcpvIsEfqSTOA8w4pLrfmwRT0XLq/LGbDuCAIPYpAFa/w2BSxxParN54rx0nvxza D6rfqht0Ybzb0VVUIc0xi2ZlfaDgxMtJevufLHpl5n/EtZkLuvX6lXlWm2Ad+TUUqw PXvMSs0H4Z6TJ3RFaRld/dVlG79CNCLwFWm7zNtEyI8PFJCGyO8dzKLe01YxhMEnnv CwCnudU7SWBDfreKmWIX1X5aUIrJOiOeM9lTXnKyF6fNdEXdnBnMDjAq1qP4ynCr8D DKdrUvQygdkYg== From: Jisheng Zhang To: Paul Walmsley , Palmer Dabbelt , Albert Ou , Nathan Chancellor Cc: linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH] riscv: Select ARCH_WANTS_NO_INSTR Date: Thu, 23 Nov 2023 22:22:23 +0800 Message-Id: <20231123142223.1787-1-jszhang@kernel.org> X-Mailer: git-send-email 2.40.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.3 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Thu, 23 Nov 2023 06:35:03 -0800 (PST) As said in the help of ARCH_WANTS_NO_INSTR entry in arch/Kconfig: "An architecture should select this if the noinstr macro is being used on functions to denote that the toolchain should avoid instrumenting such functions and is required for correctness." Select ARCH_WANTS_NO_INSTR for correctness. PS: The reason we didn't find any issue so far is that the CC_HAS_NO_PROFILE_FN_ATTR is true. Signed-off-by: Jisheng Zhang --- arch/riscv/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/riscv/Kconfig b/arch/riscv/Kconfig index e4834fa76417..433ec617703e 100644 --- a/arch/riscv/Kconfig +++ b/arch/riscv/Kconfig @@ -60,6 +60,7 @@ config RISCV select ARCH_WANT_HUGE_PMD_SHARE if 64BIT select ARCH_WANT_LD_ORPHAN_WARN if !XIP_KERNEL select ARCH_WANT_OPTIMIZE_HUGETLB_VMEMMAP + select ARCH_WANTS_NO_INSTR select ARCH_WANTS_THP_SWAP if HAVE_ARCH_TRANSPARENT_HUGEPAGE select BINFMT_FLAT_NO_DATA_START_OFFSET if !MMU select BUILDTIME_TABLE_SORT if MMU -- 2.42.0