mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-09 04:10:18 +09:00
sd: optimize sduart not supported flag [1/1]
PD#SWPL-4858 Problem: Soc not support sduart Solution: add not supported flag in dts Verify: verify by tl1 skt Change-Id: Ifd1f975bd13b150aac9d99f60423ab4f0b903c98 Signed-off-by: Nan Li <nan.li@amlogic.com>
This commit is contained in:
@@ -702,6 +702,9 @@ static int aml_is_sduart(struct amlsd_platform *pdata)
|
||||
struct amlsd_host *host = pdata->host;
|
||||
struct sd_emmc_status *ista = (struct sd_emmc_status *)&vstat;
|
||||
|
||||
if (pdata->no_sduart)
|
||||
return 0;
|
||||
|
||||
mutex_lock(&host->pinmux_lock);
|
||||
pc = aml_devm_pinctrl_get_select(host, "sd_to_ao_uart_pins");
|
||||
|
||||
@@ -885,8 +888,7 @@ int aml_sd_uart_detect(struct amlsd_platform *pdata)
|
||||
return 1;
|
||||
pdata->is_in = true;
|
||||
pdata->gpio_cd_sta = true;
|
||||
if ((!pdata->no_sduart)
|
||||
&& aml_is_sduart(pdata)) {
|
||||
if (aml_is_sduart(pdata)) {
|
||||
aml_uart_switch(pdata, 1);
|
||||
pr_info("Uart in\n");
|
||||
mmc->caps &= ~MMC_CAP_4_BIT_DATA;
|
||||
@@ -901,8 +903,10 @@ int aml_sd_uart_detect(struct amlsd_platform *pdata)
|
||||
}
|
||||
} else {
|
||||
pr_info("normal card in\n");
|
||||
aml_uart_switch(pdata, 0);
|
||||
aml_jtag_switch_ao(pdata);
|
||||
if (!pdata->no_sduart) {
|
||||
aml_uart_switch(pdata, 0);
|
||||
aml_jtag_switch_ao(pdata);
|
||||
}
|
||||
if (host->data->chip_type == MMC_CHIP_G12A)
|
||||
host->is_sduart = 0;
|
||||
if (pdata->caps & MMC_CAP_4_BIT_DATA)
|
||||
|
||||
Reference in New Issue
Block a user