[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v1 1/1] generic-loader: file: Only set a PC if a
From: |
Alistair Francis |
Subject: |
Re: [Qemu-devel] [PATCH v1 1/1] generic-loader: file: Only set a PC if a CPU is specified |
Date: |
Wed, 16 Nov 2016 14:02:27 -0800 |
On Fri, Nov 11, 2016 at 8:06 PM, Edgar E. Iglesias
<address@hidden> wrote:
> On Fri, Nov 11, 2016 at 06:51:20PM -0800, Alistair Francis wrote:
>> This patch fixes the generic-loader file loading to only set the program
>> counter if a CPU is specified. This follows what is written in the
>> documentation and was always part of the original intention.
>
> Reviewed-by: Edgar E. Iglesias <address@hidden>
Peter can this go through your queue?
I think it should make it into 2.8 as it matches the documentation and
this will be the first release with the device loader.
Thanks,
Alistair
>
>
>>
>> Signed-off-by: Alistair Francis <address@hidden>
>> ---
>>
>> hw/core/generic-loader.c | 7 ++++++-
>> 1 file changed, 6 insertions(+), 1 deletion(-)
>>
>> diff --git a/hw/core/generic-loader.c b/hw/core/generic-loader.c
>> index 79ab6df..208f549 100644
>> --- a/hw/core/generic-loader.c
>> +++ b/hw/core/generic-loader.c
>> @@ -93,7 +93,12 @@ static void generic_loader_realize(DeviceState *dev,
>> Error **errp)
>> "image");
>> return;
>> }
>> - s->set_pc = true;
>> + /* The user specified a file, only set the PC if they also specified
>> + * a CPU to use.
>> + */
>> + if (s->cpu_num != CPU_NONE) {
>> + s->set_pc = true;
>> + }
>> } else if (s->addr) {
>> /* User is setting the PC */
>> if (s->data || s->data_len || s->data_be) {
>> --
>> 2.7.4
>>