From patchwork Tue Oct 1 11:23:56 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mark Brown X-Patchwork-Id: 13817868 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 1B489CE7D10 for ; Tue, 1 Oct 2024 11:26:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Cc:To:Message-Id: Content-Transfer-Encoding:Content-Type:MIME-Version:Subject:Date:From: Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender :Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=RZwqITWI6mh4s2vgQm9UjUNT24VEkNmpezLhkryooi8=; b=oLKDeSW0yjlp/txNJ6/hbJQrP+ eYoL1QeBkKK5IYYHS6QqzO68jIjLpTvGz4h3md5Yc7GHFrSL6wFX17dkf1fX8yQGz2RJ1GjDu1pk5 V4aqsKNKgkgLYMHxOtKzdz+8VQeFf8jE2MeLVvnOpWPfUGvW9t2zpjIjSU2gcIlGQhcUfuId+2r// bs55lylC/C5QVwqAgn2EIQL+bwOWDaa0KXFMFTICYZvWnw+Q9LZdSLSYtds7OXLXnWM/8hfGHkSoA Su4eNHtCM351/g2tpNn0XA8taj/X6RbCtU7GtxkXhoYMNycGX4AVBRFZx7c7Bly+vZvpz7i9Jx3r8 K9KNGq9g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1svb19-00000002VQ6-3PY4; Tue, 01 Oct 2024 11:26:11 +0000 Received: from nyc.source.kernel.org ([2604:1380:45d1:ec00::3]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1svaz6-00000002VFb-3iwr for linux-arm-kernel@lists.infradead.org; Tue, 01 Oct 2024 11:24:06 +0000 Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by nyc.source.kernel.org (Postfix) with ESMTP id BE453A43539; Tue, 1 Oct 2024 11:23:55 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 03DE8C4CEC6; Tue, 1 Oct 2024 11:24:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1727781843; bh=sXXgqHQa9Widx7yDUBLgFY+o29P8M0HLTr5bNdEzFvc=; h=From:Date:Subject:To:Cc:From; b=pN97RCP5JS9FoMBxFBQGIZ92Bcfdx5/e7SwmifEHbww+RCmxzaIFKMZzPppK8S1Om AFCof4xhd5XO9NX14Q8tDB+Xz/UVBy4Ar9D+6IQpT0AZ2SlmUJ1BICku3jx22He2eB QgtLI2a6AOVwfW5lxiXvgIX5L0Whs4v9n6SAcMSAWDUhP4NaGSjus6LhmoY1yyEDmm 0Q1fpnlN+a+IjySKK46JgClYVQ22Ou+/kcI4/jV7lhIBy4heSwrh1m/kF2Ec1s5z6q 4APs1sBMOO1gjGCu9FztHx92SK/8/eYDuCObbgNhSvGhkHEZ3a6UgUqvlCxUPAv9CD EdtPe2/oaM4/Q== From: Mark Brown Date: Tue, 01 Oct 2024 12:23:56 +0100 Subject: [PATCH v3] clocksource: sp804: Make user selectable MIME-Version: 1.0 Message-Id: <20241001-arm64-vexpress-sp804-v3-1-0a2d3f7883e4@kernel.org> X-B4-Tracking: v=1; b=H4sIAMvb+2YC/4XNzQ6CMAzA8VchO1szuvHlyfcwHsYosKhAOrNgC O/u4KQH4/Hfpr8uwhM78uKULIIpOO/GIYY6JML2ZugIXBNboEQtM0Qw/Mg1BJonJu/BT6XUoPK syStV1rKwIp7GXevmnb1cY/fOP0d+7V9Cuk3/gCGFFKTS2jYaqS6K8414oPtx5E5sYsBPpfqhY FRsptGU0rRKmS9lXdc3Fs5twP8AAAA= To: Daniel Lezcano , Thomas Gleixner , David Abdurachmanov Cc: Sudeep Holla , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Ross Burton , Mark Rutland , Mark Brown X-Mailer: b4 0.15-dev-99b12 X-Developer-Signature: v=1; a=openpgp-sha256; l=2117; i=broonie@kernel.org; h=from:subject:message-id; bh=sXXgqHQa9Widx7yDUBLgFY+o29P8M0HLTr5bNdEzFvc=; b=owEBbQGS/pANAwAKASTWi3JdVIfQAcsmYgBm+9vQp7qXoYs0XolQAHVdukM9GIOTuZfciVURc5Or Zp5WIcaJATMEAAEKAB0WIQSt5miqZ1cYtZ/in+ok1otyXVSH0AUCZvvb0AAKCRAk1otyXVSH0Ai0B/ 4uU+yxam9fxUSl7BunsND0BflzLqvni6JhwPUtkevxfMRx55xLRWnTwgoBASr66puv52JgZEXVF8UK q5q2UHsMN8HwrnsmkPgu+dYCmeNmITAQEu2w4OEUnwjYhegiWBtk8AuWVBkaTHfj5rMqGzBvnTu5Gl 20tc9vctRmwI3W01oDh7nOxCcxAtJ8PEHlPkiLUP1WEzRuchRcMz/kdzqHAMkHuS5aj2U1pVpq9AIy NmhraSeqGk7tjIVA92vLUSQ4hO9B/FrMZU2X19iBqEcrDcOP2zKWdoK1gACw/x35T/ZvxyvRkYhqtI WIGosqXEJFvsj61u2Ly98ZH1CnbwPz X-Developer-Key: i=broonie@kernel.org; a=openpgp; fpr=3F2568AAC26998F9E813A1C5C3F436CA30F5D8EB X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241001_042405_094813_0435F389 X-CRM114-Status: GOOD ( 13.11 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The sp804 is currently only user selectable if COMPILE_TEST, this was done by commit dfc82faad725 ("clocksource/drivers/sp804: Add COMPILE_TEST to CONFIG_ARM_TIMER_SP804") in order to avoid it being spuriously offered on platforms that won't have the hardware since it's generally only seen on Arm based platforms. This config is overly restrictive, while platforms that rely on the SP804 do select it in their Kconfig there are others such as the Arm fast models which have a SP804 available but currently unused by Linux. Relax the dependency to allow it to be user selectable on arm and arm64 to avoid surprises and in case someone comes up with a use for extra timer hardware. Fixes: dfc82faad725 ("clocksource/drivers/sp804: Add COMPILE_TEST to CONFIG_ARM_TIMER_SP804") Reported-by: Ross Burton Reviewed-by: Sudeep Holla Acked-by: Mark Rutland Signed-off-by: Mark Brown --- Changes in v3: - Rebase onto v6.12-rc1. - Link to v2: https://lore.kernel.org/r/20240529-arm64-vexpress-sp804-v2-1-c542a80af33a@kernel.org Changes in v2: - Rebase onto v6.10-rc1. - Link to v1: https://lore.kernel.org/r/20240522-arm64-vexpress-sp804-v1-1-0344cd42eb77@kernel.org --- drivers/clocksource/Kconfig | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) --- base-commit: 9852d85ec9d492ebef56dc5f229416c925758edc change-id: 20240522-arm64-vexpress-sp804-365d6938b07c Best regards, diff --git a/drivers/clocksource/Kconfig b/drivers/clocksource/Kconfig index 95dd4660b5b6..d546903dba4f 100644 --- a/drivers/clocksource/Kconfig +++ b/drivers/clocksource/Kconfig @@ -400,7 +400,8 @@ config ARM_GT_INITIAL_PRESCALER_VAL This affects CPU_FREQ max delta from the initial frequency. config ARM_TIMER_SP804 - bool "Support for Dual Timer SP804 module" if COMPILE_TEST + bool "Support for Dual Timer SP804 module" + depends on ARM || ARM64 || COMPILE_TEST depends on GENERIC_SCHED_CLOCK && HAVE_CLK select CLKSRC_MMIO select TIMER_OF if OF