Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp470219imm; Fri, 5 Oct 2018 06:50:07 -0700 (PDT) X-Google-Smtp-Source: ACcGV61+0a7iQglRbjfSqjVBnWxT8pL4bliIruS6qbnhA73r5M1YgW8TIRqYusMNZU6d4pVNU75m X-Received: by 2002:a17:902:8e8b:: with SMTP id bg11-v6mr11603233plb.219.1538747407485; Fri, 05 Oct 2018 06:50:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1538747407; cv=none; d=google.com; s=arc-20160816; b=DxKvNsVNnAwybU/YQrt+7++5dQcAVTxyuAKo/w7zoItf78FuYyrksgEcW1JQSp69Dr bcKZCq2AyEqRpj1zGAZjo5D1MRcmgD2rkCcxS2KuUXLAJFmTzh9W4dYXc2dw34RljqV8 bgJK1JFWLfM11aht2LYyJELZYaP2KMLwggy+3QgyTXnRwGc/ycoJfHOoupP9yIw1ZJXL 5icR52vFINCIz7j1+ZYX1U356S7uZ3AHJGm2MTJLW5s9HVPjo410oTbrWfcj+ffw0PMX 15XQC5Zw6mEYYWeDApsX1BNYb7z3ydqD6lVejn/nv10IA07mId/yp+Z35IhKs1q3P2i+ cSYg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=pFowR5rZv27Byo7MG/rb8vt4PHkizLtRCIAEAUNAVvc=; b=AM5uuSq5yCvYvAIsF5Zp4OUMlFWzu9oYDFbV75WbMGlJiFUfdQbJzOEwho+ulI4Xa2 L2fQzE2fTCkN5OeStlPFbfznrQlTE5jpiEMEEjQ1NeM/AH75rXkF1Dq9zB79CxweUk2Y 45HiOXV28ukAQ+7U4AADTcpM+UGXmy6d1wor0tz0bqages5/WKPCHhqgUESHzKhFEtia yFJOFNRejYwr5Vz5Cbss8UqI0d2F5Z6sGG/cH9qJVhXdQEACchBdXJtNhgD1/yqT1aXU N9pCkofqlWCX3l6Pof4uyZrNxM0VkkKT8vOgseLMbBeee6rh0BMB2f2o+5T9eoOfpApp /n6g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="SNyww/+v"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j2-v6si7862116pgt.435.2018.10.05.06.49.51; Fri, 05 Oct 2018 06:50:07 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="SNyww/+v"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728868AbeJEUrv (ORCPT + 99 others); Fri, 5 Oct 2018 16:47:51 -0400 Received: from mail-wr1-f67.google.com ([209.85.221.67]:45319 "EHLO mail-wr1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728422AbeJEUrv (ORCPT ); Fri, 5 Oct 2018 16:47:51 -0400 Received: by mail-wr1-f67.google.com with SMTP id q5-v6so13617214wrw.12 for ; Fri, 05 Oct 2018 06:49:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=pFowR5rZv27Byo7MG/rb8vt4PHkizLtRCIAEAUNAVvc=; b=SNyww/+v2rOWzp3wWlNE2GMDOY2kfILfEMUec9joURmjgU94IBUPrWzgwPtwwe+NxP ZUlvOALV23Dpx1eKrKl+Upbx/yNKJs6wQQq9ruuWqUeDx/57QYjI9QJ31EWg8X+sb4+7 8BSbCxcO9EKGpY2fBN8ATf0fh2w4niAF5XPDI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=pFowR5rZv27Byo7MG/rb8vt4PHkizLtRCIAEAUNAVvc=; b=OBvw/gdxJNyTFQqMOHuvLiVvZHQlPRUp7fp++rlPCYDjnbo5WjSaR354iYkKVxmdsA bLrcVPrPPNl1Tf1/PSzXNxw8TTrRIs715Tcv7NvF0RW7sLm8By6A+95csfiMd4PqnTkw y2nMAizK0YfAsEMwGfCT3FpvjKKb65FMC5T4pqjgx1M1X72Qe84to2Xkg8uJhE6+ZDog jdWj4KHGUG8WABikaKlBuhH2rBk+rPruwaPwK+qX2eSFT2Pxnfq3WtZD019vIXAI58kU RQSiMER/+V2bFwLCIcAHBrh4gu3YQU8Xj1298NKCxkoc7o0/e8B2EghNTMhWW1lZO/rZ sdAw== X-Gm-Message-State: ABuFfoi4zYiRMYVQAyjWQz0fH0H2wt/8rkL8KMPRqyPR6q5OxdW7Q24A 8vOIN/56clFVSsdWw5nMbW1w0A== X-Received: by 2002:a5d:4a12:: with SMTP id m18-v6mr8458434wrq.278.1538747340967; Fri, 05 Oct 2018 06:49:00 -0700 (PDT) Received: from [192.168.0.40] (151.240.136.77.rev.sfr.net. [77.136.240.151]) by smtp.googlemail.com with ESMTPSA id 20-v6sm2453909wml.10.2018.10.05.06.48.59 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 05 Oct 2018 06:49:00 -0700 (PDT) Subject: Re: [PATCH V10 5/8] clocksource: add C-SKY SMP timer To: Guo Ren , tglx@linutronix.de, jason@lakedaemon.net, marc.zyngier@arm.com, robh+dt@kernel.org, mark.rutland@arm.com, anurup.m@huawei.com, Jonathan.Cameron@huawei.com, will.deacon@arm.com, zhangshaokun@hisilicon.com, jhogan@kernel.org, paul.burton@mips.com, peterz@infradead.org, arnd@arndb.de Cc: linux-kernel@vger.kernel.org, devicetree@vger.kernel.org References: <76f127a22faf8f110f102ee3534792b2b84a7d78.1538672812.git.ren_guo@c-sky.com> From: Daniel Lezcano Message-ID: <4ec284a4-0cff-91b8-bd0a-6eb578b28432@linaro.org> Date: Fri, 5 Oct 2018 15:48:58 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <76f127a22faf8f110f102ee3534792b2b84a7d78.1538672812.git.ren_guo@c-sky.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 04/10/2018 19:22, Guo Ren wrote: > This timer is used by SMP system and use mfcr/mtcr instruction > to access the regs. > > Changelog: > - Add rollback for timer_of_cleanup. > - Use request_percpu_irq separate from time_of. > - Remove #define CPUHP_AP_CSKY_TIMER_STARTING. > - Add CPUHP_AP_CSKY_TIMER_STARTING in cpuhotplug.h. > - Support csky mp timer alpha version. > - Just use low-counter with 32bit width as clocksource. > - Coding convention with upstream feed-back. > > Signed-off-by: Guo Ren > --- > drivers/clocksource/Kconfig | 10 +++ > drivers/clocksource/Makefile | 1 + > drivers/clocksource/timer-mp-csky.c | 173 ++++++++++++++++++++++++++++++++++++ > include/linux/cpuhotplug.h | 1 + > 4 files changed, 185 insertions(+) > create mode 100644 drivers/clocksource/timer-mp-csky.c > > diff --git a/drivers/clocksource/Kconfig b/drivers/clocksource/Kconfig > index a11f4ba..826a2e8 100644 > --- a/drivers/clocksource/Kconfig > +++ b/drivers/clocksource/Kconfig > @@ -620,4 +620,14 @@ config RISCV_TIMER > is accessed via both the SBI and the rdcycle instruction. This is > required for all RISC-V systems. > > +config CSKY_MP_TIMER > + bool "SMP Timer for the C-SKY platform" > + depends on CSKY > + select TIMER_OF > + help > + Say yes here to enable C-SKY SMP timer driver used for C-SKY SMP > + system. > + csky,mptimer is not only used in SMP system, it also could be used > + single core system. It's not a mmio reg and it use mtcr/mfcr instruction. ... COMPILE_TEST :) -- Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog