Commit 3bb15843 authored by Mark Brown's avatar Mark Brown Committed by yanhaitao
Browse files

arm64/sve: Remove sve_load_from_fpsimd_state()

mainline inclusion
from mainline-v5.16-rc1
commit b53223e0
category: feature
bugzilla: https://gitee.com/openeuler/kernel/issues/I8E73O
CVE: NA

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=b53223e0a4d9fbdba1a1dd1161f7240506666946



-------------------------------------------------

Following optimisations of the SVE register handling we no longer load the
SVE state from a saved copy of the FPSIMD registers, we convert directly
in registers or from one saved state to another. Remove the function so we
don't need to update it during further refactoring.

Signed-off-by: default avatarMark Brown <broonie@kernel.org>
Link: https://lore.kernel.org/r/20211019172247.3045838-3-broonie@kernel.org


Signed-off-by: default avatarWill Deacon <will@kernel.org>
Signed-off-by: default avatarWang ShaoBo <bobo.shaobowang@huawei.com>
parent eda9b197
Loading
Loading
Loading
Loading
+0 −2
Original line number Diff line number Diff line
@@ -70,8 +70,6 @@ extern void sve_save_state(void *state, u32 *pfpsr);
extern void sve_load_state(void const *state, u32 const *pfpsr,
			   unsigned long vq_minus_1);
extern void sve_flush_live(unsigned long vq_minus_1);
extern void sve_load_from_fpsimd_state(struct user_fpsimd_state const *state,
				       unsigned long vq_minus_1);
extern unsigned int sve_get_vl(void);
extern void sve_set_vq(unsigned long vq_minus_1);

+0 −16
Original line number Diff line number Diff line
@@ -53,22 +53,6 @@ SYM_FUNC_START(sve_set_vq)
	ret
SYM_FUNC_END(sve_set_vq)

/*
 * Load SVE state from FPSIMD state.
 *
 * x0 = pointer to struct fpsimd_state
 * x1 = VQ - 1
 *
 * Each SVE vector will be loaded with the first 128-bits taken from FPSIMD
 * and the rest zeroed. All the other SVE registers will be zeroed.
 */
SYM_FUNC_START(sve_load_from_fpsimd_state)
	sve_load_vq	x1, x2, x3
	fpsimd_restore	x0, 8
	sve_flush_p_ffr
	ret
SYM_FUNC_END(sve_load_from_fpsimd_state)

/*
 * Zero all SVE registers but the first 128-bits of each vector
 *