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

Re: [Xen-devel] [PATCH RFC V7 4/5] xen, libxc: Request page fault injection via libxc


  • To: Jan Beulich <JBeulich@xxxxxxxx>
  • From: Razvan Cojocaru <rcojocaru@xxxxxxxxxxxxxxx>
  • Date: Wed, 27 Aug 2014 15:15:09 +0300
  • Cc: kevin.tian@xxxxxxxxx, ian.campbell@xxxxxxxxxx, stefano.stabellini@xxxxxxxxxxxxx, andrew.cooper3@xxxxxxxxxx, eddie.dong@xxxxxxxxx, xen-devel@xxxxxxxxxxxxx, jun.nakajima@xxxxxxxxx, ian.jackson@xxxxxxxxxxxxx
  • Comment: DomainKeys? See http://domainkeys.sourceforge.net/
  • Delivery-date: Wed, 27 Aug 2014 12:15:08 +0000
  • Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=bitdefender.com; b=2Zb3VldhBirlVND9GmDkLRLbcImUKVc+joT068L7/ZOBClLE5g3zmOs3px/chGsS6Odl2AjkxiHwpVOX4yB59OffwLLPz7K5G3SbSe7W+y+9vk7AptDWPG8unWlkGha3Ehl0PfxLYRaBqpKy7IP2wAwWRu8+rWeph/bq1l1kReliKhpL34oY7gf7+WfDuzgiATu0c8GCIR+Lh4VI+jjm+mhnyCn2wGLTNDgAiVjwwRSE6e/O9ahJBM91dpcdrPxOv4cVlfyviEH7eK4mDJeehxsxNHSlm1k+jDU52BdJNT6wuyINI7HFp/EXDVIp6asFNYM1a4CJsBz1UQExQp5I/A==; h=Received:Received:Received:Received:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type:Content-Transfer-Encoding:X-BitDefender-Scanner:X-BitDefender-Spam:X-BitDefender-SpamStamp:X-BitDefender-CF-Stamp;
  • List-id: Xen developer discussion <xen-devel.lists.xen.org>

On 08/27/2014 03:10 PM, Jan Beulich wrote:
>>>> On 27.08.14 at 13:54, <rcojocaru@xxxxxxxxxxxxxxx> wrote:
>> On 08/26/2014 05:13 PM, Jan Beulich wrote:
>>>>>> On 13.08.14 at 17:28, <rcojocaru@xxxxxxxxxxxxxxx> wrote:
>>>> +    case XEN_DOMCTL_set_pagefault_info:
>>>> +    {
>>>> +        ret = -EINVAL;
>>>> +
>>>> +        if ( is_hvm_domain(d) )
>>>> +        {
>>>> +            d->arch.hvm_domain.fault_info.address_space =
>>>> +                op->u.set_pagefault_info.address_space;
>>>> +            d->arch.hvm_domain.fault_info.virtual_address =
>>>> +                op->u.set_pagefault_info.virtual_address;
>>>> +            d->arch.hvm_domain.fault_info.errcode =
>>>> +                op->u.set_pagefault_info.errcode;
>>>> +            d->arch.hvm_domain.fault_info.valid = 1;
>>>> +
>>>> +            ret = 0;
>>>> +        }
>>>> +    }
>>>
>>> Pointless curly braces.
>>
>> You're right, of course, but I've written it like that because that
>> seems to be the style (even where it is not necessary / no local
>> variables are introduced) in
>> do_domctl(XEN_GUEST_HANDLE_PARAM(xen_domctl_t) u_domctl).
>>
>> Should I break with the coding style for this switch case?
> 
> Neither do_domctl() nor x86's arch_do_domctl() really consistently
> do like you say. Hence I think rather than continuing the bad habit,
> making new additions do better is the right approach. (As to why
> I really think this isn't just a cosmetic thing: These braces usually
> get placed at the same indentation level as the containing switch
> statement's, breaking consistent indentation, potentially leading to
> two immediately successive closing braces at the same indentation
> level.)

I understand, thanks for the reply! I'll change the code.


Razvan Cojocaru

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


 


Rackspace

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