From mboxrd@z Thu Jan 1 00:00:00 1970 From: Julien Grall Subject: Re: Bringing up sequence for non-boot CPU fails Date: Sat, 01 Mar 2014 23:58:48 +0800 Message-ID: <531203B8.7070604@linaro.org> References: <1392725646.11080.47.camel@kazak.uk.xensource.com> <1392727989.11080.61.camel@kazak.uk.xensource.com> <1392730494.11080.62.camel@kazak.uk.xensource.com> <1392737632.23084.4.camel@kazak.uk.xensource.com> <5303A78C.6090709@citrix.com> <1392801354.23084.79.camel@kazak.uk.xensource.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Andrii Anisov , Oleksandr Tyshchenko Cc: Julien Grall , Ian Campbell , "xen-devel@lists.xen.org" List-Id: xen-devel@lists.xenproject.org Hello Andrii and Oleksandr, Sorry for the late answer. On 19/02/14 20:35, Andrii Anisov wrote: > The latest update is: Oleksandr tried solution suggested by Julien and > the issue seems to be not reproducible. Thanks for the update. I talked with Ian about this issue, the problem may come from setup_pagetables (arch/arm/mm.c). The function is zeros boot_pgtable, boot_first and boot_second, then just clean the cache for theses ranges. But ... when the secondary CPU sets up theses variables, the cache is disabled. When the cache is enabled (just before we enable paging), cache may contain data that was not reached the memory, therefore it will shadow the real data. Can you try these 2 small tests (separately): - Flush all the cache before boot_pgtable is zeroed (arch/arm/mm.c:486) - Flush all the cache after clean_xen_dcache(boot_second) (arch/arm/mm.c:493) If the former test is failing and not the latter, then we have found the issue :). I think the 3 clean_xen_dcache should be replaced by a clean and invalidate dcache. Regards, -- Julien Grall