Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

target-ppc: Turn descriptive CPU family comments into device descript…

…ions

This gets rid of some more overly long comments that have lost most of
their purpose now that in most cases there's only two functions left per
CPU family.

The class field is inherited by the actual CPU models, so override it.

Signed-off-by: Andreas Färber <afaerber@suse.de>
Signed-off-by: Alexander Graf <agraf@suse.de>
  • Loading branch information...
commit ca5dff0a3e532ea9168934fc361e96d969007284 1 parent ba9fd9f
Andreas Färber authored agraf committed

Showing 1 changed file with 107 additions and 52 deletions. Show diff stats Hide diff stats

  1. +107 52 target-ppc/translate_init.c
159 target-ppc/translate_init.c
@@ -3274,7 +3274,6 @@ static int check_pow_hid0_74xx (CPUPPCState *env)
3274 3274 \
3275 3275 static void glue(glue(ppc_, _name), _cpu_family_class_init)
3276 3276
3277   -/* PowerPC 401 */
3278 3277 static void init_proc_401 (CPUPPCState *env)
3279 3278 {
3280 3279 gen_spr_40x(env);
@@ -3292,8 +3291,10 @@ static void init_proc_401 (CPUPPCState *env)
3292 3291
3293 3292 POWERPC_FAMILY(401)(ObjectClass *oc, void *data)
3294 3293 {
  3294 + DeviceClass *dc = DEVICE_CLASS(oc);
3295 3295 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
3296 3296
  3297 + dc->desc = "PowerPC 401";
3297 3298 pcc->init_proc = init_proc_401;
3298 3299 pcc->check_pow = check_pow_nocheck;
3299 3300 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING |
@@ -3312,7 +3313,6 @@ POWERPC_FAMILY(401)(ObjectClass *oc, void *data)
3312 3313 POWERPC_FLAG_BUS_CLK;
3313 3314 }
3314 3315
3315   -/* PowerPC 401x2 */
3316 3316 static void init_proc_401x2 (CPUPPCState *env)
3317 3317 {
3318 3318 gen_spr_40x(env);
@@ -3338,8 +3338,10 @@ static void init_proc_401x2 (CPUPPCState *env)
3338 3338
3339 3339 POWERPC_FAMILY(401x2)(ObjectClass *oc, void *data)
3340 3340 {
  3341 + DeviceClass *dc = DEVICE_CLASS(oc);
3341 3342 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
3342 3343
  3344 + dc->desc = "PowerPC 401x2";
3343 3345 pcc->init_proc = init_proc_401x2;
3344 3346 pcc->check_pow = check_pow_nocheck;
3345 3347 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -3359,7 +3361,6 @@ POWERPC_FAMILY(401x2)(ObjectClass *oc, void *data)
3359 3361 POWERPC_FLAG_BUS_CLK;
3360 3362 }
3361 3363
3362   -/* PowerPC 401x3 */
3363 3364 static void init_proc_401x3 (CPUPPCState *env)
3364 3365 {
3365 3366 gen_spr_40x(env);
@@ -3379,8 +3380,10 @@ static void init_proc_401x3 (CPUPPCState *env)
3379 3380
3380 3381 POWERPC_FAMILY(401x3)(ObjectClass *oc, void *data)
3381 3382 {
  3383 + DeviceClass *dc = DEVICE_CLASS(oc);
3382 3384 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
3383 3385
  3386 + dc->desc = "PowerPC 401x3";
3384 3387 pcc->init_proc = init_proc_401x3;
3385 3388 pcc->check_pow = check_pow_nocheck;
3386 3389 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -3400,7 +3403,6 @@ POWERPC_FAMILY(401x3)(ObjectClass *oc, void *data)
3400 3403 POWERPC_FLAG_BUS_CLK;
3401 3404 }
3402 3405
3403   -/* IOP480 */
3404 3406 static void init_proc_IOP480 (CPUPPCState *env)
3405 3407 {
3406 3408 gen_spr_40x(env);
@@ -3426,8 +3428,10 @@ static void init_proc_IOP480 (CPUPPCState *env)
3426 3428
3427 3429 POWERPC_FAMILY(IOP480)(ObjectClass *oc, void *data)
3428 3430 {
  3431 + DeviceClass *dc = DEVICE_CLASS(oc);
3429 3432 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
3430 3433
  3434 + dc->desc = "IOP480";
3431 3435 pcc->init_proc = init_proc_IOP480;
3432 3436 pcc->check_pow = check_pow_nocheck;
3433 3437 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING |
@@ -3447,7 +3451,6 @@ POWERPC_FAMILY(IOP480)(ObjectClass *oc, void *data)
3447 3451 POWERPC_FLAG_BUS_CLK;
3448 3452 }
3449 3453
3450   -/* PowerPC 403 */
3451 3454 static void init_proc_403 (CPUPPCState *env)
3452 3455 {
3453 3456 gen_spr_40x(env);
@@ -3466,8 +3469,10 @@ static void init_proc_403 (CPUPPCState *env)
3466 3469
3467 3470 POWERPC_FAMILY(403)(ObjectClass *oc, void *data)
3468 3471 {
  3472 + DeviceClass *dc = DEVICE_CLASS(oc);
3469 3473 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
3470 3474
  3475 + dc->desc = "PowerPC 403";
3471 3476 pcc->init_proc = init_proc_403;
3472 3477 pcc->check_pow = check_pow_nocheck;
3473 3478 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING |
@@ -3486,7 +3491,6 @@ POWERPC_FAMILY(403)(ObjectClass *oc, void *data)
3486 3491 POWERPC_FLAG_BUS_CLK;
3487 3492 }
3488 3493
3489   -/* PowerPC 403 GCX */
3490 3494 static void init_proc_403GCX (CPUPPCState *env)
3491 3495 {
3492 3496 gen_spr_40x(env);
@@ -3524,8 +3528,10 @@ static void init_proc_403GCX (CPUPPCState *env)
3524 3528
3525 3529 POWERPC_FAMILY(403GCX)(ObjectClass *oc, void *data)
3526 3530 {
  3531 + DeviceClass *dc = DEVICE_CLASS(oc);
3527 3532 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
3528 3533
  3534 + dc->desc = "PowerPC 403 GCX";
3529 3535 pcc->init_proc = init_proc_403GCX;
3530 3536 pcc->check_pow = check_pow_nocheck;
3531 3537 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING |
@@ -3545,7 +3551,6 @@ POWERPC_FAMILY(403GCX)(ObjectClass *oc, void *data)
3545 3551 POWERPC_FLAG_BUS_CLK;
3546 3552 }
3547 3553
3548   -/* PowerPC 405 */
3549 3554 static void init_proc_405 (CPUPPCState *env)
3550 3555 {
3551 3556 /* Time base */
@@ -3582,8 +3587,10 @@ static void init_proc_405 (CPUPPCState *env)
3582 3587
3583 3588 POWERPC_FAMILY(405)(ObjectClass *oc, void *data)
3584 3589 {
  3590 + DeviceClass *dc = DEVICE_CLASS(oc);
3585 3591 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
3586 3592
  3593 + dc->desc = "PowerPC 405";
3587 3594 pcc->init_proc = init_proc_405;
3588 3595 pcc->check_pow = check_pow_nocheck;
3589 3596 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -3603,7 +3610,6 @@ POWERPC_FAMILY(405)(ObjectClass *oc, void *data)
3603 3610 POWERPC_FLAG_DE | POWERPC_FLAG_BUS_CLK;
3604 3611 }
3605 3612
3606   -/* PowerPC 440 EP */
3607 3613 static void init_proc_440EP (CPUPPCState *env)
3608 3614 {
3609 3615 /* Time base */
@@ -3672,8 +3678,10 @@ static void init_proc_440EP (CPUPPCState *env)
3672 3678
3673 3679 POWERPC_FAMILY(440EP)(ObjectClass *oc, void *data)
3674 3680 {
  3681 + DeviceClass *dc = DEVICE_CLASS(oc);
3675 3682 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
3676 3683
  3684 + dc->desc = "PowerPC 440 EP";
3677 3685 pcc->init_proc = init_proc_440EP;
3678 3686 pcc->check_pow = check_pow_nocheck;
3679 3687 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING |
@@ -3696,7 +3704,6 @@ POWERPC_FAMILY(440EP)(ObjectClass *oc, void *data)
3696 3704 POWERPC_FLAG_DE | POWERPC_FLAG_BUS_CLK;
3697 3705 }
3698 3706
3699   -/* PowerPC 440 GP */
3700 3707 static void init_proc_440GP (CPUPPCState *env)
3701 3708 {
3702 3709 /* Time base */
@@ -3747,8 +3754,10 @@ static void init_proc_440GP (CPUPPCState *env)
3747 3754
3748 3755 POWERPC_FAMILY(440GP)(ObjectClass *oc, void *data)
3749 3756 {
  3757 + DeviceClass *dc = DEVICE_CLASS(oc);
3750 3758 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
3751 3759
  3760 + dc->desc = "PowerPC 440 GP";
3752 3761 pcc->init_proc = init_proc_440GP;
3753 3762 pcc->check_pow = check_pow_nocheck;
3754 3763 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING |
@@ -3768,7 +3777,6 @@ POWERPC_FAMILY(440GP)(ObjectClass *oc, void *data)
3768 3777 POWERPC_FLAG_DE | POWERPC_FLAG_BUS_CLK;
3769 3778 }
3770 3779
3771   -/* PowerPC 440x4 */
3772 3780 static void init_proc_440x4 (CPUPPCState *env)
3773 3781 {
3774 3782 /* Time base */
@@ -3819,8 +3827,10 @@ static void init_proc_440x4 (CPUPPCState *env)
3819 3827
3820 3828 POWERPC_FAMILY(440x4)(ObjectClass *oc, void *data)
3821 3829 {
  3830 + DeviceClass *dc = DEVICE_CLASS(oc);
3822 3831 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
3823 3832
  3833 + dc->desc = "PowerPC 440x4";
3824 3834 pcc->init_proc = init_proc_440x4;
3825 3835 pcc->check_pow = check_pow_nocheck;
3826 3836 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING |
@@ -3840,7 +3850,6 @@ POWERPC_FAMILY(440x4)(ObjectClass *oc, void *data)
3840 3850 POWERPC_FLAG_DE | POWERPC_FLAG_BUS_CLK;
3841 3851 }
3842 3852
3843   -/* PowerPC 440x5 */
3844 3853 static void init_proc_440x5 (CPUPPCState *env)
3845 3854 {
3846 3855 /* Time base */
@@ -3909,8 +3918,10 @@ static void init_proc_440x5 (CPUPPCState *env)
3909 3918
3910 3919 POWERPC_FAMILY(440x5)(ObjectClass *oc, void *data)
3911 3920 {
  3921 + DeviceClass *dc = DEVICE_CLASS(oc);
3912 3922 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
3913 3923
  3924 + dc->desc = "PowerPC 440x5";
3914 3925 pcc->init_proc = init_proc_440x5;
3915 3926 pcc->check_pow = check_pow_nocheck;
3916 3927 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING |
@@ -3930,7 +3941,6 @@ POWERPC_FAMILY(440x5)(ObjectClass *oc, void *data)
3930 3941 POWERPC_FLAG_DE | POWERPC_FLAG_BUS_CLK;
3931 3942 }
3932 3943
3933   -/* PowerPC 460 (guessed) */
3934 3944 static void init_proc_460 (CPUPPCState *env)
3935 3945 {
3936 3946 /* Time base */
@@ -4004,8 +4014,10 @@ static void init_proc_460 (CPUPPCState *env)
4004 4014
4005 4015 POWERPC_FAMILY(460)(ObjectClass *oc, void *data)
4006 4016 {
  4017 + DeviceClass *dc = DEVICE_CLASS(oc);
4007 4018 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
4008 4019
  4020 + dc->desc = "PowerPC 460 (guessed)";
4009 4021 pcc->init_proc = init_proc_460;
4010 4022 pcc->check_pow = check_pow_nocheck;
4011 4023 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING |
@@ -4026,7 +4038,6 @@ POWERPC_FAMILY(460)(ObjectClass *oc, void *data)
4026 4038 POWERPC_FLAG_DE | POWERPC_FLAG_BUS_CLK;
4027 4039 }
4028 4040
4029   -/* PowerPC 460F (guessed) */
4030 4041 static void init_proc_460F (CPUPPCState *env)
4031 4042 {
4032 4043 /* Time base */
@@ -4100,8 +4111,10 @@ static void init_proc_460F (CPUPPCState *env)
4100 4111
4101 4112 POWERPC_FAMILY(460F)(ObjectClass *oc, void *data)
4102 4113 {
  4114 + DeviceClass *dc = DEVICE_CLASS(oc);
4103 4115 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
4104 4116
  4117 + dc->desc = "PowerPC 460F (guessed)";
4105 4118 pcc->init_proc = init_proc_460F;
4106 4119 pcc->check_pow = check_pow_nocheck;
4107 4120 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING |
@@ -4125,7 +4138,6 @@ POWERPC_FAMILY(460F)(ObjectClass *oc, void *data)
4125 4138 POWERPC_FLAG_DE | POWERPC_FLAG_BUS_CLK;
4126 4139 }
4127 4140
4128   -/* Freescale 5xx cores (aka RCPU) */
4129 4141 static void init_proc_MPC5xx (CPUPPCState *env)
4130 4142 {
4131 4143 /* Time base */
@@ -4140,8 +4152,10 @@ static void init_proc_MPC5xx (CPUPPCState *env)
4140 4152
4141 4153 POWERPC_FAMILY(MPC5xx)(ObjectClass *oc, void *data)
4142 4154 {
  4155 + DeviceClass *dc = DEVICE_CLASS(oc);
4143 4156 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
4144 4157
  4158 + dc->desc = "Freescale 5xx cores (aka RCPU)";
4145 4159 pcc->init_proc = init_proc_MPC5xx;
4146 4160 pcc->check_pow = check_pow_none;
4147 4161 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING |
@@ -4158,7 +4172,6 @@ POWERPC_FAMILY(MPC5xx)(ObjectClass *oc, void *data)
4158 4172 POWERPC_FLAG_BUS_CLK;
4159 4173 }
4160 4174
4161   -/* Freescale 8xx cores (aka PowerQUICC) */
4162 4175 static void init_proc_MPC8xx (CPUPPCState *env)
4163 4176 {
4164 4177 /* Time base */
@@ -4173,8 +4186,10 @@ static void init_proc_MPC8xx (CPUPPCState *env)
4173 4186
4174 4187 POWERPC_FAMILY(MPC8xx)(ObjectClass *oc, void *data)
4175 4188 {
  4189 + DeviceClass *dc = DEVICE_CLASS(oc);
4176 4190 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
4177 4191
  4192 + dc->desc = "Freescale 8xx cores (aka PowerQUICC)";
4178 4193 pcc->init_proc = init_proc_MPC8xx;
4179 4194 pcc->check_pow = check_pow_none;
4180 4195 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING |
@@ -4191,7 +4206,7 @@ POWERPC_FAMILY(MPC8xx)(ObjectClass *oc, void *data)
4191 4206 }
4192 4207
4193 4208 /* Freescale 82xx cores (aka PowerQUICC-II) */
4194   -/* PowerPC G2 */
  4209 +
4195 4210 static void init_proc_G2 (CPUPPCState *env)
4196 4211 {
4197 4212 gen_spr_ne_601(env);
@@ -4234,8 +4249,10 @@ static void init_proc_G2 (CPUPPCState *env)
4234 4249
4235 4250 POWERPC_FAMILY(G2)(ObjectClass *oc, void *data)
4236 4251 {
  4252 + DeviceClass *dc = DEVICE_CLASS(oc);
4237 4253 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
4238 4254
  4255 + dc->desc = "PowerPC G2";
4239 4256 pcc->init_proc = init_proc_G2;
4240 4257 pcc->check_pow = check_pow_hid0;
4241 4258 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -4255,7 +4272,6 @@ POWERPC_FAMILY(G2)(ObjectClass *oc, void *data)
4255 4272 POWERPC_FLAG_BE | POWERPC_FLAG_BUS_CLK;
4256 4273 }
4257 4274
4258   -/* PowerPC G2LE */
4259 4275 static void init_proc_G2LE (CPUPPCState *env)
4260 4276 {
4261 4277 gen_spr_ne_601(env);
@@ -4298,8 +4314,10 @@ static void init_proc_G2LE (CPUPPCState *env)
4298 4314
4299 4315 POWERPC_FAMILY(G2LE)(ObjectClass *oc, void *data)
4300 4316 {
  4317 + DeviceClass *dc = DEVICE_CLASS(oc);
4301 4318 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
4302 4319
  4320 + dc->desc = "PowerPC G2LE";
4303 4321 pcc->init_proc = init_proc_G2LE;
4304 4322 pcc->check_pow = check_pow_hid0;
4305 4323 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -4319,7 +4337,6 @@ POWERPC_FAMILY(G2LE)(ObjectClass *oc, void *data)
4319 4337 POWERPC_FLAG_BE | POWERPC_FLAG_BUS_CLK;
4320 4338 }
4321 4339
4322   -/* e200 core */
4323 4340 static void init_proc_e200 (CPUPPCState *env)
4324 4341 {
4325 4342 /* Time base */
@@ -4429,8 +4446,10 @@ static void init_proc_e200 (CPUPPCState *env)
4429 4446
4430 4447 POWERPC_FAMILY(e200)(ObjectClass *oc, void *data)
4431 4448 {
  4449 + DeviceClass *dc = DEVICE_CLASS(oc);
4432 4450 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
4433 4451
  4452 + dc->desc = "e200 core";
4434 4453 pcc->init_proc = init_proc_e200;
4435 4454 pcc->check_pow = check_pow_hid0;
4436 4455 /* XXX: unimplemented instructions:
@@ -4460,7 +4479,6 @@ POWERPC_FAMILY(e200)(ObjectClass *oc, void *data)
4460 4479 POWERPC_FLAG_BUS_CLK;
4461 4480 }
4462 4481
4463   -/* e300 core */
4464 4482 static void init_proc_e300 (CPUPPCState *env)
4465 4483 {
4466 4484 gen_spr_ne_601(env);
@@ -4496,8 +4514,10 @@ static void init_proc_e300 (CPUPPCState *env)
4496 4514
4497 4515 POWERPC_FAMILY(e300)(ObjectClass *oc, void *data)
4498 4516 {
  4517 + DeviceClass *dc = DEVICE_CLASS(oc);
4499 4518 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
4500 4519
  4520 + dc->desc = "e300 core";
4501 4521 pcc->init_proc = init_proc_e300;
4502 4522 pcc->check_pow = check_pow_hid0;
4503 4523 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -4517,11 +4537,6 @@ POWERPC_FAMILY(e300)(ObjectClass *oc, void *data)
4517 4537 POWERPC_FLAG_BE | POWERPC_FLAG_BUS_CLK;
4518 4538 }
4519 4539
4520   -/* e500v1 core */
4521   -/* e500v2 core */
4522   -/* e500mc core */
4523   -/* e5500 core */
4524   -
4525 4540 #if !defined(CONFIG_USER_ONLY)
4526 4541 static void spr_write_mas73(void *opaque, int sprn, int gprn)
4527 4542 {
@@ -4738,8 +4753,10 @@ static void init_proc_e500v1(CPUPPCState *env)
4738 4753
4739 4754 POWERPC_FAMILY(e500v1)(ObjectClass *oc, void *data)
4740 4755 {
  4756 + DeviceClass *dc = DEVICE_CLASS(oc);
4741 4757 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
4742 4758
  4759 + dc->desc = "e500v1 core";
4743 4760 pcc->init_proc = init_proc_e500v1;
4744 4761 pcc->check_pow = check_pow_hid0;
4745 4762 pcc->insns_flags = PPC_INSNS_BASE | PPC_ISEL |
@@ -4766,8 +4783,10 @@ static void init_proc_e500v2(CPUPPCState *env)
4766 4783
4767 4784 POWERPC_FAMILY(e500v2)(ObjectClass *oc, void *data)
4768 4785 {
  4786 + DeviceClass *dc = DEVICE_CLASS(oc);
4769 4787 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
4770 4788
  4789 + dc->desc = "e500v2 core";
4771 4790 pcc->init_proc = init_proc_e500v2;
4772 4791 pcc->check_pow = check_pow_hid0;
4773 4792 pcc->insns_flags = PPC_INSNS_BASE | PPC_ISEL |
@@ -4794,8 +4813,10 @@ static void init_proc_e500mc(CPUPPCState *env)
4794 4813
4795 4814 POWERPC_FAMILY(e500mc)(ObjectClass *oc, void *data)
4796 4815 {
  4816 + DeviceClass *dc = DEVICE_CLASS(oc);
4797 4817 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
4798 4818
  4819 + dc->desc = "e500mc core";
4799 4820 pcc->init_proc = init_proc_e500mc;
4800 4821 pcc->check_pow = check_pow_none;
4801 4822 pcc->insns_flags = PPC_INSNS_BASE | PPC_ISEL |
@@ -4825,8 +4846,10 @@ static void init_proc_e5500(CPUPPCState *env)
4825 4846
4826 4847 POWERPC_FAMILY(e5500)(ObjectClass *oc, void *data)
4827 4848 {
  4849 + DeviceClass *dc = DEVICE_CLASS(oc);
4828 4850 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
4829 4851
  4852 + dc->desc = "e5500 core";
4830 4853 pcc->init_proc = init_proc_e5500;
4831 4854 pcc->check_pow = check_pow_none;
4832 4855 pcc->insns_flags = PPC_INSNS_BASE | PPC_ISEL |
@@ -4856,15 +4879,16 @@ POWERPC_FAMILY(e5500)(ObjectClass *oc, void *data)
4856 4879 #if defined(TODO)
4857 4880 POWERPC_FAMILY(POWER)(ObjectClass *oc, void *data)
4858 4881 {
  4882 + DeviceClass *dc = DEVICE_CLASS(oc);
4859 4883 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
4860 4884
  4885 + dc->desc = "POWER";
4861 4886 pcc->insns_flags = XXX_TODO;
4862 4887 /* POWER RSC (from RAD6000) */
4863 4888 pcc->msr_mask = 0x00000000FEF0ULL;
4864 4889 }
4865 4890 #endif /* TODO */
4866 4891
4867   -/* PowerPC 601 */
4868 4892 #define POWERPC_MSRR_601 (0x0000000000001040ULL)
4869 4893
4870 4894 static void init_proc_601 (CPUPPCState *env)
@@ -4906,8 +4930,10 @@ static void init_proc_601 (CPUPPCState *env)
4906 4930
4907 4931 POWERPC_FAMILY(601)(ObjectClass *oc, void *data)
4908 4932 {
  4933 + DeviceClass *dc = DEVICE_CLASS(oc);
4909 4934 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
4910 4935
  4936 + dc->desc = "PowerPC 601";
4911 4937 pcc->init_proc = init_proc_601;
4912 4938 pcc->check_pow = check_pow_none;
4913 4939 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_POWER_BR |
@@ -4924,7 +4950,6 @@ POWERPC_FAMILY(601)(ObjectClass *oc, void *data)
4924 4950 pcc->flags = POWERPC_FLAG_SE | POWERPC_FLAG_RTC_CLK;
4925 4951 }
4926 4952
4927   -/* PowerPC 601v */
4928 4953 #define POWERPC_MSRR_601v (0x0000000000001040ULL)
4929 4954
4930 4955 static void init_proc_601v (CPUPPCState *env)
@@ -4939,8 +4964,10 @@ static void init_proc_601v (CPUPPCState *env)
4939 4964
4940 4965 POWERPC_FAMILY(601v)(ObjectClass *oc, void *data)
4941 4966 {
  4967 + DeviceClass *dc = DEVICE_CLASS(oc);
4942 4968 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
4943 4969
  4970 + dc->desc = "PowerPC 601v";
4944 4971 pcc->init_proc = init_proc_601v;
4945 4972 pcc->check_pow = check_pow_none;
4946 4973 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_POWER_BR |
@@ -4957,7 +4984,6 @@ POWERPC_FAMILY(601v)(ObjectClass *oc, void *data)
4957 4984 pcc->flags = POWERPC_FLAG_SE | POWERPC_FLAG_RTC_CLK;
4958 4985 }
4959 4986
4960   -/* PowerPC 602 */
4961 4987 static void init_proc_602 (CPUPPCState *env)
4962 4988 {
4963 4989 gen_spr_ne_601(env);
@@ -4987,8 +5013,10 @@ static void init_proc_602 (CPUPPCState *env)
4987 5013
4988 5014 POWERPC_FAMILY(602)(ObjectClass *oc, void *data)
4989 5015 {
  5016 + DeviceClass *dc = DEVICE_CLASS(oc);
4990 5017 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
4991 5018
  5019 + dc->desc = "PowerPC 602";
4992 5020 pcc->init_proc = init_proc_602;
4993 5021 pcc->check_pow = check_pow_hid0;
4994 5022 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -5009,7 +5037,6 @@ POWERPC_FAMILY(602)(ObjectClass *oc, void *data)
5009 5037 POWERPC_FLAG_BE | POWERPC_FLAG_BUS_CLK;
5010 5038 }
5011 5039
5012   -/* PowerPC 603 */
5013 5040 static void init_proc_603 (CPUPPCState *env)
5014 5041 {
5015 5042 gen_spr_ne_601(env);
@@ -5039,8 +5066,10 @@ static void init_proc_603 (CPUPPCState *env)
5039 5066
5040 5067 POWERPC_FAMILY(603)(ObjectClass *oc, void *data)
5041 5068 {
  5069 + DeviceClass *dc = DEVICE_CLASS(oc);
5042 5070 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
5043 5071
  5072 + dc->desc = "PowerPC 603";
5044 5073 pcc->init_proc = init_proc_603;
5045 5074 pcc->check_pow = check_pow_hid0;
5046 5075 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -5060,7 +5089,6 @@ POWERPC_FAMILY(603)(ObjectClass *oc, void *data)
5060 5089 POWERPC_FLAG_BE | POWERPC_FLAG_BUS_CLK;
5061 5090 }
5062 5091
5063   -/* PowerPC 603e */
5064 5092 static void init_proc_603E (CPUPPCState *env)
5065 5093 {
5066 5094 gen_spr_ne_601(env);
@@ -5095,8 +5123,10 @@ static void init_proc_603E (CPUPPCState *env)
5095 5123
5096 5124 POWERPC_FAMILY(603E)(ObjectClass *oc, void *data)
5097 5125 {
  5126 + DeviceClass *dc = DEVICE_CLASS(oc);
5098 5127 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
5099 5128
  5129 + dc->desc = "PowerPC 603e";
5100 5130 pcc->init_proc = init_proc_603E;
5101 5131 pcc->check_pow = check_pow_hid0;
5102 5132 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -5116,7 +5146,6 @@ POWERPC_FAMILY(603E)(ObjectClass *oc, void *data)
5116 5146 POWERPC_FLAG_BE | POWERPC_FLAG_BUS_CLK;
5117 5147 }
5118 5148
5119   -/* PowerPC 604 */
5120 5149 static void init_proc_604 (CPUPPCState *env)
5121 5150 {
5122 5151 gen_spr_ne_601(env);
@@ -5140,8 +5169,10 @@ static void init_proc_604 (CPUPPCState *env)
5140 5169
5141 5170 POWERPC_FAMILY(604)(ObjectClass *oc, void *data)
5142 5171 {
  5172 + DeviceClass *dc = DEVICE_CLASS(oc);
5143 5173 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
5144 5174
  5175 + dc->desc = "PowerPC 604";
5145 5176 pcc->init_proc = init_proc_604;
5146 5177 pcc->check_pow = check_pow_nocheck;
5147 5178 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -5161,7 +5192,6 @@ POWERPC_FAMILY(604)(ObjectClass *oc, void *data)
5161 5192 POWERPC_FLAG_PMM | POWERPC_FLAG_BUS_CLK;
5162 5193 }
5163 5194
5164   -/* PowerPC 604E */
5165 5195 static void init_proc_604E (CPUPPCState *env)
5166 5196 {
5167 5197 gen_spr_ne_601(env);
@@ -5205,8 +5235,10 @@ static void init_proc_604E (CPUPPCState *env)
5205 5235
5206 5236 POWERPC_FAMILY(604E)(ObjectClass *oc, void *data)
5207 5237 {
  5238 + DeviceClass *dc = DEVICE_CLASS(oc);
5208 5239 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
5209 5240
  5241 + dc->desc = "PowerPC 604E";
5210 5242 pcc->init_proc = init_proc_604E;
5211 5243 pcc->check_pow = check_pow_nocheck;
5212 5244 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -5226,7 +5258,6 @@ POWERPC_FAMILY(604E)(ObjectClass *oc, void *data)
5226 5258 POWERPC_FLAG_PMM | POWERPC_FLAG_BUS_CLK;
5227 5259 }
5228 5260
5229   -/* PowerPC 740 */
5230 5261 static void init_proc_740 (CPUPPCState *env)
5231 5262 {
5232 5263 gen_spr_ne_601(env);
@@ -5257,8 +5288,10 @@ static void init_proc_740 (CPUPPCState *env)
5257 5288
5258 5289 POWERPC_FAMILY(740)(ObjectClass *oc, void *data)
5259 5290 {
  5291 + DeviceClass *dc = DEVICE_CLASS(oc);
5260 5292 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
5261 5293
  5294 + dc->desc = "PowerPC 740";
5262 5295 pcc->init_proc = init_proc_740;
5263 5296 pcc->check_pow = check_pow_hid0;
5264 5297 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -5278,7 +5311,6 @@ POWERPC_FAMILY(740)(ObjectClass *oc, void *data)
5278 5311 POWERPC_FLAG_PMM | POWERPC_FLAG_BUS_CLK;
5279 5312 }
5280 5313
5281   -/* PowerPC 750 */
5282 5314 static void init_proc_750 (CPUPPCState *env)
5283 5315 {
5284 5316 gen_spr_ne_601(env);
@@ -5317,8 +5349,10 @@ static void init_proc_750 (CPUPPCState *env)
5317 5349
5318 5350 POWERPC_FAMILY(750)(ObjectClass *oc, void *data)
5319 5351 {
  5352 + DeviceClass *dc = DEVICE_CLASS(oc);
5320 5353 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
5321 5354
  5355 + dc->desc = "PowerPC 750";
5322 5356 pcc->init_proc = init_proc_750;
5323 5357 pcc->check_pow = check_pow_hid0;
5324 5358 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -5338,7 +5372,6 @@ POWERPC_FAMILY(750)(ObjectClass *oc, void *data)
5338 5372 POWERPC_FLAG_PMM | POWERPC_FLAG_BUS_CLK;
5339 5373 }
5340 5374
5341   -/* PowerPC 750 CL */
5342 5375 static void init_proc_750cl (CPUPPCState *env)
5343 5376 {
5344 5377 gen_spr_ne_601(env);
@@ -5462,8 +5495,10 @@ static void init_proc_750cl (CPUPPCState *env)
5462 5495
5463 5496 POWERPC_FAMILY(750cl)(ObjectClass *oc, void *data)
5464 5497 {
  5498 + DeviceClass *dc = DEVICE_CLASS(oc);
5465 5499 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
5466 5500
  5501 + dc->desc = "PowerPC 750 CL";
5467 5502 pcc->init_proc = init_proc_750cl;
5468 5503 pcc->check_pow = check_pow_hid0;
5469 5504 /* XXX: not implemented:
@@ -5521,7 +5556,6 @@ POWERPC_FAMILY(750cl)(ObjectClass *oc, void *data)
5521 5556 POWERPC_FLAG_PMM | POWERPC_FLAG_BUS_CLK;
5522 5557 }
5523 5558
5524   -/* PowerPC 750CX */
5525 5559 static void init_proc_750cx (CPUPPCState *env)
5526 5560 {
5527 5561 gen_spr_ne_601(env);
@@ -5564,8 +5598,10 @@ static void init_proc_750cx (CPUPPCState *env)
5564 5598
5565 5599 POWERPC_FAMILY(750cx)(ObjectClass *oc, void *data)
5566 5600 {
  5601 + DeviceClass *dc = DEVICE_CLASS(oc);
5567 5602 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
5568 5603
  5604 + dc->desc = "PowerPC 750CX";
5569 5605 pcc->init_proc = init_proc_750cx;
5570 5606 pcc->check_pow = check_pow_hid0;
5571 5607 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -5585,7 +5621,6 @@ POWERPC_FAMILY(750cx)(ObjectClass *oc, void *data)
5585 5621 POWERPC_FLAG_PMM | POWERPC_FLAG_BUS_CLK;
5586 5622 }
5587 5623
5588   -/* PowerPC 750FX */
5589 5624 static void init_proc_750fx (CPUPPCState *env)
5590 5625 {
5591 5626 gen_spr_ne_601(env);
@@ -5633,8 +5668,10 @@ static void init_proc_750fx (CPUPPCState *env)
5633 5668
5634 5669 POWERPC_FAMILY(750fx)(ObjectClass *oc, void *data)
5635 5670 {
  5671 + DeviceClass *dc = DEVICE_CLASS(oc);
5636 5672 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
5637 5673
  5674 + dc->desc = "PowerPC 750FX";
5638 5675 pcc->init_proc = init_proc_750fx;
5639 5676 pcc->check_pow = check_pow_hid0;
5640 5677 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -5654,7 +5691,6 @@ POWERPC_FAMILY(750fx)(ObjectClass *oc, void *data)
5654 5691 POWERPC_FLAG_PMM | POWERPC_FLAG_BUS_CLK;
5655 5692 }
5656 5693
5657   -/* PowerPC 750GX */
5658 5694 static void init_proc_750gx (CPUPPCState *env)
5659 5695 {
5660 5696 gen_spr_ne_601(env);
@@ -5702,8 +5738,10 @@ static void init_proc_750gx (CPUPPCState *env)
5702 5738
5703 5739 POWERPC_FAMILY(750gx)(ObjectClass *oc, void *data)
5704 5740 {
  5741 + DeviceClass *dc = DEVICE_CLASS(oc);
5705 5742 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
5706 5743
  5744 + dc->desc = "PowerPC 750GX";
5707 5745 pcc->init_proc = init_proc_750gx;
5708 5746 pcc->check_pow = check_pow_hid0;
5709 5747 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -5723,7 +5761,6 @@ POWERPC_FAMILY(750gx)(ObjectClass *oc, void *data)
5723 5761 POWERPC_FLAG_PMM | POWERPC_FLAG_BUS_CLK;
5724 5762 }
5725 5763
5726   -/* PowerPC 745 */
5727 5764 static void init_proc_745 (CPUPPCState *env)
5728 5765 {
5729 5766 gen_spr_ne_601(env);
@@ -5762,8 +5799,10 @@ static void init_proc_745 (CPUPPCState *env)
5762 5799
5763 5800 POWERPC_FAMILY(745)(ObjectClass *oc, void *data)
5764 5801 {
  5802 + DeviceClass *dc = DEVICE_CLASS(oc);
5765 5803 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
5766 5804
  5805 + dc->desc = "PowerPC 745";
5767 5806 pcc->init_proc = init_proc_745;
5768 5807 pcc->check_pow = check_pow_hid0;
5769 5808 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -5783,7 +5822,6 @@ POWERPC_FAMILY(745)(ObjectClass *oc, void *data)
5783 5822 POWERPC_FLAG_PMM | POWERPC_FLAG_BUS_CLK;
5784 5823 }
5785 5824
5786   -/* PowerPC 755 */
5787 5825 static void init_proc_755 (CPUPPCState *env)
5788 5826 {
5789 5827 gen_spr_ne_601(env);
@@ -5833,8 +5871,10 @@ static void init_proc_755 (CPUPPCState *env)
5833 5871
5834 5872 POWERPC_FAMILY(755)(ObjectClass *oc, void *data)
5835 5873 {
  5874 + DeviceClass *dc = DEVICE_CLASS(oc);
5836 5875 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
5837 5876
  5877 + dc->desc = "PowerPC 755";
5838 5878 pcc->init_proc = init_proc_755;
5839 5879 pcc->check_pow = check_pow_hid0;
5840 5880 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -5854,7 +5894,6 @@ POWERPC_FAMILY(755)(ObjectClass *oc, void *data)
5854 5894 POWERPC_FLAG_PMM | POWERPC_FLAG_BUS_CLK;
5855 5895 }
5856 5896
5857   -/* PowerPC 7400 (aka G4) */
5858 5897 static void init_proc_7400 (CPUPPCState *env)
5859 5898 {
5860 5899 gen_spr_ne_601(env);
@@ -5887,8 +5926,10 @@ static void init_proc_7400 (CPUPPCState *env)
5887 5926
5888 5927 POWERPC_FAMILY(7400)(ObjectClass *oc, void *data)
5889 5928 {
  5929 + DeviceClass *dc = DEVICE_CLASS(oc);
5890 5930 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
5891 5931
  5932 + dc->desc = "PowerPC 7400 (aka G4)";
5892 5933 pcc->init_proc = init_proc_7400;
5893 5934 pcc->check_pow = check_pow_hid0;
5894 5935 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -5913,7 +5954,6 @@ POWERPC_FAMILY(7400)(ObjectClass *oc, void *data)
5913 5954 POWERPC_FLAG_BUS_CLK;
5914 5955 }
5915 5956
5916   -/* PowerPC 7410 (aka G4) */
5917 5957 static void init_proc_7410 (CPUPPCState *env)
5918 5958 {
5919 5959 gen_spr_ne_601(env);
@@ -5952,8 +5992,10 @@ static void init_proc_7410 (CPUPPCState *env)
5952 5992
5953 5993 POWERPC_FAMILY(7410)(ObjectClass *oc, void *data)
5954 5994 {
  5995 + DeviceClass *dc = DEVICE_CLASS(oc);
5955 5996 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
5956 5997
  5998 + dc->desc = "PowerPC 7410 (aka G4)";
5957 5999 pcc->init_proc = init_proc_7410;
5958 6000 pcc->check_pow = check_pow_hid0;
5959 6001 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -5978,7 +6020,6 @@ POWERPC_FAMILY(7410)(ObjectClass *oc, void *data)
5978 6020 POWERPC_FLAG_BUS_CLK;
5979 6021 }
5980 6022
5981   -/* PowerPC 7440 (aka G4) */
5982 6023 static void init_proc_7440 (CPUPPCState *env)
5983 6024 {
5984 6025 gen_spr_ne_601(env);
@@ -6043,8 +6084,10 @@ static void init_proc_7440 (CPUPPCState *env)
6043 6084
6044 6085 POWERPC_FAMILY(7440)(ObjectClass *oc, void *data)
6045 6086 {
  6087 + DeviceClass *dc = DEVICE_CLASS(oc);
6046 6088 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
6047 6089
  6090 + dc->desc = "PowerPC 7440 (aka G4)";
6048 6091 pcc->init_proc = init_proc_7440;
6049 6092 pcc->check_pow = check_pow_hid0_74xx;
6050 6093 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -6069,7 +6112,6 @@ POWERPC_FAMILY(7440)(ObjectClass *oc, void *data)
6069 6112 POWERPC_FLAG_BUS_CLK;
6070 6113 }
6071 6114
6072   -/* PowerPC 7450 (aka G4) */
6073 6115 static void init_proc_7450 (CPUPPCState *env)
6074 6116 {
6075 6117 gen_spr_ne_601(env);
@@ -6160,8 +6202,10 @@ static void init_proc_7450 (CPUPPCState *env)
6160 6202
6161 6203 POWERPC_FAMILY(7450)(ObjectClass *oc, void *data)
6162 6204 {
  6205 + DeviceClass *dc = DEVICE_CLASS(oc);
6163 6206 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
6164 6207
  6208 + dc->desc = "PowerPC 7450 (aka G4)";
6165 6209 pcc->init_proc = init_proc_7450;
6166 6210 pcc->check_pow = check_pow_hid0_74xx;
6167 6211 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -6186,7 +6230,6 @@ POWERPC_FAMILY(7450)(ObjectClass *oc, void *data)
6186 6230 POWERPC_FLAG_BUS_CLK;
6187 6231 }
6188 6232
6189   -/* PowerPC 7445 (aka G4) */
6190 6233 static void init_proc_7445 (CPUPPCState *env)
6191 6234 {
6192 6235 gen_spr_ne_601(env);
@@ -6280,8 +6323,10 @@ static void init_proc_7445 (CPUPPCState *env)
6280 6323
6281 6324 POWERPC_FAMILY(7445)(ObjectClass *oc, void *data)
6282 6325 {
  6326 + DeviceClass *dc = DEVICE_CLASS(oc);
6283 6327 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
6284 6328
  6329 + dc->desc = "PowerPC 7445 (aka G4)";
6285 6330 pcc->init_proc = init_proc_7445;
6286 6331 pcc->check_pow = check_pow_hid0_74xx;
6287 6332 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -6306,7 +6351,6 @@ POWERPC_FAMILY(7445)(ObjectClass *oc, void *data)
6306 6351 POWERPC_FLAG_BUS_CLK;
6307 6352 }
6308 6353
6309   -/* PowerPC 7455 (aka G4) */
6310 6354 static void init_proc_7455 (CPUPPCState *env)
6311 6355 {
6312 6356 gen_spr_ne_601(env);
@@ -6402,8 +6446,10 @@ static void init_proc_7455 (CPUPPCState *env)
6402 6446
6403 6447 POWERPC_FAMILY(7455)(ObjectClass *oc, void *data)
6404 6448 {
  6449 + DeviceClass *dc = DEVICE_CLASS(oc);
6405 6450 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
6406 6451
  6452 + dc->desc = "PowerPC 7455 (aka G4)";
6407 6453 pcc->init_proc = init_proc_7455;
6408 6454 pcc->check_pow = check_pow_hid0_74xx;
6409 6455 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -6428,7 +6474,6 @@ POWERPC_FAMILY(7455)(ObjectClass *oc, void *data)
6428 6474 POWERPC_FLAG_BUS_CLK;
6429 6475 }
6430 6476
6431   -/* PowerPC 7457 (aka G4) */
6432 6477 static void init_proc_7457 (CPUPPCState *env)
6433 6478 {
6434 6479 gen_spr_ne_601(env);
@@ -6548,8 +6593,10 @@ static void init_proc_7457 (CPUPPCState *env)
6548 6593
6549 6594 POWERPC_FAMILY(7457)(ObjectClass *oc, void *data)
6550 6595 {
  6596 + DeviceClass *dc = DEVICE_CLASS(oc);
6551 6597 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
6552 6598
  6599 + dc->desc = "PowerPC 7457 (aka G4)";
6553 6600 pcc->init_proc = init_proc_7457;
6554 6601 pcc->check_pow = check_pow_hid0_74xx;
6555 6602 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -6575,7 +6622,6 @@ POWERPC_FAMILY(7457)(ObjectClass *oc, void *data)
6575 6622 }
6576 6623
6577 6624 #if defined (TARGET_PPC64)
6578   -/* PowerPC 970 */
6579 6625 #if defined(CONFIG_USER_ONLY)
6580 6626 #define POWERPC970_HID5_INIT 0x00000080
6581 6627 #else
@@ -6654,8 +6700,10 @@ static void init_proc_970 (CPUPPCState *env)
6654 6700
6655 6701 POWERPC_FAMILY(970)(ObjectClass *oc, void *data)
6656 6702 {
  6703 + DeviceClass *dc = DEVICE_CLASS(oc);
6657 6704 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
6658 6705
  6706 + dc->desc = "PowerPC 970";
6659 6707 pcc->init_proc = init_proc_970;
6660 6708 pcc->check_pow = check_pow_970;
6661 6709 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -6678,7 +6726,6 @@ POWERPC_FAMILY(970)(ObjectClass *oc, void *data)
6678 6726 POWERPC_FLAG_BUS_CLK;
6679 6727 }
6680 6728
6681   -/* PowerPC 970FX (aka G5) */
6682 6729 static int check_pow_970FX (CPUPPCState *env)
6683 6730 {
6684 6731 if (env->spr[SPR_HID0] & 0x00600000)
@@ -6763,8 +6810,10 @@ static void init_proc_970FX (CPUPPCState *env)
6763 6810
6764 6811 POWERPC_FAMILY(970FX)(ObjectClass *oc, void *data)
6765 6812 {
  6813 + DeviceClass *dc = DEVICE_CLASS(oc);
6766 6814 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
6767 6815
  6816 + dc->desc = "PowerPC 970FX (aka G5)";
6768 6817 pcc->init_proc = init_proc_970FX;
6769 6818 pcc->check_pow = check_pow_970FX;
6770 6819 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -6787,7 +6836,6 @@ POWERPC_FAMILY(970FX)(ObjectClass *oc, void *data)
6787 6836 POWERPC_FLAG_BUS_CLK;
6788 6837 }
6789 6838
6790   -/* PowerPC 970 GX */
6791 6839 static int check_pow_970GX (CPUPPCState *env)
6792 6840 {
6793 6841 if (env->spr[SPR_HID0] & 0x00600000)
@@ -6860,8 +6908,10 @@ static void init_proc_970GX (CPUPPCState *env)
6860 6908
6861 6909 POWERPC_FAMILY(970GX)(ObjectClass *oc, void *data)
6862 6910 {
  6911 + DeviceClass *dc = DEVICE_CLASS(oc);
6863 6912 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
6864 6913
  6914 + dc->desc = "PowerPC 970 GX";
6865 6915 pcc->init_proc = init_proc_970GX;
6866 6916 pcc->check_pow = check_pow_970GX;
6867 6917 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -6884,7 +6934,6 @@ POWERPC_FAMILY(970GX)(ObjectClass *oc, void *data)
6884 6934 POWERPC_FLAG_BUS_CLK;
6885 6935 }
6886 6936
6887   -/* PowerPC 970 MP */
6888 6937 static int check_pow_970MP (CPUPPCState *env)
6889 6938 {
6890 6939 if (env->spr[SPR_HID0] & 0x01C00000)
@@ -6957,8 +7006,10 @@ static void init_proc_970MP (CPUPPCState *env)
6957 7006
6958 7007 POWERPC_FAMILY(970MP)(ObjectClass *oc, void *data)
6959 7008 {
  7009 + DeviceClass *dc = DEVICE_CLASS(oc);
6960 7010 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
6961 7011
  7012 + dc->desc = "PowerPC 970 MP";
6962 7013 pcc->init_proc = init_proc_970MP;
6963 7014 pcc->check_pow = check_pow_970MP;
6964 7015 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -6981,7 +7032,6 @@ POWERPC_FAMILY(970MP)(ObjectClass *oc, void *data)
6981 7032 POWERPC_FLAG_BUS_CLK;
6982 7033 }
6983 7034
6984   -/* POWER7 */
6985 7035 static void init_proc_POWER7 (CPUPPCState *env)
6986 7036 {
6987 7037 gen_spr_ne_601(env);
@@ -7046,8 +7096,10 @@ static void init_proc_POWER7 (CPUPPCState *env)
7046 7096
7047 7097 POWERPC_FAMILY(POWER7)(ObjectClass *oc, void *data)
7048 7098 {
  7099 + DeviceClass *dc = DEVICE_CLASS(oc);
7049 7100 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
7050 7101
  7102 + dc->desc = "POWER7";
7051 7103 pcc->init_proc = init_proc_POWER7;
7052 7104 pcc->check_pow = check_pow_nocheck;
7053 7105 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -7071,7 +7123,6 @@ POWERPC_FAMILY(POWER7)(ObjectClass *oc, void *data)
7071 7123 POWERPC_FLAG_BUS_CLK | POWERPC_FLAG_CFAR;
7072 7124 }
7073 7125
7074   -/* PowerPC 620 */
7075 7126 static void init_proc_620 (CPUPPCState *env)
7076 7127 {
7077 7128 gen_spr_ne_601(env);
@@ -7095,8 +7146,10 @@ static void init_proc_620 (CPUPPCState *env)
7095 7146
7096 7147 POWERPC_FAMILY(620)(ObjectClass *oc, void *data)
7097 7148 {
  7149 + DeviceClass *dc = DEVICE_CLASS(oc);
7098 7150 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
7099 7151
  7152 + dc->desc = "PowerPC 620";
7100 7153 pcc->init_proc = init_proc_620;
7101 7154 pcc->check_pow = check_pow_nocheck; /* Check this */
7102 7155 pcc->insns_flags = PPC_INSNS_BASE | PPC_STRING | PPC_MFTB |
@@ -7832,10 +7885,12 @@ enum {
7832 7885 glue(POWERPC_DEF_PREFIX(_pvr, _svr, _type), _cpu_class_init) \
7833 7886 (ObjectClass *oc, void *data) \
7834 7887 { \
  7888 + DeviceClass *dc = DEVICE_CLASS(oc); \
7835 7889 PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc); \
7836 7890 \
7837 7891 pcc->pvr = _pvr; \
7838 7892 pcc->svr = _svr; \
  7893 + dc->desc = NULL; \
7839 7894 } \
7840 7895 \
7841 7896 static const TypeInfo \

0 comments on commit ca5dff0

Please sign in to comment.
Something went wrong with that request. Please try again.