xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Julien Grall <julien.grall@linaro.org>
To: mjaggi@caviumnetworks.com, xen-devel@lists.xen.org,
	marc.zyngier@arm.com, sstabellini@kernel.org,
	andre.przywara@linaro.org
Cc: manish.jaggi@cavium.com
Subject: Re: [PATCH 06/10] Expose gicv3_ich_read/write_lr
Date: Thu, 25 Jan 2018 16:52:17 +0000	[thread overview]
Message-ID: <84f1a998-ad1e-3a42-41fb-19fa43c290f9@linaro.org> (raw)
In-Reply-To: <20180116154305.19186-7-mjaggi@caviumnetworks.com>

Hi,

On 16/01/18 15:43, mjaggi@caviumnetworks.com wrote:
> From: Manish Jaggi <manish.jaggi@cavium.com>
> 
> gicv3_ich_read/write_lr functions are static in gic-v3.c
> This patch creates wrapper functions which can be used from outside the file.
> 
> Signed-off-by: Manish Jaggi <manish.jaggi@cavium.com>
> ---
>   xen/arch/arm/gic-v3.c        | 10 ++++++++++
>   xen/include/asm-arm/gic_v3.h |  7 +++++++
>   2 files changed, 17 insertions(+)
> 
> diff --git a/xen/arch/arm/gic-v3.c b/xen/arch/arm/gic-v3.c
> index 473e26111f..5dba8bc932 100644
> --- a/xen/arch/arm/gic-v3.c
> +++ b/xen/arch/arm/gic-v3.c
> @@ -184,6 +184,11 @@ static uint64_t gicv3_ich_read_lr(int lr)
>       }
>   }
>   
> +uint64_t __gicv3_ich_read_lr(int lr)

I see no reason to have a wrapper with exactly the same parameters. Just 
export the current one.

But I think I would prefer the function to be redefined in the cpu if 
implementation. So we vGIC errata is fully separated from the rest of Xen.

> +{
> +    return gicv3_ich_read_lr(lr);
> +}
> +
>   static void gicv3_ich_write_lr(int lr, uint64_t val)
>   {
>       switch ( lr )
> @@ -242,6 +247,11 @@ static void gicv3_ich_write_lr(int lr, uint64_t val)
>       isb();
>   }
>   
> +void __gicv3_ich_write_lr(int lr, uint64_t val)
> +{
> +    return gicv3_ich_write_lr(lr, val);
> +}
> +
>   /*
>    * System Register Enable (SRE). Enable to access CPU & Virtual
>    * interface registers as system registers in EL2
> diff --git a/xen/include/asm-arm/gic_v3.h b/xen/include/asm-arm/gic_v3.h
> new file mode 100644
> index 0000000000..544aad5932
> --- /dev/null
> +++ b/xen/include/asm-arm/gic_v3.h
> @@ -0,0 +1,7 @@
> +#ifndef GICV3_H
> +#define GICV3_H
> +
> +uint64_t __gicv3_ich_read_lr(int lr);
> +void __gicv3_ich_write_lr(int lr, uint64_t val);
> +
> +#endif
> 

Cheers,

-- 
Julien Grall

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

  reply	other threads:[~2018-01-25 16:52 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-16 15:42 [RFC PATCH 00/10] arm64: Mediate access to GICv3 sysregs at EL2 mjaggi
2018-01-16 15:42 ` [RFC PATCH 01/10] Add CONFIG_VGIC_ERRATA mjaggi
2018-01-25 13:48   ` Julien Grall
2018-02-21 15:17     ` Manish Jaggi
2018-02-21 15:56       ` Julien Grall
2018-01-16 15:42 ` [RFC PATCH 02/10] arm64: Add hook to handle guest GICv3 sysreg accesses mjaggi
2018-01-25 16:17   ` Julien Grall
2018-01-25 18:07   ` Julien Grall
2018-02-01  8:51     ` Manish Jaggi
2018-02-01 10:54       ` Julien Grall
2018-02-26  6:42         ` Manish Jaggi
2018-02-26  6:58           ` Manish Jaggi
2018-02-26 10:43           ` Julien Grall
2018-01-16 15:42 ` [PATCH 03/10] arm64: Add ICV_BPR1_EL1 handler mjaggi
2018-01-25 16:44   ` Julien Grall
2018-02-01  8:57     ` Manish Jaggi
2018-02-01 10:55       ` Julien Grall
2018-01-16 15:42 ` [PATCH 04/10] arm64: Add ICV_IGRPEN1_EL1 handler mjaggi
2018-01-16 15:43 ` [PATCH 05/10] arm64: Add accessors for the ICH_APxRn_EL2 registers mjaggi
2018-01-16 15:43 ` [PATCH 06/10] Expose gicv3_ich_read/write_lr mjaggi
2018-01-25 16:52   ` Julien Grall [this message]
2018-02-01  8:54     ` Manish Jaggi
2018-01-16 15:43 ` [PATCH 07/10] arm64: Add ICV_IAR1_EL1 handler mjaggi
2018-01-16 15:43 ` [PATCH 08/10] Add ICV_EOIR1_EL1 handler mjaggi
2018-01-16 15:43 ` [PATCH 09/10] arm64: Add a handler for ICV_HPPIR1_EL1 mjaggi
2018-01-16 15:43 ` [PATCH 10/10] Enable Trapping of Group1 registers which is controlled by command line mjaggi
2018-01-25 17:00   ` Julien Grall
2018-02-01  8:53     ` Manish Jaggi

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=84f1a998-ad1e-3a42-41fb-19fa43c290f9@linaro.org \
    --to=julien.grall@linaro.org \
    --cc=andre.przywara@linaro.org \
    --cc=manish.jaggi@cavium.com \
    --cc=marc.zyngier@arm.com \
    --cc=mjaggi@caviumnetworks.com \
    --cc=sstabellini@kernel.org \
    --cc=xen-devel@lists.xen.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).