Received: from eggs.gnu.org ([2001:4830:134:3::10]:55082) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xvafi-0000ZQ-3h for qemu-devel@nongnu.org; Mon, 01 Dec 2014 18:46:33 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Xvafa-0001Jb-ER for qemu-devel@nongnu.org; Mon, 01 Dec 2014 18:46:25 -0500 Received: from mx2.rt-rk.com ([89.216.37.149]:56558 helo=mail.rt-rk.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XvafZ-0001Ct-SU for qemu-devel@nongnu.org; Mon, 01 Dec 2014 18:46:18 -0500 From: "Petar Jovanovic" References: <000e01d00dbf$36b8f4f0$a42aded0$@rt-rk.com> In-Reply-To: <000e01d00dbf$36b8f4f0$a42aded0$@rt-rk.com> Date: Tue, 2 Dec 2014 00:45:52 +0100 Message-ID: <001501d00dc0$f1e038f0$d5a0aad0$@rt-rk.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_0016_01D00DC9.53A90DC0" Content-Language: en-us Subject: Re: [Qemu-devel] [PATCH] target-mips: add CPU definition for MIPS-II List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: 'Vasileios Kalintiris' Cc: 'Leon Alrae' , qemu-devel@nongnu.org This is a multipart message in MIME format. ------=_NextPart_000_0016_01D00DC9.53A90DC0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Adding (another) generic model for an old ISA revision is rather discouraged in QEMU trunk. Can you add a particular real CPU model? Regards, Petar ________________________________________ From: Vasileios Kalintiris Sent: 25 November 2014 11:04 To: address@hidden Cc: Leon Alrae; address@hidden Subject: [PATCH] target-mips: add CPU definition for MIPS-II Add mips2-generic among CPU definitions for MIPS. Signed-off-by: Vasileios Kalintiris --- target-mips/translate_init.c | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/target-mips/translate_init.c b/target-mips/translate_init.c index 148b394..d4b1cd8 100644 --- a/target-mips/translate_init.c +++ b/target-mips/translate_init.c @@ -108,6 +108,29 @@ struct mips_def_t { static const mips_def_t mips_defs[] = { { + /* A generic CPU providing MIPS-II features. + FIXME: Eventually this should be replaced by a real CPU model. */ + .name = "mips2-generic", + .CP0_PRid = 0x00018000, + .CP0_Config0 = MIPS_CONFIG0 | (MMU_TYPE_R4000 << CP0C0_MT), + .CP0_Config1 = MIPS_CONFIG1 | (1 << CP0C1_FP) | (15 << CP0C1_MMU) | + (0 << CP0C1_IS) | (3 << CP0C1_IL) | (1 << CP0C1_IA) | + (0 << CP0C1_DS) | (3 << CP0C1_DL) | (1 << CP0C1_DA) | + (0 << CP0C1_CA), + .CP0_Config2 = MIPS_CONFIG2, + .CP0_Config3 = MIPS_CONFIG3, + .CP0_LLAddr_rw_bitmask = 0, + .CP0_LLAddr_shift = 4, + .SYNCI_Step = 32, + .CCRes = 2, + .CP0_Status_rw_bitmask = 0x30000011, + .CP1_fcr0 = (1 << FCR0_W) | (1 << FCR0_D) | (1 << FCR0_S), + .SEGBITS = 32, + .PABITS = 32, + .insn_flags = CPU_MIPS2, + .mmu_type = MMU_TYPE_R4000, + }, + { .name = "4Kc", .CP0_PRid = 0x00018000, .CP0_Config0 = MIPS_CONFIG0 | (MMU_TYPE_R4000 << CP0C0_MT), -- ping ------=_NextPart_000_0016_01D00DC9.53A90DC0 Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable

Adding = (another) generic model for an old ISA revision is = rather

discouraged in QEMU trunk. Can = you add a particular real CPU model?

 

Regards,

Petar

________________________________________

From: = Vasileios Kalintiris

Sent: = 25 November 2014 11:04

To: = address@hidden

Cc: = Leon Alrae; address@hidden

Subject: [PATCH] target-mips: add CPU definition for = MIPS-II

 

Add = mips2-generic among CPU definitions for MIPS.

 

Signed-off-by: Vasileios Kalintiris = <address@hidden>

---

target-mips/translate_init.c | 23 = +++++++++++++++++++++++

1 file = changed, 23 insertions(+)

 

diff = --git a/target-mips/translate_init.c = b/target-mips/translate_init.c

index 148b394..d4b1cd8 100644

--- = a/target-mips/translate_init.c

+++ = b/target-mips/translate_init.c

@@ -108,6 +108,29 @@ struct mips_def_t = {

static = const mips_def_t mips_defs[] =3D

{

     {

+        /* A = generic CPU providing MIPS-II features.

+         =   FIXME: Eventually this should be replaced by a real CPU model. = */

+        .name =3D = "mips2-generic",

+        .CP0_PRid = =3D 0x00018000,

+        = .CP0_Config0 =3D MIPS_CONFIG0 | (MMU_TYPE_R4000 << = CP0C0_MT),

+        = .CP0_Config1 =3D MIPS_CONFIG1 | (1 << CP0C1_FP) | (15 << = CP0C1_MMU) |

+         =              = (0 << CP0C1_IS) | (3 << CP0C1_IL) | (1 << CP0C1_IA) = |

+         =              = (0 << CP0C1_DS) | (3 << CP0C1_DL) | (1 << CP0C1_DA) = |

+         =              = (0 << CP0C1_CA),

+        = .CP0_Config2 =3D MIPS_CONFIG2,

+        = .CP0_Config3 =3D MIPS_CONFIG3,

+        = .CP0_LLAddr_rw_bitmask =3D 0,

+        = .CP0_LLAddr_shift =3D 4,

+        = .SYNCI_Step =3D 32,

+        .CCRes =3D = 2,

+        = .CP0_Status_rw_bitmask =3D 0x30000011,

+        .CP1_fcr0 = =3D (1 << FCR0_W) | (1 << FCR0_D) | (1 << = FCR0_S),

+        .SEGBITS = =3D 32,

+        .PABITS = =3D 32,

+        = .insn_flags =3D CPU_MIPS2,

+        .mmu_type = =3D MMU_TYPE_R4000,

+    },

+    {

         .name = =3D "4Kc",

         = .CP0_PRid =3D 0x00018000,

         = .CP0_Config0 =3D MIPS_CONFIG0 | (MMU_TYPE_R4000 << = CP0C0_MT),

--

 

ping

 

------=_NextPart_000_0016_01D00DC9.53A90DC0--