From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49513) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ag4lf-0001zg-5p for qemu-devel@nongnu.org; Wed, 16 Mar 2016 02:17:16 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ag4lb-0006JI-VV for qemu-devel@nongnu.org; Wed, 16 Mar 2016 02:17:15 -0400 References: <1457974600-13828-1-git-send-email-clg@fr.ibm.com> <1457974600-13828-16-git-send-email-clg@fr.ibm.com> <20160316011412.GX9032@voom> From: Thomas Huth Message-ID: <56E8FA5E.3040709@redhat.com> Date: Wed, 16 Mar 2016 07:17:02 +0100 MIME-Version: 1.0 In-Reply-To: <20160316011412.GX9032@voom> Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="r0vKrXXruM12Mg0qg24H9pxTD6K7pNuVj" Subject: Re: [Qemu-devel] [PATCH 15/17] ppc: Add dummy POWER8 MPPR register List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: David Gibson , =?UTF-8?Q?C=c3=a9dric_Le_Goater?= Cc: qemu-ppc@nongnu.org, qemu-devel@nongnu.org This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --r0vKrXXruM12Mg0qg24H9pxTD6K7pNuVj Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 16.03.2016 02:14, David Gibson wrote: > On Mon, Mar 14, 2016 at 05:56:38PM +0100, C=C3=A9dric Le Goater wrote: >> From: Benjamin Herrenschmidt >> >> Controls the micropartition prefetch, this is pretty much meaningless >> in full emulation (used for priming the caches on real HW). >> >> Signed-off-by: Benjamin Herrenschmidt >=20 > So, this is readable with HV=3D0, so technically a fix even for non-HV > machines. I'm guessing it's not actually read in practice outside the > HV, though. Not sure if this should go in 2.6 or 2.7. Patch looks simple (i.e. without risk) enough to be fine for 2.6, I think= =2E But looking at this again, I wonder why there is no KVM_REG_PPC_* definition for this register, so that it could be sync'ed with the kernel, too? Is that on purpose or is it just missing by accident? Thomas >> --- >> target-ppc/cpu.h | 1 + >> target-ppc/translate_init.c | 13 +++++++++++++ >> 2 files changed, 14 insertions(+) >> >> diff --git a/target-ppc/cpu.h b/target-ppc/cpu.h >> index 81a3e6b5ed29..5203cc6a3bfb 100644 >> --- a/target-ppc/cpu.h >> +++ b/target-ppc/cpu.h >> @@ -1398,6 +1398,7 @@ static inline int cpu_mmu_index (CPUPPCState *en= v, bool ifetch) >> #define SPR_DHDES (0x0B1) >> #define SPR_DPDES (0x0B0) >> #define SPR_DAWR (0x0B4) >> +#define SPR_MPPR (0x0B8) >> #define SPR_RPR (0x0BA) >> #define SPR_DAWRX (0x0BC) >> #define SPR_HFSCR (0x0BE) >> diff --git a/target-ppc/translate_init.c b/target-ppc/translate_init.c= >> index 28a9c2e73156..cfb1bc088950 100644 >> --- a/target-ppc/translate_init.c >> +++ b/target-ppc/translate_init.c >> @@ -8161,6 +8161,18 @@ static void gen_spr_power8_ic(CPUPPCState *env)= >> #endif >> } >> =20 >> +static void gen_spr_power8_book4(CPUPPCState *env) >> +{ >> + /* Add a number of P8 book4 registers */ >> +#if !defined(CONFIG_USER_ONLY) >> + spr_register_hv(env, SPR_MPPR, "MPPR", >> + SPR_NOACCESS, SPR_NOACCESS, >> + &spr_read_generic, SPR_NOACCESS, >> + &spr_read_generic, &spr_write_generic, >> + 0); >> +#endif >> +} >> + >> static void init_proc_book3s_64(CPUPPCState *env, int version) >> { >> gen_spr_ne_601(env); >> @@ -8216,6 +8228,7 @@ static void init_proc_book3s_64(CPUPPCState *env= , int version) >> gen_spr_power8_rpr(env); >> gen_spr_power8_dbell(env); >> gen_spr_power8_ic(env); >> + gen_spr_power8_book4(env); >> } >> if (version < BOOK3S_CPU_POWER8) { >> gen_spr_book3s_dbg(env); >=20 --r0vKrXXruM12Mg0qg24H9pxTD6K7pNuVj Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (GNU/Linux) iQIcBAEBAgAGBQJW6PpjAAoJEC7Z13T+cC21xsUP/247L8hKOgkH63BHg497LJEF h7EYAQVSYzhfougcmpcHUBgqeBn+qpnyVlzjJ2rmaLGn2yu3nJ7xQ1xx5OMhWzqp 9gvAPpDlTLbAQBT++0hFe+NZYUZxOn8eeMhoBCWP5vG5RIcuyWuRS/x6pRYrH64l YyWWO5OJfx7VUglk6Xeu0baX+LZgwyINnfVCzMVuNx0F0k6dtIkX5tfQ7CJYzi0i x3FzLMBjWfs3YtVqCnybB+TVHocYdbI7uzdC8k9XdpMjKy1ViFmm2keeAhPScdtM 7YFAQG2sBfY9ovZv8dJMIJRzjcPW/cU9URNcastAYe1mCz2BLgZLaUu/9bur+vMY LzRFm/+jJF4jewJxTHYHAaytQxbr8rQdNQI0yS5ogMO2652CPfxwqXhWggW46kE+ afLg2aEf3yXXTwboxnUjBqHuiFzkPva8eWP++tMInhp4iGSbp1vJHMhX5VRg6dKM uLL/lrrMV+kd/tV1XEy6BxyZKXbG14MADX1lyMuMtVHj1h8FfaXuIo+UK8jnLLR4 f0RfEAlVlSN9GIhiul4mvoU0dHu4hii5y8hJiLYlhjWxPTBxrEDE5mWAsA+SOKXW SmhgmQZ3+QuBOMQArSwrApyKilA06dYT922+Em6lYf6x4iJwM33+E65Wnms2EyAw Bl7ff4YSClj6lm4mIGs1 =P0oY -----END PGP SIGNATURE----- --r0vKrXXruM12Mg0qg24H9pxTD6K7pNuVj--