From mboxrd@z Thu Jan 1 00:00:00 1970 From: Julien Grall Subject: Re: [PATCH] xen/arm: Set up Versatile Express timer frequency to 24 Mhz Date: Tue, 25 Jun 2013 16:46:00 +0100 Message-ID: <51C9BB38.3000805@linaro.org> References: <1372079458-7884-1-git-send-email-julien.grall@linaro.org> <20130624135133.GA93536@ocelot.phlegethon.org> <1372174264.18901.46.camel@zakaz.uk.xensource.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1372174264.18901.46.camel@zakaz.uk.xensource.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Ian Campbell Cc: patches@linaro.org, Tim Deegan , Stefano.Stabellini@eu.citrix.com, xen-devel@lists.xen.org List-Id: xen-devel@lists.xenproject.org On 06/25/2013 04:31 PM, Ian Campbell wrote: > On Mon, 2013-06-24 at 14:51 +0100, Tim Deegan wrote: >> At 14:10 +0100 on 24 Jun (1372083058), Julien Grall wrote: >>> On TC2, the timer frequency was set to 100 Mhz which slows down the whole >>> platform. >>> When Linux is running on bare metal, the frequency is 24 Mhz. >>> >>> "sleep 60" in dom0 takes: >>> - 4 mins with a frequency equals to 100 Mhz >>> - 1 min with a frequency equals to 24 Mhz >>> >>> Signed-off-by: Julien Grall >> >> Is this a problem with the vexpress (e.g. the timer runs at 24MHz >> regardless of this setting, which would explain the otherwise odd >> numbers you give above), or just that linux code assumes the timer is >> always 24MHz? >> >> If it's the latter, I think it needs to be fixed on the linux side. Xen >> can't let the guest OS dictate things like this, since we might want to >> run two guests with different OSes. Also, if linux changes its choice, >> we'd have trouble with old and new linux running together. > > Isn't this timer only available to dom0, as the owner of most > peripherals? > > Guests use the arch timers, because that is all they see. > > Xen doesn't use this timer at all for any purpose AFAIK. > > That said, it is a bit of an odd quirk that dom0 can see platform timers > too, especially if it can cause breakage, but maybe not as critical as > all that? Timers on ARM seems a bit complex. The current issue is with arch timer (which is also used by dom0). As I understand, there are also a bunch of clocks for different device (UARTs, I2C,...). If theses clocks is not "pass-through" to dom0 nothing will work. -- Julien