Unverified Commit fb512ada authored by openeuler-ci-bot's avatar openeuler-ci-bot Committed by Gitee
Browse files

!11617 v2 Fix VSYNC referencing an unmapped VPE on GIC v4.0/v4.1

Merge Pull Request from: @ci-robot 
 
PR sync from: Zhou Wang <wangzhou1@hisilicon.com>
https://mailweb.openeuler.org/hyperkitty/list/kernel@openeuler.org/message/IKBUBNHG4OBMJLLEZBFUVRI3EA3IJ3YT/ 
From: caijian <caijian11@h-partners.com>

Patch#1 Fix VSYNC referencing an unmapped VPE on GIC v4.1
Patch#2 Fix VSYNC referencing an unmapped VPE on GIC v4.0

Nianyao Tang (1):
  irqchip/gic-v3-its: Fix VSYNC referencing an unmapped VPE on GIC v4.1

Zhou Wang (1):
  irqchip/gic-v3-its: Fix VSYNC referencing an unmapped VPE on GIC v4.0


-- 
2.33.0
 
https://gitee.com/openeuler/kernel/issues/IARQ2V 
 
Link:https://gitee.com/openeuler/kernel/pulls/11617

 

Reviewed-by: default avatarZhang Jianhua <chris.zjh@huawei.com>
Signed-off-by: default avatarZhang Peng <zhangpeng362@huawei.com>
parents e184a607 b695c96f
Loading
Loading
Loading
Loading
+9 −1
Original line number Diff line number Diff line
@@ -1096,6 +1096,7 @@ static struct its_vpe *its_build_vmapp_cmd(struct its_node *its,
					   struct its_cmd_block *cmd,
					   struct its_cmd_desc *desc)
{
	struct its_vpe *vpe = valid_vpe(its, desc->its_vmapp_cmd.vpe);
	unsigned long vpt_addr, vconf_addr;
	u64 target;
	bool alloc;
@@ -1108,6 +1109,13 @@ static struct its_vpe *its_build_vmapp_cmd(struct its_node *its,
		if (is_v4_1(its)) {
			alloc = !atomic_dec_return(&desc->its_vmapp_cmd.vpe->vmapp_count);
			its_encode_alloc(cmd, alloc);
			/*
			 * Unmapping a VPE is self-synchronizing on GICv4.1,
			 * no need to issue a VSYNC.
			 */
			vpe = NULL;
		} else if (is_v4(its)) {
			vpe = NULL;
		}

		goto out;
@@ -1142,7 +1150,7 @@ static struct its_vpe *its_build_vmapp_cmd(struct its_node *its,
out:
	its_fixup_cmd(cmd);

	return valid_vpe(its, desc->its_vmapp_cmd.vpe);
	return vpe;
}

static struct its_vpe *its_build_vmapti_cmd(struct its_node *its,