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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <000001da5ee9$bc1dee40$3459cac0$@samsung.com>
Date: Wed, 14 Feb 2024 11:01:33 +0900
From: 이승희 <sh043.lee@...sung.com>
To: "'Christian Loehle'" <christian.loehle@....com>, "'Avri Altman'"
	<Avri.Altman@....com>, <linux-mmc@...r.kernel.org>,
	<linux-kernel@...r.kernel.org>, <ulf.hansson@...aro.org>,
	<gregkh@...uxfoundation.org>
Cc: <grant.jung@...sung.com>, <jt77.jang@...sung.com>,
	<dh0421.hwang@...sung.com>, <junwoo80.lee@...sung.com>,
	<jangsub.yi@...sung.com>, <cw9316.lee@...sung.com>,
	<sh8267.baek@...sung.com>, <wkon.kim@...sung.com>
Subject: RE: [PATCH] mmc: sd: Add a variable to check a faulty device

> -----Original Message-----
> From: Christian Loehle <christian.loehle@....com>
> Sent: Tuesday, February 13, 2024 10:35 PM
> To: 이승희 <sh043.lee@...sung.com>; 'Avri Altman' <Avri.Altman@....com>;
> linux-mmc@...r.kernel.org; linux-kernel@...r.kernel.org;
> ulf.hansson@...aro.org; gregkh@...uxfoundation.org
> Cc: grant.jung@...sung.com; jt77.jang@...sung.com;
> dh0421.hwang@...sung.com; junwoo80.lee@...sung.com; jangsub.yi@...sung.com;
> cw9316.lee@...sung.com; sh8267.baek@...sung.com; wkon.kim@...sung.com
> Subject: Re: [PATCH] mmc: sd: Add a variable to check a faulty device
> 
> On 13/02/2024 09:49, 이승희 wrote:
> >
> >
> >> -----Original Message-----
> >> From: Avri Altman <Avri.Altman@....com>
> >> Sent: Tuesday, February 13, 2024 5:42 PM
> >> To: Seunghui Lee <sh043.lee@...sung.com>; linux-mmc@...r.kernel.org;
> >> linux-kernel@...r.kernel.org; ulf.hansson@...aro.org;
> >> gregkh@...uxfoundation.org
> >> Cc: grant.jung@...sung.com; jt77.jang@...sung.com;
> >> dh0421.hwang@...sung.com; junwoo80.lee@...sung.com;
> >> jangsub.yi@...sung.com; cw9316.lee@...sung.com;
> >> sh8267.baek@...sungcom; wkon.kim@...sung.com
> >> Subject: RE: [PATCH] mmc: sd: Add a variable to check a faulty device
> >>
> >>> In mobile devices, suspend/resume situations are frequent.
> >>> In the case of a defective SD card in which initialization fails,
> >>> unnecessary initialization time is consumed for each resume.
> >>> A field is needed to check that SD card initialization has failed on
> >>> the host. It could be used to remove unnecessary initialization.
> >> I don't see where you are using this new init_failed field?
> >> Maybe instead, elaborate the logic to free_card: to detect a broken sd.
> >> e.g. instead of just if (!oldcard), if (!oldcard || !
> >> mmc_sd_alive(host)) or something.
> >>
> >> Thanks,
> >> Avri
> >>
> > Thank you for your suggestion.
> > I'm going to use it in mmc_rescan as below.
> >
> > e.g.
> > diff --git a/drivers/mmc/core/core.c b/drivers/mmc/core/core.c index
> > a8c17b4cd737..461cd75dc7ab 100644
> > --- a/drivers/mmc/core/core.c
> > +++ b/drivers/mmc/core/core.c
> > @@ -2210,7 +2210,7 @@ void mmc_rescan(struct work_struct *work)
> >                 container_of(work, struct mmc_host, detect.work);
> >         int i;
> >
> > -       if (host->rescan_disable)
> > +       if (host->rescan_disable || host->init_failed)
> >                 return;
> 
> I've seen SD cards that fail the first initialization attempt for both
> 'valid' reasons (e.g. weird insertion timing) and things like out-of-spec
> initialization time from the card, outright disabling these on the first
> fail is a bit too much IMO.
> 
> Kind Regards,
> Christian

I agree with you. It's a bit too much.
It's just simple example.

Anyway, It's difficult to distinguish between NO card and a faulty card.
That's why I'd like to merge this.
It helps that we check if it's a faulty card or not in a dump.




Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ