linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Daniel Lezcano <daniel.lezcano@linaro.org>
To: Jisheng Zhang <jszhang@marvell.com>,
	tglx@linutronix.de, linux@arm.linux.org.uk, arnd@arndb.de
Cc: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 0/3] let Marvell Berlin SoCs make use of the best delay timer
Date: Wed, 4 Nov 2015 10:46:49 +0100	[thread overview]
Message-ID: <5639D409.1030302@linaro.org> (raw)
In-Reply-To: <1446560917-6318-1-git-send-email-jszhang@marvell.com>

On 11/03/2015 03:28 PM, Jisheng Zhang wrote:
> In case there are several possible delay timers, we purely base the
> selection on the frequency, which is suboptimal in some cases. Take
> one Marvell Berlin platform for example: we have arch timer and dw-apb
> timer. The arch timer freq is 25MHZ while the dw-apb timer freq is
> 100MHZ, current selection would choose the dw-apb timer. But the dw
> apb timer is on the APB bus while arch timer sits in CPU, the cost
> of accessing the apb timer is higher than the arch timer.
>
> This series firstly modifies register_current_timer_delay() to choose
> the highest rating delay timer: use the rating as a primary indication
> and fall back to comparing the frequency if the rating is not set or
> the same. Then we set the arch_delay_timer rating as 400, finally
> Implement ARM delay timer for the dw_apb_timer and set its rating as 300.

Hi Jisheng, Arnd,

I don't feel comfortable with the rating / freq think. I am afraid this 
approach based on heuristic will bring a lot of complexity and 
workarounds in the code for a small benefit.

Why don't we define a DT entry for the delay timer ? So we delegate the 
choice to the platform DT definition.


-- 
  <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


  parent reply	other threads:[~2015-11-04  9:46 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-03 14:28 [PATCH v2 0/3] let Marvell Berlin SoCs make use of the best delay timer Jisheng Zhang
2015-11-03 14:28 ` [PATCH v2 1/3] ARM: delay: choose the highest rating " Jisheng Zhang
2015-11-03 14:28 ` [PATCH v2 2/3] ARM: arch_timer: set the arch_delay_timer rating as 400 Jisheng Zhang
2015-11-03 14:28 ` [PATCH v2 3/3] clocksource/drivers/dw_apb_timer_of: Implement ARM delay timer Jisheng Zhang
2015-11-04  9:46 ` Daniel Lezcano [this message]
2015-11-04 10:30   ` [PATCH v2 0/3] let Marvell Berlin SoCs make use of the best " Arnd Bergmann
2015-11-04 11:19     ` Daniel Lezcano
2015-11-04 12:19       ` Arnd Bergmann
2015-11-05  2:36         ` Jisheng Zhang

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=5639D409.1030302@linaro.org \
    --to=daniel.lezcano@linaro.org \
    --cc=arnd@arndb.de \
    --cc=jszhang@marvell.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@arm.linux.org.uk \
    --cc=tglx@linutronix.de \
    /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;
as well as URLs for NNTP newsgroup(s).