>>> On 12.08.15 at 11:19, <vkuzn...@redhat.com> wrote:
> "Jan Beulich" <jbeul...@suse.com> writes:
> 
>>>>> On 11.08.15 at 21:57, <konrad.w...@oracle.com> wrote:
>>> On Tue, Jul 28, 2015 at 03:28:11PM +0200, Vitaly Kuznetsov wrote:
>>>> @@ -1038,6 +1045,32 @@ void domain_unpause_except_self(struct domain *d)
>>>>          domain_unpause(d);
>>>>  }
>>>>  
>>>> +int domain_soft_reset(struct domain *d)
>>>> +{
>>>> +    struct vcpu *v;
>>>> +    int rc;
>>>> +
>>>> +    spin_lock(&d->shutdown_lock);
>>>> +    for_each_vcpu ( d, v )
>>>> +        if ( !v->paused_for_shutdown )
>>>> +        {
>>>> +            spin_unlock(&d->shutdown_lock);
>>>> +            return -EINVAL;
>>>> +        }
>>>> +    spin_unlock(&d->shutdown_lock);
>>>> +
>>>> +    rc = evtchn_reset(d);
>>> 
>>> You do ignore the 'rc' value? In which case why not just
>>> do:
>>> 
>>>     (void)evtchn_reset(d);
>>> 
>>> Unless you want to return the 'rc' ?
>>
>> It clearly needs to be returned.
> 
> Yes,
> 
> as evtchn_reset() doesn't break somewhere in the middle (it can only
> return -EINVAL is !d->controller_pause_count in this case) I think we're
> OK with a simple
> 
> if ( rc )
>     return rc;
> 
> here, no domain destroy which we introduce with arch-specific hooks is
> required (we haven't done anything to the domain yet).
> 
> Jan, does you Acked-by: stand with such change?

Yes (the more that I already confirmed the change to be needed).

Jan


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

Reply via email to