From: "Jan Beulich" <JBeulich@suse.com>
To: george.dunlap@citrix.com
Cc: Razvan Cojocaru <rcojocaru@bitdefender.com>,
Andrew Cooper <andrew.cooper3@citrix.com>,
Tim Deegan <tim@xen.org>,
Tamas K Lengyel <tamas.lengyel@zentific.com>,
aisaila@bitdefender.com,
xen-devel <xen-devel@lists.xenproject.org>
Subject: Re: [RFC PATCH 1/2] mem_access: Fix npfec.kind propagation
Date: Thu, 27 Sep 2018 01:04:35 -0600 [thread overview]
Message-ID: <5BAC810302000078001EC6E9@prv1-mh.provo.novell.com> (raw)
In-Reply-To: <02c6bddf-933c-5348-73eb-25d6d826d30b@citrix.com>
>>> On 26.09.18 at 19:00, <andrew.cooper3@citrix.com> wrote:
> On 26/09/18 17:47, George Dunlap wrote:
>> --- a/xen/arch/x86/mm/mem_access.c
>> +++ b/xen/arch/x86/mm/mem_access.c
>> @@ -232,12 +232,12 @@ bool p2m_mem_access_check(paddr_t gpa, unsigned long gla,
>> {
>> req->u.mem_access.flags |= MEM_ACCESS_GLA_VALID;
>> req->u.mem_access.gla = gla;
>> -
>> - if ( npfec.kind == npfec_kind_with_gla )
>> - req->u.mem_access.flags |= MEM_ACCESS_FAULT_WITH_GLA;
>> - else if ( npfec.kind == npfec_kind_in_gpt )
>> - req->u.mem_access.flags |= MEM_ACCESS_FAULT_IN_GPT;
>> }
>> +
>> + if ( npfec.kind == npfec_kind_with_gla )
>> + req->u.mem_access.flags |= MEM_ACCESS_FAULT_WITH_GLA;
>> + else if ( npfec.kind == npfec_kind_in_gpt )
>> + req->u.mem_access.flags |= MEM_ACCESS_FAULT_IN_GPT;
>
> Nit. Newline here please, as it is not logically related with the block
> below.
And, despite it being just two comparisons, perhaps better to
make it a switch() at the same time?
Jan
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel
next prev parent reply other threads:[~2018-09-27 7:04 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-09-26 16:47 [RFC PATCH 1/2] mem_access: Fix npfec.kind propagation George Dunlap
2018-09-26 16:47 ` [RFC PATCH 2/2] x86/mm: Add mem access rights to NPT George Dunlap
2018-09-26 17:22 ` Andrew Cooper
2018-09-27 10:37 ` George Dunlap
2018-09-27 10:53 ` Paul Durrant
2019-01-09 9:30 ` Alexandru Stefan ISAILA
2018-09-27 9:38 ` Isaila Alexandru
2019-06-13 10:56 ` [Xen-devel] " Alexandru Stefan ISAILA
2019-06-17 10:48 ` George Dunlap
2019-06-17 11:58 ` Andrew Cooper
2019-06-13 15:19 ` Tamas Lengyel
2019-06-13 15:21 ` Razvan Cojocaru
2018-09-26 16:51 ` [RFC PATCH 1/2] mem_access: Fix npfec.kind propagation Tamas Lengyel
2018-09-26 17:00 ` Andrew Cooper
2018-09-27 7:04 ` Jan Beulich [this message]
2018-09-27 8:46 ` George Dunlap
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5BAC810302000078001EC6E9@prv1-mh.provo.novell.com \
--to=jbeulich@suse.com \
--cc=aisaila@bitdefender.com \
--cc=andrew.cooper3@citrix.com \
--cc=george.dunlap@citrix.com \
--cc=rcojocaru@bitdefender.com \
--cc=tamas.lengyel@zentific.com \
--cc=tim@xen.org \
--cc=xen-devel@lists.xenproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).