Re: [PATCH for-7.1] vl: fix [memory] section with -readconfig

2022-08-07 Thread Markus Armbruster
Paolo Bonzini writes: > On 8/5/22 15:40, Markus Armbruster wrote: >>> +loc_push_none(&loc); >>> +qemu_opts_loc_restore(opts); >>> + >>> prop = qdict_new(); >>> if (qemu_opt_get_size(opts, "size", 0) != 0) { >> >> This treats "size=0" like absent size. Before commit ce9d03fb

Re: [PATCH for-7.1] vl: fix [memory] section with -readconfig

2022-08-05 Thread Paolo Bonzini
On 8/5/22 15:40, Markus Armbruster wrote: +loc_push_none(&loc); +qemu_opts_loc_restore(opts); + prop = qdict_new(); if (qemu_opt_get_size(opts, "size", 0) != 0) { This treats "size=0" like absent size. Before commit ce9d03fb3f, we instead checked mem_str = qemu_o

Re: [PATCH for-7.1] vl: fix [memory] section with -readconfig

2022-08-05 Thread Markus Armbruster
Paolo Bonzini writes: > The -M memory.* options do not have magic applied to them than the -m > option, namely no "M" (for mebibytes) is tacked at the end of a > suffixless value for "-M memory.size". This sentence is confusing. Do you mean "like the -m option"? > This magic is performed by pa

Re: [PATCH for-7.1] vl: fix [memory] section with -readconfig

2022-08-05 Thread Daniel P . Berrangé
On Fri, Aug 05, 2022 at 12:06:35PM +0200, Paolo Bonzini wrote: > The -M memory.* options do not have magic applied to them than the -m > option, namely no "M" (for mebibytes) is tacked at the end of a > suffixless value for "-M memory.size". > > This magic is performed by parse_memory_options, and

[PATCH for-7.1] vl: fix [memory] section with -readconfig

2022-08-05 Thread Paolo Bonzini
The -M memory.* options do not have magic applied to them than the -m option, namely no "M" (for mebibytes) is tacked at the end of a suffixless value for "-M memory.size". This magic is performed by parse_memory_options, and we have to do it for both "-m" and the [memory] section of a config file