All of lore.kernel.org
 help / color / mirror / Atom feed
From: Luca Fancellu <Luca.Fancellu@arm.com>
To: Julien Grall <julien@xen.org>
Cc: Xen development discussion <xen-devel@lists.xenproject.org>,
	Bertrand Marquis <Bertrand.Marquis@arm.com>,
	Wei Chen <Wei.Chen@arm.com>,
	Stefano Stabellini <sstabellini@kernel.org>,
	Volodymyr Babchuk <Volodymyr_Babchuk@epam.com>
Subject: Re: [PATCH] arm/domain: fix comment for arch_set_info_guest
Date: Thu, 28 Jul 2022 18:08:40 +0000	[thread overview]
Message-ID: <E90317DB-5C1E-415B-8699-0ED1A0984C34@arm.com> (raw)
In-Reply-To: <e069280a-4d97-7a63-a125-b8ef3c397319@xen.org>



> On 28 Jul 2022, at 19:07, Julien Grall <julien@xen.org> wrote:
> 
> Hi Luca,
> 
> On 25/07/2022 15:46, Luca Fancellu wrote:
>> The function arch_set_info_guest is not reached anymore through
>> VCPUOP_initialise on arm, update the comment.
>> Signed-off-by: Luca Fancellu <luca.fancellu@arm.com>
>> ---
>> xen/arch/arm/domain.c | 6 +++---
>> 1 file changed, 3 insertions(+), 3 deletions(-)
>> diff --git a/xen/arch/arm/domain.c b/xen/arch/arm/domain.c
>> index 2f8eaab7b56b..6451cd013c1a 100644
>> --- a/xen/arch/arm/domain.c
>> +++ b/xen/arch/arm/domain.c
>> @@ -882,9 +882,9 @@ static int is_guest_pv64_psr(uint64_t psr)
>> #endif
>> /*
>> - * Initialise VCPU state. The context can be supplied by either the
>> - * toolstack (XEN_DOMCTL_setvcpucontext) or the guest
>> - * (VCPUOP_initialise) and therefore must be properly validated.
>> + * Initialise VCPU state. The context can be supplied by the toolstack
>> + * (XEN_DOMCTL_setvcpucontext) and therefore must be properly validated,
>> + * or by PSCI call (PSCI_cpu_on) handled by vpsci module.
>> */
> 
> I would prefer if the comment doesn't mention who are the callers. So there are no need to modify the comment the next time we add/remove a caller. How about something like:
> 
> "Initialise vCPU state. The context may be supplied by an external entity, so we need to validate it"

Sounds good! I’ll update and push it soon!

> 
> Cheers,
> 
> -- 
> Julien Grall


  reply	other threads:[~2022-07-28 18:09 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-25 14:46 [PATCH] arm/domain: fix comment for arch_set_info_guest Luca Fancellu
2022-07-28 18:07 ` Julien Grall
2022-07-28 18:08   ` Luca Fancellu [this message]
2022-08-05 13:08 Luca Fancellu
2022-08-05 13:12 ` Luca Fancellu
2022-08-05 17:35 ` Julien Grall
2022-08-22  6:56   ` Luca Fancellu
2022-08-22  8:09     ` Julien Grall

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=E90317DB-5C1E-415B-8699-0ED1A0984C34@arm.com \
    --to=luca.fancellu@arm.com \
    --cc=Bertrand.Marquis@arm.com \
    --cc=Volodymyr_Babchuk@epam.com \
    --cc=Wei.Chen@arm.com \
    --cc=julien@xen.org \
    --cc=sstabellini@kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.