* [PATCH] irqchip/gic-v3-its: Reference to its_invall_cmd descriptor when building INVALL
@ 2019-12-02 7:10 Zenghui Yu
2019-12-02 10:00 ` Marc Zyngier
2020-02-08 14:58 ` [tip: irq/urgent] " tip-bot2 for Zenghui Yu
0 siblings, 2 replies; 3+ messages in thread
From: Zenghui Yu @ 2019-12-02 7:10 UTC (permalink / raw)
To: maz, tglx, jason
Cc: linux-arm-kernel, linux-kernel, wanghaibin.wang, Zenghui Yu
It looks like an obvious mistake to use its_mapc_cmd descriptor when
building the INVALL command block. It so far worked by luck because
both its_mapc_cmd.col and its_invall_cmd.col sit at the same offset of
the ITS command descriptor, but we should not rely on it.
Signed-off-by: Zenghui Yu <yuzenghui@huawei.com>
---
drivers/irqchip/irq-gic-v3-its.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/irqchip/irq-gic-v3-its.c b/drivers/irqchip/irq-gic-v3-its.c
index c52cc8d6d6b8..b3fec78b2226 100644
--- a/drivers/irqchip/irq-gic-v3-its.c
+++ b/drivers/irqchip/irq-gic-v3-its.c
@@ -598,7 +598,7 @@ static struct its_collection *its_build_invall_cmd(struct its_node *its,
struct its_cmd_desc *desc)
{
its_encode_cmd(cmd, GITS_CMD_INVALL);
- its_encode_collection(cmd, desc->its_mapc_cmd.col->col_id);
+ its_encode_collection(cmd, desc->its_invall_cmd.col->col_id);
its_fixup_cmd(cmd);
--
2.19.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] irqchip/gic-v3-its: Reference to its_invall_cmd descriptor when building INVALL
2019-12-02 7:10 [PATCH] irqchip/gic-v3-its: Reference to its_invall_cmd descriptor when building INVALL Zenghui Yu
@ 2019-12-02 10:00 ` Marc Zyngier
2020-02-08 14:58 ` [tip: irq/urgent] " tip-bot2 for Zenghui Yu
1 sibling, 0 replies; 3+ messages in thread
From: Marc Zyngier @ 2019-12-02 10:00 UTC (permalink / raw)
To: Zenghui Yu; +Cc: tglx, jason, linux-arm-kernel, linux-kernel, wanghaibin.wang
Hi Zenghui,
On 2019-12-02 07:10, Zenghui Yu wrote:
> It looks like an obvious mistake to use its_mapc_cmd descriptor when
> building the INVALL command block. It so far worked by luck because
> both its_mapc_cmd.col and its_invall_cmd.col sit at the same offset
> of
> the ITS command descriptor, but we should not rely on it.
>
> Signed-off-by: Zenghui Yu <yuzenghui@huawei.com>
> ---
> drivers/irqchip/irq-gic-v3-its.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/irqchip/irq-gic-v3-its.c
> b/drivers/irqchip/irq-gic-v3-its.c
> index c52cc8d6d6b8..b3fec78b2226 100644
> --- a/drivers/irqchip/irq-gic-v3-its.c
> +++ b/drivers/irqchip/irq-gic-v3-its.c
> @@ -598,7 +598,7 @@ static struct its_collection
> *its_build_invall_cmd(struct its_node *its,
> struct its_cmd_desc *desc)
> {
> its_encode_cmd(cmd, GITS_CMD_INVALL);
> - its_encode_collection(cmd, desc->its_mapc_cmd.col->col_id);
> + its_encode_collection(cmd, desc->its_invall_cmd.col->col_id);
>
> its_fixup_cmd(cmd);
Yup, well spotted. Thankfully, there is no impact due to the two
structures having similar layouts, but that definitely needs
fixing.
I'll queue this for post -rc1.
Thanks,
M.
--
Jazz is not dead. It just smells funny...
^ permalink raw reply [flat|nested] 3+ messages in thread
* [tip: irq/urgent] irqchip/gic-v3-its: Reference to its_invall_cmd descriptor when building INVALL
2019-12-02 7:10 [PATCH] irqchip/gic-v3-its: Reference to its_invall_cmd descriptor when building INVALL Zenghui Yu
2019-12-02 10:00 ` Marc Zyngier
@ 2020-02-08 14:58 ` tip-bot2 for Zenghui Yu
1 sibling, 0 replies; 3+ messages in thread
From: tip-bot2 for Zenghui Yu @ 2020-02-08 14:58 UTC (permalink / raw)
To: linux-tip-commits; +Cc: Zenghui Yu, Marc Zyngier, x86, LKML
The following commit has been merged into the irq/urgent branch of tip:
Commit-ID: 107945227ac5d4c37911c7841b27c64b489ce9a9
Gitweb: https://git.kernel.org/tip/107945227ac5d4c37911c7841b27c64b489ce9a9
Author: Zenghui Yu <yuzenghui@huawei.com>
AuthorDate: Mon, 02 Dec 2019 15:10:21 +08:00
Committer: Marc Zyngier <maz@kernel.org>
CommitterDate: Mon, 03 Feb 2020 10:04:19
irqchip/gic-v3-its: Reference to its_invall_cmd descriptor when building INVALL
It looks like an obvious mistake to use its_mapc_cmd descriptor when
building the INVALL command block. It so far worked by luck because
both its_mapc_cmd.col and its_invall_cmd.col sit at the same offset of
the ITS command descriptor, but we should not rely on it.
Fixes: cc2d3216f53c ("irqchip: GICv3: ITS command queue")
Signed-off-by: Zenghui Yu <yuzenghui@huawei.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20191202071021.1251-1-yuzenghui@huawei.com
---
drivers/irqchip/irq-gic-v3-its.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/irqchip/irq-gic-v3-its.c b/drivers/irqchip/irq-gic-v3-its.c
index f717586..e5a25d9 100644
--- a/drivers/irqchip/irq-gic-v3-its.c
+++ b/drivers/irqchip/irq-gic-v3-its.c
@@ -661,7 +661,7 @@ static struct its_collection *its_build_invall_cmd(struct its_node *its,
struct its_cmd_desc *desc)
{
its_encode_cmd(cmd, GITS_CMD_INVALL);
- its_encode_collection(cmd, desc->its_mapc_cmd.col->col_id);
+ its_encode_collection(cmd, desc->its_invall_cmd.col->col_id);
its_fixup_cmd(cmd);
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-02-08 14:58 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-12-02 7:10 [PATCH] irqchip/gic-v3-its: Reference to its_invall_cmd descriptor when building INVALL Zenghui Yu
2019-12-02 10:00 ` Marc Zyngier
2020-02-08 14:58 ` [tip: irq/urgent] " tip-bot2 for Zenghui Yu
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).