diff mbox

[v1,1/1] xlnx-zcu102: Specify the number of max CPUs

Message ID 382833937419ccd4de5de9b65f74ca561cfa328d.1509114880.git.alistair.francis@xilinx.com (mailing list archive)
State New, archived
Headers show

Commit Message

Alistair Francis Oct. 27, 2017, 2:35 p.m. UTC
Specify the number of CPUs that can run on ZynqMP.

Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>
---

 hw/arm/xlnx-zcu102.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Philippe Mathieu-Daudé Oct. 27, 2017, 6:22 p.m. UTC | #1
Hi Alistair,

On 10/27/2017 11:35 AM, Alistair Francis wrote:
> Specify the number of CPUs that can run on ZynqMP.
> 
> Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>
> ---
> 
>  hw/arm/xlnx-zcu102.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/hw/arm/xlnx-zcu102.c b/hw/arm/xlnx-zcu102.c
> index 519a16ed98..b86c048bb3 100644
> --- a/hw/arm/xlnx-zcu102.c
> +++ b/hw/arm/xlnx-zcu102.c
> @@ -240,6 +240,7 @@ static void xlnx_zcu102_machine_class_init(ObjectClass *oc, void *data)
>      mc->block_default_type = IF_IDE;
>      mc->units_per_default_bus = 1;
>      mc->ignore_memory_transaction_failures = true;
> +    mc->max_cpus = 6;

This can be self-explanatory:

    mc->max_cpus = XLNX_ZYNQMP_NUM_APU_CPUS + XLNX_ZYNQMP_NUM_RPU_CPUS;

Then:
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>

>  }
>  
>  static const TypeInfo xlnx_zcu102_machine_init_typeinfo = {
>
Alistair Francis Oct. 28, 2017, 6:12 a.m. UTC | #2
On Fri, Oct 27, 2017 at 8:22 PM, Philippe Mathieu-Daudé <f4bug@amsat.org> wrote:
> Hi Alistair,
>
> On 10/27/2017 11:35 AM, Alistair Francis wrote:
>> Specify the number of CPUs that can run on ZynqMP.
>>
>> Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>
>> ---
>>
>>  hw/arm/xlnx-zcu102.c | 1 +
>>  1 file changed, 1 insertion(+)
>>
>> diff --git a/hw/arm/xlnx-zcu102.c b/hw/arm/xlnx-zcu102.c
>> index 519a16ed98..b86c048bb3 100644
>> --- a/hw/arm/xlnx-zcu102.c
>> +++ b/hw/arm/xlnx-zcu102.c
>> @@ -240,6 +240,7 @@ static void xlnx_zcu102_machine_class_init(ObjectClass *oc, void *data)
>>      mc->block_default_type = IF_IDE;
>>      mc->units_per_default_bus = 1;
>>      mc->ignore_memory_transaction_failures = true;
>> +    mc->max_cpus = 6;
>
> This can be self-explanatory:
>
>     mc->max_cpus = XLNX_ZYNQMP_NUM_APU_CPUS + XLNX_ZYNQMP_NUM_RPU_CPUS;

Ah good point.

I won't be able to update that until I'm back from holidays.

>
> Then:
> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>

Thanks!
Alistair

>
>>  }
>>
>>  static const TypeInfo xlnx_zcu102_machine_init_typeinfo = {
>>
diff mbox

Patch

diff --git a/hw/arm/xlnx-zcu102.c b/hw/arm/xlnx-zcu102.c
index 519a16ed98..b86c048bb3 100644
--- a/hw/arm/xlnx-zcu102.c
+++ b/hw/arm/xlnx-zcu102.c
@@ -240,6 +240,7 @@  static void xlnx_zcu102_machine_class_init(ObjectClass *oc, void *data)
     mc->block_default_type = IF_IDE;
     mc->units_per_default_bus = 1;
     mc->ignore_memory_transaction_failures = true;
+    mc->max_cpus = 6;
 }
 
 static const TypeInfo xlnx_zcu102_machine_init_typeinfo = {