lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <6e259e6d-3821-0f2c-f308-5f5eb6550b6d@intel.com>
Date:   Wed, 30 Nov 2022 17:23:45 +0200
From:   Adrian Hunter <adrian.hunter@...el.com>
To:     Wenchao Chen <wenchao.chen@...soc.com>, ulf.hansson@...aro.org,
        orsonzhai@...il.com, baolin.wang@...ux.alibaba.com,
        zhang.lyra@...il.com
Cc:     linux-mmc@...r.kernel.org, linux-kernel@...r.kernel.org,
        zhenxiong.lai@...soc.com, yuelin.tang@...soc.com,
        gengcixi@...il.com
Subject: Re: [PATCH V2] mmc: sdhci-sprd: Fix no reset data and command after
 voltage switch

On 30/11/22 14:13, Wenchao Chen wrote:
> After switching the voltage, no reset data and command will cause
> CMD2 timeout.
> 
> Fixes: 29ca763fc26f ("mmc: sdhci-sprd: Add pin control support for voltage switch")
> Signed-off-by: Wenchao Chen <wenchao.chen@...soc.com>

Acked-by: Adrian Hunter <adrian.hunter@...el.com>

> ---
> Changelog:
> 
> v1 -> v2:
> There is no need to wait for the state of the pin to stabilize.
> ---
>  drivers/mmc/host/sdhci-sprd.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/mmc/host/sdhci-sprd.c b/drivers/mmc/host/sdhci-sprd.c
> index b92a408f138d..bec3f9e3cd3f 100644
> --- a/drivers/mmc/host/sdhci-sprd.c
> +++ b/drivers/mmc/host/sdhci-sprd.c
> @@ -470,7 +470,7 @@ static int sdhci_sprd_voltage_switch(struct mmc_host *mmc, struct mmc_ios *ios)
>  	}
>  
>  	if (IS_ERR(sprd_host->pinctrl))
> -		return 0;
> +		goto reset;
>  
>  	switch (ios->signal_voltage) {
>  	case MMC_SIGNAL_VOLTAGE_180:
> @@ -498,6 +498,8 @@ static int sdhci_sprd_voltage_switch(struct mmc_host *mmc, struct mmc_ios *ios)
>  
>  	/* Wait for 300 ~ 500 us for pin state stable */
>  	usleep_range(300, 500);
> +
> +reset:
>  	sdhci_reset(host, SDHCI_RESET_CMD | SDHCI_RESET_DATA);
>  
>  	return 0;

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ