I am trying to enable an SDIO Wi-Fi module for SDIO 3.0 operation (SDR-140 mode) on an SoloX Sabre SD board.. The sdhci_execute_tuning() in sdhci.c handles the tuning procedure. The SoloX's host controller's SOC flags select the ESDHC_FLAG_STD_TUNING (standard tuning) for tuning the sampling clock.
In a nutshell, the sdhci_execute_tuning() function, sends CMD19 to the SDIO card up to 40 times. For each CMD19 received, the card is expected to respond with a tuning block, which contains a predefined data pattern. From what I can tell, the host controller is responsible for processing the tuning blocks sent from the card and making a determination on whether the tuning procedure is completed. The SDHC driver code monitors a flag from the host controller after each CMD19 - Tuning Block transaction to determine if the host controller has completed tuning. If the host controller has not completed tuning, it sends the next CMD19 command. If the host controller still has not completed tuning on the 40th CMD19, the host driver code aborts the tuning process and declare tuning process failure. (Note: My Linux kernel is BSP L3.14.52)
My Wi-Fi module failed the standard tuning procedure. Since the host driver is responsible for the standard tuning process for the most part, I am not quite sure how to troubleshoot the tuning failure.
My debug code showed the SDHC host didn't clear the flag (SDHCI_CTRL_EXEC_TUNING) after 40 CMD19 had been sent. There was no timeout error after each CMD19 comment was sent.
When the Wi-Fi module was installed on a i.MX6SABRE SD board, the SDHC card initialization process was able to enable UHF-I (SDR-104) mode. (Note: i.MX6SABRE SD uses a manual tuning process)
Suggestions will be greatly appreciated. Thank you!