From: mark.rutland@arm.com (Mark Rutland)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v2 6/9] arm: mediatek: enable gpt6 on boot up to make arch timer working
Date: Thu, 21 Aug 2014 11:56:08 +0100 [thread overview]
Message-ID: <20140821105608.GK21734@leverpostej> (raw)
In-Reply-To: <CABuKBe+oVzQ9_Q__sULLQt8OvJ1Za_uA5x2aXSSQ6r8myvFqnA@mail.gmail.com>
On Thu, Aug 21, 2014 at 11:38:20AM +0100, Matthias Brugger wrote:
> 2014-08-18 17:45 GMT+02:00 Mark Rutland <mark.rutland@arm.com>:
> > Hi Matthias,
> >
> > On Mon, Aug 18, 2014 at 03:58:34PM +0100, Matthias Brugger wrote:
> >> We enable GTP6 which ungates the arch timer clock. Apart we write the
> >> frequency with which the timer is running in the CNTFREQ register.
> >
> > We don't seem to set CNTFRQ below. Does it happen to have a consistent
> > value on current versions of the bootloader?
>
> Oh sorry, my fault. In v2 I moved the frequency to the dts, as this
> will make the driver write CNTFRQ.
> I forgot to update the commit message.
The arch timer driver does not write CNTFRQ as this can only be done
from the secure side. It simply uses the value provided internally. This
isn't sufficient for virtualization guests (which need to have CNTFRQ
programmed correctly).
For the moment as we're not booting at Hyp that's not necessarily a big
problem, but it is a shame.
> >> In the future this should be done in the bootloader.
> >
> > Do we know how far in the future that's likely to be?
>
> AFAIK no one right now is working on an open source bootloader for the
> mediatek devices.
> So I think we won't see an open source bootloader in a reasonable time.
Ok. :(
> > What's the plan for this code when such a bootloader becomes available?
>
> I think when a bootloader becomes available, this code should be
> removed. I know that this will lead to a not working ARM arch timer in
> devices which don't migrate to the new bootloader, but I think it's
> not too critical. Apart from the ARM arch timer, the devices have the
> mediatek global porpose timer (drivers/clocksource/mtk_timer.c), which
> implement a clock source and a clock event timer. So the system won't
> hang.
I fear that's never going to happen, either because such a bootloader
never becomes available or because there will be hold-outs sticking to
the old loader.
If that's not critical, why not for the moment use the global timer?
Thanks,
Mark.
next prev parent reply other threads:[~2014-08-21 10:56 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-18 14:58 [PATCH v2 0/9] arm: mediatek: Add more basic features Matthias Brugger
2014-08-18 14:58 ` [PATCH v2 1/9] arm: dts: Build dtb for Mediatek board Matthias Brugger
2014-08-18 14:58 ` [PATCH v2 2/9] arm: multi_v7_defconfig: Enable Mediatek platform Matthias Brugger
2014-08-18 14:58 ` [PATCH v2 3/9] arm: dts: mt6589: Fix typo in GIC unit address Matthias Brugger
2014-08-18 14:58 ` [PATCH v2 4/9] arm: mediatek: Add earlyprintk support for mt6589 Matthias Brugger
2014-08-18 14:58 ` [PATCH v2 5/9] arm: dts: mt6589-aquaris5: Add boot argument earlyprintk Matthias Brugger
2014-08-18 14:58 ` [PATCH v2 6/9] arm: mediatek: enable gpt6 on boot up to make arch timer working Matthias Brugger
2014-08-18 15:45 ` Mark Rutland
2014-08-21 10:38 ` Matthias Brugger
2014-08-21 10:56 ` Mark Rutland [this message]
2014-08-18 14:58 ` [PATCH v2 7/9] arm: dts: mt6589: Add arm arch timer node Matthias Brugger
2014-08-18 14:58 ` [PATCH v2 8/9] arm: dts: mediatek: Add compatible property for aquaris5 Matthias Brugger
2014-08-18 14:58 ` [PATCH v2 9/9] arm: dts: mt6589: Change compatible string for GIC Matthias Brugger
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=20140821105608.GK21734@leverpostej \
--to=mark.rutland@arm.com \
--cc=linux-arm-kernel@lists.infradead.org \
/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