[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v2] Arm32: MSR to SPSR needs qualification
- To: "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- From: Jan Beulich <jbeulich@xxxxxxxx>
- Date: Fri, 11 Jun 2021 15:04:24 +0200
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=VJz7WJrgdIu7Yqmi+3r6jyJnowYjSigtTjONlNknBI8=; b=EgztL39ul5Gz9vMdI1kEQ8pynhDab82CRX6kNCEXVb57YkI2RjrAGsDm20YzNg7879jQfi5YZ0IU/SfwLgfTQ+RxkgXQ4vP4qdF1eCkicnMlj3viecYMcnDG3iyz56bVBvI8OYsJn0Y0AQIrEYL/Nxk/YanfVOwf/U+rNQlGh5OshY6lYzxmSrzpmXKpe9gQORZcGDav22aC2Xr98rY+2HiMslx97yfXdj19PXf7ps4QnfDJReEdI548cYXpOr4p/BGIsrJYj/aWzA2ShWvlTlmXMDFK5BkC3ujEfzzd4j47faShYe8fijisCo4hEe35KjW4KJWkdxc2FFtpk6B7+g==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=CGg10AqhXHEfQP8m5wR+6flTYcReNqfTEbj2jNr8n75ZcFKu7iHfUewtyhzEngJIuSMjsHWxCNSsDL66LJUaQ8SwvFnUlbx6APDBS3P4UwTM0BJg1iolg/tiiCyhd//axNv3qy6B41/WPMqSBjeec9aKfZE8KT10VyBtUbmV9j9OpqePZMXX19YSOKNxiIqnRJ5pp62b8+zuk44dup5Rdu4DC9C2bZqFPX/8/IeQ+QYYBKD8AP/NDzM1XdaPSAv8FM2dfziNXFdk/mAk3qHl5GQEqTCsHBu0JY/Dy84fF0OBcbhSp+mmKl/xyPhrMKQnfLHonDFTvhd8qP1Cp/bF6g==
- Authentication-results: xen.org; dkim=none (message not signed) header.d=none;xen.org; dmarc=none action=none header.from=suse.com;
- Cc: Stefano Stabellini <sstabellini@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>
- Delivery-date: Fri, 11 Jun 2021 13:04:31 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
The Arm ARM's description of MSR (ARM DDI 0406C.d section B9.3.12)
doesn't even allow for plain "SPSR" here, and while gas accepts this, it
takes it to mean SPSR_cf. Yet surely all of SPSR wants updating on this
path, not just the lowest and highest 8 bits.
Fixes: dfcffb128be4 ("xen/arm32: SPSR_hyp/SPSR")
Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>
---
v2: Add doc ref.
--- a/xen/arch/arm/arm32/entry.S
+++ b/xen/arch/arm/arm32/entry.S
@@ -395,7 +395,7 @@ return_to_hypervisor:
ldr r11, [sp, #UREGS_pc]
msr ELR_hyp, r11
ldr r11, [sp, #UREGS_cpsr]
- msr SPSR, r11
+ msr SPSR_cxsf, r11
#ifdef CONFIG_ARM32_HARDEN_BRANCH_PREDICTOR
/*
* Hardening branch predictor may require to setup a different
|