public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [PATCH] ArmPkg/ArmGicLib: Fix setting GICv3 Interrupt Priority
@ 2021-02-25 17:19 Ashish Singhal
  2021-02-25 20:07 ` Leif Lindholm
  0 siblings, 1 reply; 3+ messages in thread
From: Ashish Singhal @ 2021-02-25 17:19 UTC (permalink / raw)
  To: leif, ardb+tianocore, devel; +Cc: Ashish Singhal

Incorrect register is being set for configuring interrupt
priority. Correct register is located in SGI space and not
in RD space.

Signed-off-by: Ashish Singhal <ashishsingha@nvidia.com>
---
 ArmPkg/Drivers/ArmGic/ArmGicLib.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/ArmPkg/Drivers/ArmGic/ArmGicLib.c b/ArmPkg/Drivers/ArmGic/ArmGicLib.c
index 8ef32b3..3c0bee6 100644
--- a/ArmPkg/Drivers/ArmGic/ArmGicLib.c
+++ b/ArmPkg/Drivers/ArmGic/ArmGicLib.c
@@ -236,7 +236,7 @@ ArmGicSetInterruptPriority (
     }
 
     MmioAndThenOr32 (
-      GicCpuRedistributorBase + ARM_GIC_ICDIPR + (4 * RegOffset),
+      GicCpuRedistributorBase + ARM_GICR_CTLR_FRAME_SIZE + ARM_GIC_ICDIPR + (4 * RegOffset),
       ~(0xff << RegShift),
       Priority << RegShift
       );
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] ArmPkg/ArmGicLib: Fix setting GICv3 Interrupt Priority
  2021-02-25 17:19 [PATCH] ArmPkg/ArmGicLib: Fix setting GICv3 Interrupt Priority Ashish Singhal
@ 2021-02-25 20:07 ` Leif Lindholm
  2021-03-01 14:48   ` Ashish Singhal
  0 siblings, 1 reply; 3+ messages in thread
From: Leif Lindholm @ 2021-02-25 20:07 UTC (permalink / raw)
  To: Ashish Singhal; +Cc: ardb+tianocore, devel

Hi Ashish,

This bug was already reported by Ming (who also submitted a patch).

Tracked in https://bugzilla.tianocore.org/show_bug.cgi?id=3236, should
make it into the tree tomorrow.

Thank you for your contribution!

/
    Leif

On Thu, Feb 25, 2021 at 10:19:46 -0700, Ashish Singhal wrote:
> Incorrect register is being set for configuring interrupt
> priority. Correct register is located in SGI space and not
> in RD space.
> 
> Signed-off-by: Ashish Singhal <ashishsingha@nvidia.com>
> ---
>  ArmPkg/Drivers/ArmGic/ArmGicLib.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/ArmPkg/Drivers/ArmGic/ArmGicLib.c b/ArmPkg/Drivers/ArmGic/ArmGicLib.c
> index 8ef32b3..3c0bee6 100644
> --- a/ArmPkg/Drivers/ArmGic/ArmGicLib.c
> +++ b/ArmPkg/Drivers/ArmGic/ArmGicLib.c
> @@ -236,7 +236,7 @@ ArmGicSetInterruptPriority (
>      }
>  
>      MmioAndThenOr32 (
> -      GicCpuRedistributorBase + ARM_GIC_ICDIPR + (4 * RegOffset),
> +      GicCpuRedistributorBase + ARM_GICR_CTLR_FRAME_SIZE + ARM_GIC_ICDIPR + (4 * RegOffset),
>        ~(0xff << RegShift),
>        Priority << RegShift
>        );
> -- 
> 2.7.4
> 

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] ArmPkg/ArmGicLib: Fix setting GICv3 Interrupt Priority
  2021-02-25 20:07 ` Leif Lindholm
@ 2021-03-01 14:48   ` Ashish Singhal
  0 siblings, 0 replies; 3+ messages in thread
From: Ashish Singhal @ 2021-03-01 14:48 UTC (permalink / raw)
  To: Leif Lindholm; +Cc: ardb+tianocore@kernel.org, devel@edk2.groups.io

[-- Attachment #1: Type: text/plain, Size: 1686 bytes --]

I have picked up the patches this morning and they are working as expected. Thanks, Leif.

Thanks
Ashish
________________________________
From: Leif Lindholm <leif@nuviainc.com>
Sent: Thursday, February 25, 2021 1:07 PM
To: Ashish Singhal <ashishsingha@nvidia.com>
Cc: ardb+tianocore@kernel.org <ardb+tianocore@kernel.org>; devel@edk2.groups.io <devel@edk2.groups.io>
Subject: Re: [PATCH] ArmPkg/ArmGicLib: Fix setting GICv3 Interrupt Priority

External email: Use caution opening links or attachments


Hi Ashish,

This bug was already reported by Ming (who also submitted a patch).

Tracked in https://bugzilla.tianocore.org/show_bug.cgi?id=3236, should
make it into the tree tomorrow.

Thank you for your contribution!

/
    Leif

On Thu, Feb 25, 2021 at 10:19:46 -0700, Ashish Singhal wrote:
> Incorrect register is being set for configuring interrupt
> priority. Correct register is located in SGI space and not
> in RD space.
>
> Signed-off-by: Ashish Singhal <ashishsingha@nvidia.com>
> ---
>  ArmPkg/Drivers/ArmGic/ArmGicLib.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/ArmPkg/Drivers/ArmGic/ArmGicLib.c b/ArmPkg/Drivers/ArmGic/ArmGicLib.c
> index 8ef32b3..3c0bee6 100644
> --- a/ArmPkg/Drivers/ArmGic/ArmGicLib.c
> +++ b/ArmPkg/Drivers/ArmGic/ArmGicLib.c
> @@ -236,7 +236,7 @@ ArmGicSetInterruptPriority (
>      }
>
>      MmioAndThenOr32 (
> -      GicCpuRedistributorBase + ARM_GIC_ICDIPR + (4 * RegOffset),
> +      GicCpuRedistributorBase + ARM_GICR_CTLR_FRAME_SIZE + ARM_GIC_ICDIPR + (4 * RegOffset),
>        ~(0xff << RegShift),
>        Priority << RegShift
>        );
> --
> 2.7.4
>

[-- Attachment #2: Type: text/html, Size: 3307 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-03-01 14:49 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-02-25 17:19 [PATCH] ArmPkg/ArmGicLib: Fix setting GICv3 Interrupt Priority Ashish Singhal
2021-02-25 20:07 ` Leif Lindholm
2021-03-01 14:48   ` Ashish Singhal

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox