qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH] hw: fix to display correct memory size


From: Yongbok Kim
Subject: Re: [Qemu-devel] [PATCH] hw: fix to display correct memory size
Date: Tue, 27 Aug 2013 15:47:40 +0000

Because this patch is not the critical, probably I can re-send this and the 
additional patches (Andreas' suggestion) as trivial patches when the 2GiB patch 
applied.

Regards,
Yongbok

-----Original Message-----
From: Alexander Graf [mailto:address@hidden 
Sent: 25 August 2013 17:12
To: Andreas Färber
Cc: Yongbok Kim; address@hidden; Leon Alrae; address@hidden; address@hidden
Subject: Re: [Qemu-devel] [PATCH] hw: fix to display correct memory size


On 23.08.2013, at 17:20, Andreas Färber wrote:

> Am 23.08.2013 16:57, schrieb Yongbok Kim:
>> A parenthesis placed inappropriately caused displaying wrong memory 
>> size bigger than 4GB.
>> 
>> Signed-off-by: Yongbok Kim <address@hidden>
>> ---
>> hw/mips/mips_malta.c  |    2 +-
>> hw/mips/mips_r4k.c    |    2 +-
>> hw/ppc/mac_oldworld.c |    2 +-
>> 3 files changed, 3 insertions(+), 3 deletions(-)
> 
> Thanks for fixing this even beyond MIPS machines!
> 
> In theory I would've preferred a patch using the correct format string 
> and dropping the unsigned int cast completely, but our RAM_ADDR_FMT 
> uses hexadecimal format, so:
> 
> Reviewed-by: Andreas Färber <address@hidden>
> 
>> diff --git a/hw/mips/mips_malta.c b/hw/mips/mips_malta.c index 
>> f8d064c..23ac1ca 100644
>> --- a/hw/mips/mips_malta.c
>> +++ b/hw/mips/mips_malta.c
>> @@ -954,7 +954,7 @@ void mips_malta_init(QEMUMachineInitArgs *args)
>>     if (ram_size > (256 << 20)) {
>>         fprintf(stderr,
>>                 "qemu: Too much memory for this machine: %d MB, maximum 256 
>> MB\n",
>> -                ((unsigned int)ram_size / (1 << 20)));
>> +                (unsigned int)(ram_size / (1 << 20)));
> 
> Seeing that in the Malta case your other patch will trivially conflict 
> with this bugfix, would you have time to turn it into a series of 
> three patches, this being the first and adding "Cc: 
> address@hidden" to its commit message for inclusion in 1.6.1, 
> then an additional patch replacing fprintf(stderr, "qemu: ...\n", ...) 
> with error_report("...",
> ...) (note no trailing \n and it will also automatically prefix the 
> right qemu-system-mips* executable name) and finally your 2 GiB patch?

Ah, saw this comment too late. Andreas' suggestions is obviously even better :).


Alex





reply via email to

[Prev in Thread] Current Thread [Next in Thread]