All of lore.kernel.org
 help / color / mirror / Atom feed
From: Nikunj A Dadhania <nikunj@linux.vnet.ibm.com>
To: Alexander Graf <agraf@suse.de>, qemu-devel@nongnu.org
Cc: thuth@linux.vnet.ibm.com, aik@ozlabs.ru, armbru@redhat.com,
	qemu-ppc@nongnu.org, marcel.apfelbaum@gmail.com,
	imammedo@redhat.com
Subject: Re: [Qemu-devel] [PATCH v4 2/2] spapr: override default ram size to 1GB
Date: Thu, 05 Mar 2015 20:09:02 +0530	[thread overview]
Message-ID: <87sidjwltl.fsf@linux.vnet.ibm.com> (raw)
In-Reply-To: <54F85596.30802@suse.de>

Alexander Graf <agraf@suse.de> writes:

> On 05.03.15 12:56, Nikunj A Dadhania wrote:
>> Signed-off-by: Nikunj A Dadhania <nikunj@linux.vnet.ibm.com>
>> Reviewed-by: Igor Mammedov <imammedo@redhat.com>
>> ---
>>  hw/ppc/spapr.c | 2 ++
>>  1 file changed, 2 insertions(+)
>> 
>> diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c
>> index 23cde20..c71ee4b 100644
>> --- a/hw/ppc/spapr.c
>> +++ b/hw/ppc/spapr.c
>> @@ -96,6 +96,7 @@ typedef struct sPAPRMachineState sPAPRMachineState;
>>  #define SPAPR_MACHINE(obj) \
>>      OBJECT_CHECK(sPAPRMachineState, (obj), TYPE_SPAPR_MACHINE)
>>  
>> +#define SPAPR_DEFAULT_RAM_SIZE   (1UL << 30)
>
> UL is almost always wrong on QEMU land. Please use ULL.
>
> Also I find 1 << 30 pretty hard to read. Can't we just define simple
> KB/MB/GB/TB helpers somewhere in a header file and just fold this is
> below as ..

Ok, let me get a appropriate header for these.

>
>>  /**
>>   * sPAPRMachineState:
>>   */
>> @@ -1738,6 +1739,7 @@ static void spapr_machine_class_init(ObjectClass *oc, void *data)
>>      mc->max_cpus = MAX_CPUS;
>>      mc->no_parallel = 1;
>>      mc->default_boot_order = NULL;
>> +    mc->default_ram_size = SPAPR_DEFAULT_RAM_SIZE;
>
> mc->default_ram_size = 1 * GB;
>
>
> Alex
>
>>      mc->kvm_type = spapr_kvm_type;
>>      mc->has_dynamic_sysbus = true;
>>  
>> 

      reply	other threads:[~2015-03-05 14:40 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-05 11:56 [Qemu-devel] [PATCH v4 0/2] Introduce default ram size in MachineClass Nikunj A Dadhania
2015-03-05 11:56 ` [Qemu-devel] [PATCH v4 1/2] machine: add default_ram_size to machine class Nikunj A Dadhania
2015-03-05 15:13   ` Marcel Apfelbaum
2015-03-05 15:34     ` Nikunj A Dadhania
2015-03-05 11:56 ` [Qemu-devel] [PATCH v4 2/2] spapr: override default ram size to 1GB Nikunj A Dadhania
2015-03-05 13:09   ` Alexander Graf
2015-03-05 14:39     ` Nikunj A Dadhania [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87sidjwltl.fsf@linux.vnet.ibm.com \
    --to=nikunj@linux.vnet.ibm.com \
    --cc=agraf@suse.de \
    --cc=aik@ozlabs.ru \
    --cc=armbru@redhat.com \
    --cc=imammedo@redhat.com \
    --cc=marcel.apfelbaum@gmail.com \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-ppc@nongnu.org \
    --cc=thuth@linux.vnet.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.