From patchwork Thu Oct 8 15:46:42 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 11823397 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 6A7581580 for ; Thu, 8 Oct 2020 15:48:59 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 2F5EC20578 for ; Thu, 8 Oct 2020 15:48:59 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="tQ24t7QX" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 2F5EC20578 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=arndb.de Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To:Message-Id:Date: Subject:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=0gKmv/8psLF9pUoTI83FEmhxg4ppsC6oDMMYv8deyLo=; b=tQ24t7QXAV/sNglxO6UmfEhPs zOd8GQwxj7FRSfqQKDyPWwpyMHeZcC+Hw43glXSTAvETI0ZBDeRAwzSaETD94wPEoNBUEKNrf7N9v sGc6MjFyrH5ycJpM7OTRlah+uyHVWazKDpwvwWcRCFfy2gJsU+aRNkK0FVcdtf5MnnWjBI9gI25Rf Rd2+qlDOpZqVAHqnzot73ZhB4e/8JfGG2KANw8RvTcri/OLVpNRr8R62flqnei18iZKZ1VWNmnNqS RydFTqMI1lb4g/GovlVoA9ZuADq5S/Whf0rGUzA7VuJ3t0PnzB5bcbKCHl5rTXN+ZdUL9TaOadFjq xnwX4pw4w==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kQY9m-0002ea-Vr; Thu, 08 Oct 2020 15:48:39 +0000 Received: from mout.kundenserver.de ([212.227.17.24]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kQY9S-0002WS-H0 for linux-arm-kernel@lists.infradead.org; Thu, 08 Oct 2020 15:48:24 +0000 Received: from localhost.localdomain ([192.30.34.233]) by mrelayeu.kundenserver.de (mreue107 [212.227.15.145]) with ESMTPA (Nemesis) id 1MWSFB-1jskwY2rRj-00Xu9o; Thu, 08 Oct 2020 17:47:42 +0200 From: Arnd Bergmann To: linux-kernel@vger.kernel.org Subject: [PATCH 04/13] parisc: use legacy_timer_tick Date: Thu, 8 Oct 2020 17:46:42 +0200 Message-Id: <20201008154651.1901126-5-arnd@arndb.de> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20201008154651.1901126-1-arnd@arndb.de> References: <20201008154651.1901126-1-arnd@arndb.de> MIME-Version: 1.0 X-Provags-ID: V03:K1:JdVsDzGIawLwj8GEUcu7QzV/eSgsFBBvS0zSunz+ouzZc2Q42gH wrq8P/ptdFN5PdXAnSdPK0jcmjjMVf2vwLGkyGbU+4+wf7ii7gGAJOpJxhpL50KcY/HrtG/ cWCdxngFkr9agKUW7Hbh21FchDr+S7YHVvrOZTcGziVShhOCTL4Yu5VjfVRuTZfOWZaoUva CcYs2SG7EoaTpdxAmfUzA== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:KZruJGxefIk=:xe3mRoOuTB6CmdWXSfBp/W OxmZ6VsiGfShkMH1AvQb3F7fr+iAbCgSbX/UM3s0vTBpZDkM3oEuD5h0UsiHP/2qzs5gcY436 Odm6b+I7fFLD0OMLDqKzkb7D5hORDXcGk5ob+C5YMe2wObJw3Mg1zgKV+mzBdfSj6yOeTfhqS 478MASLcP8Qqc1N2NOJ1ukQvGIhiucZTuHdhGPmlRwGPiuZUZ6+j4yT/C/SpkMX6ehPnH9okK jNOCK7+HVIxxlbKtzOi0YSwT/ikQAHBRKYToKMUpbGRZwDQdHDqL9/LHFNW7rLG7gCpCBrvP2 IZoBoAN3Wm1FHx/NN3jHYSTfrX9PGYtgT4ACQ0XseAi4iNuQCFfd7ztsA8H+sO4wmaCaJUXRR PD9WCPi16Zrizrhvyp3gswizEF+Gbxmu0cjCcNrIJhWPLmrpXv+3TK3us04jpfQHInW/ogqV1 a/24PqyLY/NvbJwxO+HTYnbhXFzIM9cLmw66It7D8ThBhFAmNaP1Pbpm5COVz9YL0HTC0dpzc yE96fToR2MNVWM3i5dVUmxrTBMhwlHfkayyb6bXBtbltsf3ZCAVL8xCBPOo3zEe8YLXufyg7G BHUMrmSx5xE1mVF0ssKoLh8Uz+fjmXMrIo7je9EU68kjozzKmFbWQKWrAT33olxXvB23K+pYr T+kVW32AGwSkx+1fZWkpQJoBud4RhdI62tZEkmNV+sTPHbNG0yi3kg5g3rQrSjCSvkE32R1Aj 8p5Rws7nG8SCU2qhjGQghuOCDq/ACf0+pkOC7fbNgfdsA6I/Nu/MlU8ZVo91WaRyePMWSA1BI sW1IR23mPOEb2kT3spdqoIRUDps68oE2qN17RLFhr92t9xFlIeoxQ+6gys/MRXh5YzG8K1B X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201008_114818_832459_C2CF615F X-CRM114-Status: GOOD ( 18.15 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [212.227.17.24 listed in list.dnswl.org] -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [212.227.17.24 listed in wl.mailspike.net] 0.0 SPF_NONE SPF: sender does not publish an SPF Record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Sam Creasey , Fenghua Yu , Linus Walleij , Tony Luck , Thomas Gleixner , linux-parisc@vger.kernel.org, Arnd Bergmann , linux-ia64@vger.kernel.org, Stephen Boyd , Helge Deller , Daniel Lezcano , Russell King , Finn Thain , "James E.J. Bottomley" , linux-m68k@lists.linux-m68k.org, Geert Uytterhoeven , linux-arm-kernel@lists.infradead.org, John Stultz , Philip Blundell , Greg Ungerer , Joshua Thompson Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org parisc has selected CONFIG_GENERIC_CLOCKEVENTS since commit 43b1f6abd590 ("parisc: Switch to generic sched_clock implementation"), but does not appear to actually be using it, and instead calls the low-level timekeeping functions directly. Remove the GENERIC_CLOCKEVENTS select again, and instead convert to the newly added legacy_timer_tick() helper. Signed-off-by: Arnd Bergmann --- Documentation/features/time/clockevents/arch-support.txt | 2 +- arch/parisc/Kconfig | 2 +- arch/parisc/kernel/time.c | 9 +++------ 3 files changed, 5 insertions(+), 8 deletions(-) diff --git a/Documentation/features/time/clockevents/arch-support.txt b/Documentation/features/time/clockevents/arch-support.txt index 8287b6aa522e..61a5c9d68c15 100644 --- a/Documentation/features/time/clockevents/arch-support.txt +++ b/Documentation/features/time/clockevents/arch-support.txt @@ -21,7 +21,7 @@ | nds32: | ok | | nios2: | ok | | openrisc: | ok | - | parisc: | ok | + | parisc: | TODO | | powerpc: | ok | | riscv: | ok | | s390: | ok | diff --git a/arch/parisc/Kconfig b/arch/parisc/Kconfig index b234e8154cbd..78b17621ee4a 100644 --- a/arch/parisc/Kconfig +++ b/arch/parisc/Kconfig @@ -52,7 +52,7 @@ config PARISC select HAVE_REGS_AND_STACK_ACCESS_API select GENERIC_SCHED_CLOCK select HAVE_UNSTABLE_SCHED_CLOCK if SMP - select GENERIC_CLOCKEVENTS + select LEGACY_TIMER_TICK select CPU_NO_EFFICIENT_FFS select NEED_DMA_MAP_STATE select NEED_SG_DMA_LENGTH diff --git a/arch/parisc/kernel/time.c b/arch/parisc/kernel/time.c index 04508158815c..889aaaa555ea 100644 --- a/arch/parisc/kernel/time.c +++ b/arch/parisc/kernel/time.c @@ -70,8 +70,6 @@ irqreturn_t __irq_entry timer_interrupt(int irq, void *dev_id) /* gcc can optimize for "read-only" case with a local clocktick */ unsigned long cpt = clocktick; - profile_tick(CPU_PROFILING); - /* Initialize next_tick to the old expected tick time. */ next_tick = cpuinfo->it_value; @@ -86,10 +84,9 @@ irqreturn_t __irq_entry timer_interrupt(int irq, void *dev_id) cpuinfo->it_value = next_tick; /* Go do system house keeping. */ - if (cpu == 0) - xtime_update(ticks_elapsed); - - update_process_times(user_mode(get_irq_regs())); + if (cpu != 0) + ticks_elapsed = 0; + legacy_timer_tick(ticks_elapsed); /* Skip clockticks on purpose if we know we would miss those. * The new CR16 must be "later" than current CR16 otherwise