]> git.baikalelectronics.ru Git - kernel.git/commit
arm64/sve: Thin out initialisation sanity-checks for sve_max_vl
authorDave Martin <Dave.Martin@arm.com>
Fri, 1 Jun 2018 10:10:13 +0000 (11:10 +0100)
committerCatalin Marinas <catalin.marinas@arm.com>
Fri, 1 Jun 2018 14:53:07 +0000 (15:53 +0100)
commit64982315de9d1a8c7bbe9be4723835fb2b5938fb
tree63cf1f0255bc65b88b28614be8465c81e6598090
parent49c0b1f12bb1cf27ce259aa95fe8fa63c9fddad0
arm64/sve: Thin out initialisation sanity-checks for sve_max_vl

Now that the kernel SVE support is reasonably mature, it is
excessive to default sve_max_vl to the invalid value -1 and then
sprinkle WARN_ON()s around the place to make sure it has been
initialised before use.  The cpufeatures code already runs pretty
early, and will ensure sve_max_vl gets initialised.

This patch initialises sve_max_vl to something sane that will be
supported by every SVE implementation, and removes most of the
sanity checks.

The checks in find_supported_vector_length() are retained for now.
If anything goes horribly wrong, we are likely to trip a check here
sooner or later.

Signed-off-by: Dave Martin <Dave.Martin@arm.com>
Acked-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
arch/arm64/kernel/fpsimd.c
arch/arm64/kernel/ptrace.c