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

Re: [Xen-devel] [PATCH v2 Altp2m cleanup v3 2/3] Move altp2m specific functions to altp2m files.



>>> On 02.09.16 at 19:56, <paul.c.lai@xxxxxxxxx> wrote:
> From: Jan Beulich [mailto:JBeulich@xxxxxxxx] 
> Sent: Friday, September 2, 2016 6:31 AM
>>>> On 19.08.16 at 19:22, <paul.c.lai@xxxxxxxxx> wrote:
>> +    /* Init alternate p2m data. */
>> +    if ( (d->arch.altp2m_eptp = alloc_xenheap_page()) == NULL )
>> +    {
>> +        rc = -ENOMEM;
>> +        goto out;
>> +    }
> 
> When the epilogue (after the target label) is just a return statement, 
> please avoid using goto.
> 
> [PAUL] I don't see this code in an epilogue (after the target label).  

I don't understand: The function ends like this

 out:
    return rc;
}

What is it that you don't see here? Again, all I'm asking for is that
in a case like this you simply use "return" instead of the rc
assignment and "goto".

Jan


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

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.