[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v3 1/1] vl/s390x: fixup ram sizes for compat machines
From: |
Igor Mammedov |
Subject: |
Re: [PATCH v3 1/1] vl/s390x: fixup ram sizes for compat machines |
Date: |
Thu, 2 Apr 2020 14:05:36 +0200 |
On Thu, 2 Apr 2020 13:42:22 +0200
Christian Borntraeger <address@hidden> wrote:
> On 02.04.20 13:39, Igor Mammedov wrote:
> [...]
> >>>
> >>>> + "MB to match machine restrictions. Consider
> >>>> updating "
> >>>> + "the guest definition.i\n", sz / MiB, newsz / MiB);
> >>>>
> >>>
> >>> also it might be better to use size_to_str() to format numbers
> >>
> >> The text explicitly talks about 'MB'... not sure if it would be
> >> confusing if the user specified MB and ended up with GB or so in this
> >> message.
> >
> > MB can be dropped, since it still might not match what user specified with
> > -m
> > it could be specified in b/kb/mb/gb over there
> >
> > so I'd drop MB and print value size_to_str() returns
> > (it will add appropriate suffix if I'm not mistaken)
> >
>
> The return value of size_to_str must be freed. Arent we going overboard for
> such
> a message?
yep, one can use g_autofree for it.
on upside one doesn't have to bother with picking proper format string
which is far from trivial in case type mutates depending on host.
>
- Re: [PATCH v3 1/1] vl/s390x: fixup ram sizes for compat machines, (continued)
Re: [PATCH v3 1/1] vl/s390x: fixup ram sizes for compat machines, Igor Mammedov, 2020/04/01
Re: [PATCH v3 1/1] vl/s390x: fixup ram sizes for compat machines, Igor Mammedov, 2020/04/02
Re: [PATCH v3 1/1] vl/s390x: fixup ram sizes for compat machines, Christian Borntraeger, 2020/04/02
Re: [PATCH v3 1/1] vl/s390x: fixup ram sizes for compat machines,
Igor Mammedov <=
Re: [PATCH v3 1/1] vl/s390x: fixup ram sizes for compat machines, Christian Borntraeger, 2020/04/02
Re: [PATCH v3 1/1] vl/s390x: fixup ram sizes for compat machines, Christian Borntraeger, 2020/04/02
Re: [PATCH v3 1/1] vl/s390x: fixup ram sizes for compat machines, Cornelia Huck, 2020/04/02
Re: [PATCH v3 1/1] vl/s390x: fixup ram sizes for compat machines, Cornelia Huck, 2020/04/02