From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:56642) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bDVDh-0005R3-6N for qemu-devel@nongnu.org; Thu, 16 Jun 2016 07:12:22 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bDVDe-0004uA-Ng for qemu-devel@nongnu.org; Thu, 16 Jun 2016 07:12:20 -0400 Date: Thu, 16 Jun 2016 16:37:02 +1000 From: David Gibson Message-ID: <20160616063702.GB1642@voom.fritz.box> References: <20160615041757.GI4882@voom.fritz.box> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="xgyAXRrhYN0wYx8y" Content-Disposition: inline In-Reply-To: Subject: Re: [Qemu-devel] [Qemu-ppc] Determining interest in PPC e500spin, yield, and openpic patches List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: alarson@ddci.com Cc: agraf@suse.de, qemu-devel@nongnu.org, qemu-ppc@nongnu.org --xgyAXRrhYN0wYx8y Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Jun 15, 2016 at 01:12:37PM -0700, alarson@ddci.com wrote: > David Gibson wrote on 06/14/2016 11:17:57= =20 > PM: > Aaron Larson >=20 > AL> 1. There is a defect in ppce500_spin.c:spin_kick() that creates an > AL> incorrectly sized TLB entry. This was reported as bug > AL> https://bugs.launchpad.net/qemu/+bug/1587535 I can provide a > AL> patch if desired. >=20 > DG> Absolutely. >=20 > OK, I'll start with this one. Let me know if there is anything you'd=20 > like me to do > with that bug report. >=20 > When e500 PPC is booted multi-core, the non-boot cores are started via > the spin table. ppce500_spin.c:spin_kick() calls > mmubooke_create_initial_mapping() to allocate a 64MB TLB entry, but > the created TLB entry is only 256KB. >=20 > The root cause is that the function computing the size of the TLB > entry, namely booke206_page_size_to_tlb assumes MAS1.TSIZE as defined > by latter PPC cores, specifically n to the power of FOUR * 1KB. The > result is then used by mmubooke_create_initial_mapping using > MAS1_TSIZE_SHIFT, but MAS1_TSIZE_SHIFT is defined assuming TLB entries > are n to the power of TWO * 1KB. I.e., a difference of shift=3D7 or > shift=3D8. >=20 > Simply changing MAS1_TSIZE_SHIFT from 7 to 8 is not appropriate since > the macro is used elsewhere. >=20 > The following patch has a fix for that, and also raises a separate > issue that I'd be happy to resolve after getting some guidance. Ok, thanks for sending this, but there are some procedural things you'll need to check before we can go ahead. We generally prefer patches to be sent inline, rather than as attachments (it makes adding review comments much easier), and you'll need to apply a Signed-off-by line before I could merge it. There are more details on the procedures for submitting patches at: http://wiki.qemu.org/Contribute/SubmitAPatch --=20 David Gibson | I'll have my music baroque, and my code david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_ | _way_ _around_! http://www.ozlabs.org/~dgibson --xgyAXRrhYN0wYx8y Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBAgAGBQJXYkkOAAoJEGw4ysog2bOSBlEP/3NXvOK+ycW996qXUPc6Olf5 cSEzOZlw2Tnf3D3yUd2uHfWz484++WmwHg4LsQp2FsPlm3dN8okcdu2em/skjAmk DTFs9IINxlZ9VBNt5QAL0vOHXGXpWtVUYRa4pg3YREWDjxzenbEUBvFocCs0NqkK T0w04GXtUlBnE+n6Ztcceur5AFfJ20FIp58szQUF4j7lwnVhbakH03R5gZVMKMC1 ybM/d2pvQvFnKP7xGG60bXyTdBfxAkaL1FzlXgVI7d5mCbdXSIto9xU9QwMIrwIA 5KuVTvjs1a44NNGCXjR0nfWiEn+dfuNFQZKFDe1zk99gagCSfSGizfavtdMwWQwO UPNOg0sUDYqK+LyBatmKl0uAG6J35zvsSYlqIfv+xq99DdUS8gmjqGLmTmqcTsQ/ mJpAb7yK0V8yg0aconG9sHqYHnxXJlsi83MV83bhzVDoOrFIUaNCgTzxxqwH+DDX ArbNgfFD/d11o5QGAV9l8ye/f9Ck8imTgC93NUESfaf2+QkjokL3iFkxHwen/tZf pz9UQD4c8Ls8j5yOawIz42z5l9y5I3ds75ZpVCbdvn3xLbl2yfZ/azwiYSApTBeX V4EqIn1obva+7gWAa8Vpob7yjKiXwkwPchdkHPTMMRpmZGBqc3mcEMh4jSq1hjlI ybIy3YJqwPgkuzoWwRjn =0hLO -----END PGP SIGNATURE----- --xgyAXRrhYN0wYx8y--