Skip to content
Unverified Commit 2c8af6a5 authored by Yicong Yang's avatar Yicong Yang Committed by Mark Brown
Browse files

spi: hisi-sfc-v3xx: factor out IO modes configuration



Factor IO modes configuration out of hisi_sfc_v3xx_generic_exec_op()
using an IO modes lookup table. This will make the process a bit clearer
and reduce the cyclomatic complexity. Simplify the IO mode definition
macros a little bit as well.

Also add the .supports_op() method for the controller mem ops, in order
to avoid OOB access.

Acked-by: default avatarJohn Garry <john.garry@huawei.com>
Signed-off-by: default avatarYicong Yang <yangyicong@hisilicon.com>
Link: https://lore.kernel.org/r/1600950270-52536-2-git-send-email-yangyicong@hisilicon.com


Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent f09a433b
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment