All of lore.kernel.org
 help / color / mirror / Atom feed
From: "John W. Linville" <linville@tuxdriver.com>
To: Ohad Ben-Cohen <ohad@wizery.com>
Cc: linux-wireless@vger.kernel.org,
	Luciano Coelho <luciano.coelho@nokia.com>
Subject: Re: [PATCH] wl1271: sdio: claim host only when doing IO
Date: Tue, 14 Sep 2010 16:30:01 -0400	[thread overview]
Message-ID: <20100914203000.GF2484@tuxdriver.com> (raw)
In-Reply-To: <1283822661-16018-1-git-send-email-ohad@wizery.com>

On Tue, Sep 07, 2010 at 04:24:21AM +0300, Ohad Ben-Cohen wrote:
> Do not maintain a persistent sdio_claim_host state. Instead,
> claim host before doing IO and release host soon after.
> 
> This fixes several mmc deadlock scenarios, e.g. during
> suspend/resume.
> 
> Signed-off-by: Ohad Ben-Cohen <ohad@wizery.com>

<snip>

> @@ -160,13 +189,11 @@ static void wl1271_sdio_set_power(struct wl1271 *wl, bool enable)
>  	 * keep host claimed while wlan is in use to keep wl1271
>  	 * alive.
>  	 */
> -	if (enable) {
> -		sdio_claim_host(func);
> -		sdio_enable_func(func);
> -	} else {
> -		sdio_disable_func(func);
> -		sdio_release_host(func);
> -	}
> +	if (enable)
> +		return wl1271_sdio_power_on(wl);
> +	else
> +		return wl1271_sdio_power_off(wl);
> +
>  }

Please don't add new warnings...

drivers/net/wireless/wl12xx/wl1271_sdio.c: In function ‘wl1271_sdio_set_power’:
drivers/net/wireless/wl12xx/wl1271_sdio.c:193: warning: ‘return’ with a value, in function returning void
drivers/net/wireless/wl12xx/wl1271_sdio.c:195: warning: ‘return’ with a value, in function returning void
drivers/net/wireless/wl12xx/wl1271_sdio.c:186: warning: unused variable ‘func’

I'll fix these in a separate patch.

John
-- 
John W. Linville		Someday the world will need a hero, and you
linville@tuxdriver.com			might be all we have.  Be ready.

  parent reply	other threads:[~2010-09-14 20:29 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-07  1:24 [PATCH] wl1271: sdio: claim host only when doing IO Ohad Ben-Cohen
2010-09-08 18:00 ` Luciano Coelho
2010-09-14 20:30 ` John W. Linville [this message]
2010-09-14 20:30   ` [PATCH] wl1271: remove warnings in wl1271_sdio_set_power John W. Linville
2010-09-14 21:30   ` [PATCH] wl1271: sdio: claim host only when doing IO Ohad Ben-Cohen
2010-09-15  1:18     ` John W. Linville

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100914203000.GF2484@tuxdriver.com \
    --to=linville@tuxdriver.com \
    --cc=linux-wireless@vger.kernel.org \
    --cc=luciano.coelho@nokia.com \
    --cc=ohad@wizery.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.