Commit ed68afa1 authored by Manivannan Sadhasivam's avatar Manivannan Sadhasivam Committed by Abel Vesa
Browse files

scsi: ufs: ufs-qcom: Add support for finding HS gear on new UFS versions



Starting from UFS controller v4, Qcom supports dual gear mode (i.e., the
controller/PHY can be configured to run in two gear speeds). But that
requires an agreement between the UFS controller and the UFS device.
This commit finds the max gear supported by both controller and device
then decides which one to use.

UFS controller's max gear can be read from the REG_UFS_PARAM0 register and
UFS device's max gear can be read from the "max-device-gear" devicetree
property.

The UFS PHY also needs to be configured with the decided gear using the
phy_set_mode_ext() API.

Signed-off-by: default avatarManivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Reviewed-by: default avatarAndrew Halaney <ahalaney@redhat.com>
parent 2c94bbc6
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment