Linux ACPI
 help / color / mirror / Atom feed
From: Thomas Gleixner <tglx@linutronix.de>
To: Fu Wei <fu.wei@linaro.org>
Cc: rjw@rjwysocki.net, lenb@kernel.org, daniel.lezcano@linaro.org,
	marc.zyngier@arm.com, hanjun.guo@linaro.org,
	linux-arm-kernel@lists.infradead.org,
	linaro-acpi@lists.linaro.org, linux-kernel@vger.kernel.org,
	linux-acpi@vger.kernel.org, rruigrok@codeaurora.org,
	harba@codeaurora.org, cov@codeaurora.org, timur@codeaurora.org,
	graeme.gregory@linaro.org, al.stone@linaro.org, jcm@redhat.com,
	wei@redhat.com, arnd@arndb.de, wim@iguana.be,
	catalin.marinas@arm.com, will.deacon@arm.com,
	Suravee.Suthikulpanit@amd.com, leo.duran@amd.com
Subject: Re: [RESEND PATCH v4 5/5] clocksource: add memory-mapped timer support in arm_arch_timer.c
Date: Fri, 18 Mar 2016 10:32:48 +0100 (CET)	[thread overview]
Message-ID: <alpine.DEB.2.11.1603181031280.3978@nanos> (raw)
In-Reply-To: <1458288053-29031-6-git-send-email-fu.wei@linaro.org>

[-- Attachment #1: Type: TEXT/PLAIN, Size: 940 bytes --]

On Fri, 18 Mar 2016, fu.wei@linaro.org wrote:
> +static u32 __init arch_timer_mem_cnttidr(struct acpi_gtdt_timer_block *gt_block)
> +{
> +	phys_addr_t cntctlbase_phy;
> +	void __iomem *cntctlbase;
> +	u32 cnttidr;
> +
> +	cntctlbase_phy = (phys_addr_t)gtdt_gt_cntctlbase(gt_block);
> +	if (!cntctlbase_phy) {
> +		pr_err("Can't find CNTCTLBase.\n");
> +		return 0;
> +	}
> +
> +	/*
> +	 * According to ARMv8 Architecture Reference Manual(ARM),
> +	 * the size of CNTCTLBase frame of memory-mapped timer
> +	 * is SZ_4K(Offset 0x000 – 0xFFF).
> +	 */
> +	cntctlbase = ioremap(cntctlbase_phy, SZ_4K);
> +	if (!cntctlbase) {
> +		pr_err("Can't map CNTCTLBase\n");
> +		return 0;
> +	}

Why are you continuing when you can't find a base address or the remap fails?

> +	/*
> +	 * Get Generic Timer Counter-timer Timer ID Register
> +	 * for Virtual Timer Capability info
> +	 */
> +	cnttidr = arch_timer_mem_cnttidr(gt_block);

Thanks,

	tglx

  reply	other threads:[~2016-03-18  9:34 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-18  8:00 [RESEND PATCH v4 0/5] acpi, clocksource: add GTDT and ARM memory-mapped timer support fu.wei
2016-03-18  8:00 ` [RESEND PATCH v4 1/5] clocksource: move some enums and marcos to header file for arm_arch_timer fu.wei
2016-03-18  9:27   ` Thomas Gleixner
2016-03-29  9:38     ` Fu Wei
2016-03-18  8:00 ` [RESEND PATCH v4 2/5] ACPI: add GTDT table parse driver into ACPI driver fu.wei
2016-03-18 14:45   ` Daniel Lezcano
2016-03-18  8:00 ` [RESEND PATCH v4 3/5] clocksource: simplify ACPI code in arm_arch_timer.c fu.wei
2016-03-18  8:00 ` [RESEND PATCH v4 4/5] clocksource: a little improvment for printk " fu.wei
2016-03-18  8:00 ` [RESEND PATCH v4 5/5] clocksource: add memory-mapped timer support " fu.wei
2016-03-18  9:32   ` Thomas Gleixner [this message]
2016-03-18 13:37 ` [RESEND PATCH v4 0/5] acpi, clocksource: add GTDT and ARM memory-mapped timer support 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=alpine.DEB.2.11.1603181031280.3978@nanos \
    --to=tglx@linutronix.de \
    --cc=Suravee.Suthikulpanit@amd.com \
    --cc=al.stone@linaro.org \
    --cc=arnd@arndb.de \
    --cc=catalin.marinas@arm.com \
    --cc=cov@codeaurora.org \
    --cc=daniel.lezcano@linaro.org \
    --cc=fu.wei@linaro.org \
    --cc=graeme.gregory@linaro.org \
    --cc=hanjun.guo@linaro.org \
    --cc=harba@codeaurora.org \
    --cc=jcm@redhat.com \
    --cc=lenb@kernel.org \
    --cc=leo.duran@amd.com \
    --cc=linaro-acpi@lists.linaro.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=marc.zyngier@arm.com \
    --cc=rjw@rjwysocki.net \
    --cc=rruigrok@codeaurora.org \
    --cc=timur@codeaurora.org \
    --cc=wei@redhat.com \
    --cc=will.deacon@arm.com \
    --cc=wim@iguana.be \
    /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