qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH 43/47] mirror: allow customizing the granularity


From: Paolo Bonzini
Subject: Re: [Qemu-devel] [PATCH 43/47] mirror: allow customizing the granularity
Date: Mon, 30 Jul 2012 15:40:32 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:13.0) Gecko/20120615 Thunderbird/13.0.1

Il 28/07/2012 15:43, Eric Blake ha scritto:
>> > +    if (granularity < 512 || granularity > 1048576 * 64) {
>> > +        error_set(errp, QERR_INVALID_PARAMETER, device);
>> > +        return;
>> > +    }
>> > +    if (granularity & (granularity - 1)) {
>> > +        error_set(errp, QERR_INVALID_PARAMETER, device);
>> > +        return;
> In the XBZLRE migration series, we decided to round the users input down
> to a power of two instead of reject it.  Should we do that here?

I can certainly do that, but do you have a pointer to the discussion so
that I can understand the rationale?

> Also,
> there is already an explicit QERR_PROPERY_VALUE_NOT_POWER_OF_2 that
> might fit better here (depending on how the error cleanup series goes).

It's not a property value though.

Paolo



reply via email to

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