sdio: Adjust the location of the GXL best sampling point

PD#160789: sdio: optimizing the selection of sdio tuning sampling points

[problem] When all sampling points can be sampled correctly,

select 0 points as the best sampling point.M8 platform is normal,

but some S905 platform is not suitable.

[resolved] The GXL platfoarm selects the intermediate

point of all sampling points as the best sampling point

Change-Id: I59097daa8fe3d99f2f11a3e1347945c8eea4e1c9
Signed-off-by: Long Yu <long.yu@amlogic.com>
This commit is contained in:
Long Yu
2018-03-23 11:31:39 +08:00
committed by Yixun Lan
parent 9b43aa868f
commit 8ba4becb1e

View File

@@ -747,7 +747,8 @@ tunning:
if ((best_win_size != clk_div)
|| (aml_card_type_sdio(pdata)
&& (host->data->chip_type == MMC_CHIP_GXM))) {
&& ((host->data->chip_type == MMC_CHIP_GXM)
|| (host->data->chip_type == MMC_CHIP_GXL)))) {
adj_delay_find = best_win_start + (best_win_size - 1) / 2
+ (best_win_size - 1) % 2;
adj_delay_find = adj_delay_find % clk_div;