From: Daniel Lezcano <daniel.lezcano@linaro.org>
To: Zhen Lei <thunder.leizhen@huawei.com>,
Thomas Gleixner <tglx@linutronix.de>,
linux-kernel <linux-kernel@vger.kernel.org>
Cc: Libin <huawei.libin@huawei.com>,
Kefeng Wang <wangkefeng.wang@huawei.com>,
Jianguo Chen <chenjianguo3@huawei.com>
Subject: Re: [PATCH v2 7/9] clocksource: sp804: add support for Hisilicon sp804 timer
Date: Fri, 18 Sep 2020 10:53:25 +0200 [thread overview]
Message-ID: <5efc0de3-754b-2b48-7769-d9ac7f5e21b0@linaro.org> (raw)
In-Reply-To: <20200912114536.2910-8-thunder.leizhen@huawei.com>
On 12/09/2020 13:45, Zhen Lei wrote:
> The ARM SP804 supports a maximum of 32-bit counter, but Hisilicon extends
> it to 64-bit. That means, the registers: TimerXload, TimerXValue and
> TimerXBGLoad are 64bits, all other registers are the same as those in the
> SP804. The driver code can be completely reused except that the register
> offset is different.
>
> Use compatible = "hisilicon,sp804" mark as Hisilicon sp804 timer.
>
> Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com>
> ---
> drivers/clocksource/timer-sp.h | 12 ++++++++++++
> drivers/clocksource/timer-sp804.c | 15 +++++++++++++++
> 2 files changed, 27 insertions(+)
>
> diff --git a/drivers/clocksource/timer-sp.h b/drivers/clocksource/timer-sp.h
> index 1ab75cbed0e0..6ca8d82e8544 100644
> --- a/drivers/clocksource/timer-sp.h
> +++ b/drivers/clocksource/timer-sp.h
> @@ -31,6 +31,18 @@
> #define TIMER_MIS 0x14 /* CVR ro */
> #define TIMER_BGLOAD 0x18 /* CVR rw */
>
> +
> +#define HISI_TIMER_1_BASE 0x00
> +#define HISI_TIMER_2_BASE 0x40
> +#define HISI_TIMER_LOAD 0x00
> +#define HISI_TIMER_VALUE 0x08
> +#define HISI_TIMER_CTRL 0x10
> +#define HISI_TIMER_INTCLR 0x14
> +#define HISI_TIMER_RIS 0x18
> +#define HISI_TIMER_MIS 0x1c
> +#define HISI_TIMER_BGLOAD 0x20
Why not put them in timer-sp804.c directly ?
[ ... ]
--
<http://www.linaro.org/> Linaro.org │ Open source software for ARM SoCs
Follow Linaro: <http://www.facebook.com/pages/Linaro> Facebook |
<http://twitter.com/#!/linaroorg> Twitter |
<http://www.linaro.org/linaro-blog/> Blog
next prev parent reply other threads:[~2020-09-18 8:53 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-12 11:45 [PATCH v2 0/9] " Zhen Lei
2020-09-12 11:45 ` [PATCH v2 1/9] clocksource: sp804: cleanup clk_get_sys() Zhen Lei
2020-09-12 11:45 ` [PATCH v2 2/9] clocksource: sp804: remove unused sp804_timer_disable() and timer-sp804.h Zhen Lei
2020-09-12 11:45 ` [PATCH v2 3/9] clocksource: sp804: delete the leading "__" of some functions Zhen Lei
2020-09-12 11:45 ` [PATCH v2 4/9] clocksource: sp804: remove a mismatched comment Zhen Lei
2020-09-12 11:45 ` [PATCH v2 5/9] clocksource: sp804: prepare for support non-standard register offset Zhen Lei
2020-09-12 11:45 ` [PATCH v2 6/9] clocksource: sp804: " Zhen Lei
2020-09-12 11:45 ` [PATCH v2 7/9] clocksource: sp804: add support for Hisilicon sp804 timer Zhen Lei
2020-09-18 8:53 ` Daniel Lezcano [this message]
2020-09-18 9:34 ` Leizhen (ThunderTown)
2020-09-12 11:45 ` [PATCH v2 8/9] clocksource: sp804: enable Hisilicon sp804 timer 64bit mode Zhen Lei
2020-09-12 11:45 ` [PATCH v2 9/9] dt-bindings: sp804: add support for Hisilicon sp804 timer Zhen Lei
2020-09-15 1:27 ` [PATCH v2 0/9] clocksource: " Leizhen (ThunderTown)
2020-09-17 12:34 ` Daniel Lezcano
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5efc0de3-754b-2b48-7769-d9ac7f5e21b0@linaro.org \
--to=daniel.lezcano@linaro.org \
--cc=chenjianguo3@huawei.com \
--cc=huawei.libin@huawei.com \
--cc=linux-kernel@vger.kernel.org \
--cc=tglx@linutronix.de \
--cc=thunder.leizhen@huawei.com \
--cc=wangkefeng.wang@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®