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] [day] [month] [year] [list]
Date:	Thu, 26 Mar 2015 08:49:26 +1100
From:	NeilBrown <neilb@...e.de>
To:	Ulf Hansson <ulf.hansson@...aro.org>
Cc:	Tony Lindgren <tony@...mide.com>,
	Andreas Fenkart <afenkart@...il.com>,
	linux-mmc <linux-mmc@...r.kernel.org>,
	lkml <linux-kernel@...r.kernel.org>,
	GTA04 owners <gta04-owner@...delico.com>,
	NeilBrown <neil@...wn.name>,
	linux-omap <linux-omap@...r.kernel.org>,
	Adrian Hunter <adrian.hunter@...el.com>
Subject: Re: [PATCH 3/4] mmc: sdio: support switching to 1-bit before
 turning off clocks

On Mon, 23 Mar 2015 10:10:18 +0100 Ulf Hansson <ulf.hansson@...aro.org> wrote:

> On 24 February 2015 at 03:42, NeilBrown <neilb@...e.de> wrote:

> > @@ -941,8 +947,12 @@ void mmc_release_host(struct mmc_host *host)
> >
> >         WARN_ON(!host->claimed);
> >
> > -       if (host->ops->disable && host->claim_cnt == 1)
> > -               host->ops->disable(host);
> > +       if (host->claim_cnt == 1) {
> > +               if (atomic_read(&host->sdio_narrowed) == 1)
> > +                       atomic_set(&host->sdio_narrowed, 0);
> > +               if (host->ops->disable)
> > +                       host->ops->disable(host);
> > +       }
> 
> As omap_hsmmc in currently the only user of the
> host_ops->enable|disable() callbacks, I wonder if this approach will
> work "race-free" for those hosts that don't implement these callbacks?

Hi Ulf,
 you might have guessed, but to be explicit: I withdraw this patchset.
I much prefer the other approach that I suggested using runtime PM on
the mmc_host device and switching to 1-bit more in the pm_runtime_suspend
function.

As you say, omap_hsmmc is the only user of enable/disable and they were an
important part of my strategy in this patchset.
Which raises the question:  what is omap_hsmmc using enable/disable?

My guess is that it is largely historical - added because omap_hsmmc wanted
runtime pm before sufficient generic infrastructure was available.

I've tested a patch to remove it, and it seem fine.  I'll post it.

Thanks,
NeilBrown


Content of type "application/pgp-signature" skipped

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ