[CRIU] [PATCH 2/2]v2 service: add support for check request
Ruslan Kuprieiev
kupruser at gmail.com
Tue Nov 19 15:22:22 PST 2013
On 19.11.2013 22:54, Pavel Emelyanov wrote:
>>>>>>>>>> +
>>>>>>>>>> + resp.kernel = true;
>>>>>>>>> Always true argument is pointless.
>>>>>>>> But resp.kernel = false after init. If cr_check() does not fail, we set
>>>>>>>> resp.kernel to true, and if cr_check() does fail - resp.kernel = false.
>>>>>>> So we have two types of responses:
>>>>>>>
>>>>>>> * kernel = true, success = true for OK
>>>>>>> * kernel = false, success = false for not-OK
>>>>>>>
>>>>>>> Why is just success = <success-or-not> not enough?
>>>>>> Here is what we've got:
>>>>>>
>>>>>> -- resp.success == false -- options are wrong or something bad happened
>>>>>> and check wasn't done
>>>>>>
>>>>>> -- resp.success == true and resp.check.kernel == true -- check was done
>>>>>> and kernel features are ok
>>>>>>
>>>>>> -- resp.success == true and resp.check.kernel == false -- check was done
>>>>>> and kernel features are not ok
>>>>> I don't see this in the code -- resp.success = true and resp.kernel = true
>>>>> are set together in one place.
>> Yes, it can't be such for now. But it is a preparation for further work.
>> Or you are not sure about adding more functionality to this request? We
>> may add check_dump/check_restore/check_images? as a separate ones. What
>> do you think?
> If we want to extend req/resp later, we can do it with optional pb fields.
> Plz, make only necessary amount of coding.
Ok.
More information about the CRIU
mailing list