From owner-freebsd-arm@FreeBSD.ORG Thu Dec 19 13:14:29 2013 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id CBC343BE for ; Thu, 19 Dec 2013 13:14:29 +0000 (UTC) Received: from kanar.ci0.org (kanar.ci0.org [IPv6:2001:bc8:35e6::1]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 6C43B1F70 for ; Thu, 19 Dec 2013 13:14:29 +0000 (UTC) Received: from kanar.ci0.org (pluxor@localhost [127.0.0.1]) by kanar.ci0.org (8.14.5/8.14.5) with ESMTP id rBJDEQUU017716; Thu, 19 Dec 2013 14:14:26 +0100 (CET) (envelope-from mlfbsd@kanar.ci0.org) Received: (from mlfbsd@localhost) by kanar.ci0.org (8.14.5/8.14.5/Submit) id rBJDEQsX017715; Thu, 19 Dec 2013 14:14:26 +0100 (CET) (envelope-from mlfbsd) Date: Thu, 19 Dec 2013 14:14:26 +0100 From: Olivier Houchard To: Wojciech Macek Subject: Re: arm SMP on Cortex-A15 Message-ID: <20131219131426.GA17686@ci0.org> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Cc: freebsd-arm@freebsd.org X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Dec 2013 13:14:29 -0000 Hi Wojciech, On Thu, Dec 19, 2013 at 12:41:59PM +0100, Wojciech Macek wrote: > Hi, > > Finally, I'm able to run FreeBSD stable on Cortex-A15. The TLB issue which > was observed, was caused by an aggressive A15 feature called "L2 TLB > prefetch". > Wow that's great news ! > There are 4 fixes that helped: > 0. Prerequisite, Olivier's patch for PCPU atomicity. Cool, I'll commit it, then. > 1. TEX remap - to be compliant with spec, TEX remap is used to configure > memory as Inner Shareable > 2. TLB flush SE - after each PTE modification and PTE_SYNC, there is no > guarantee that newly created entry is not overlapped by old value in TLB > cache. Do flush_SE to ensure proper mapping. Wow, I failed to realized we were missing so many flush. And I've read the pmap code to find any of those many many times. Great work ! > 3. During context switch, ensure that tlb flush is executed after ttb is > changed. Clean BTB to be compliant with specs. > > Above patches can be found here > https://drive.google.com/folderview?id=0B-7yTLrPxaWteWFtWUQxVVNHVFk&usp=sharing > > > None of them is 100%-ready, but should work. Any comments and/or testing > are really appreciated. > Regards, Olivier