linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Arnd Hannemann <arnd@arndnet.de>
To: Ohad Ben-Cohen <ohad@wizery.com>
Cc: "linux-mmc@vger.kernel.org" <linux-mmc@vger.kernel.org>,
	"linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>,
	linux-kernel@vger.kernel.org
Subject: Re: regression: b43-sdio: probe of mmc0:0001:1 failed with error -16
Date: Sun, 31 Oct 2010 22:51:39 +0100	[thread overview]
Message-ID: <4CCDE4EB.7060001@arndnet.de> (raw)
In-Reply-To: <AANLkTin80pwnb1DX8OdZK3Wgsq0nj==G9VM3pahsmo0U@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 967 bytes --]

Hi Ohad,

Am 31.10.2010 20:14, schrieb Ohad Ben-Cohen:

> On Sun, Oct 31, 2010 at 7:16 PM, Arnd Hannemann <arnd@arndnet.de> wrote:
>> b43-sdio: probe of mmc0:0001:1 failed with error -16
> 
> It's exactly what Daniel is experiencing with the XO-1.5.
> 
> In Daniel's scenario, mmc_sdio_init_card() fails because
> mmc_send_relative_addr() returns -110.
> 
> Can you please check out if that's the same thing you have too ?

No, it seems to be the pm_runtime_get_sync in sdio_bus.c::sdio_bus_probe().

If I test with CONFIG_PM_RUNTIME=y and the attached modifications,
then I get this as output:

root@ap4evb:~# modprobe b43
[   29.859375] cfg80211: Calling CRDA to update world regulatory domain
[   30.226562] pm_runtime_get_sync: -16
[   30.234375] b43-sdio: probe of mmc0:0001:1 failed with error -16
[   30.242187] Broadcom 43xx driver loaded [ Features: LS, Firmware-ID: FW13 ]

If CONFIG_PM_RUNTIME is not set in .config, the problem goes away.

Regards,
Arnd


[-- Attachment #2: diff --]
[-- Type: text/plain, Size: 996 bytes --]

diff --git a/drivers/mmc/core/sd_ops.c b/drivers/mmc/core/sd_ops.c
index 797cdb5..57b6dd4 100644
--- a/drivers/mmc/core/sd_ops.c
+++ b/drivers/mmc/core/sd_ops.c
@@ -237,8 +237,10 @@ int mmc_send_relative_addr(struct mmc_host *host, unsigned int *rca)
 	cmd.flags = MMC_RSP_R6 | MMC_CMD_BCR;
 
 	err = mmc_wait_for_cmd(host, &cmd, MMC_CMD_RETRIES);
-	if (err)
+	if (err) {
+		printk(KERN_INFO "%s(): %d\n", __func__, err);
 		return err;
+	}
 
 	*rca = cmd.resp[0] >> 16;
 
diff --git a/drivers/mmc/core/sdio_bus.c b/drivers/mmc/core/sdio_bus.c
index 2716c7a..102c163 100644
--- a/drivers/mmc/core/sdio_bus.c
+++ b/drivers/mmc/core/sdio_bus.c
@@ -133,8 +133,10 @@ static int sdio_bus_probe(struct device *dev)
 	 * pm_runtime_get_noresume() in its remove routine.
 	 */
 	ret = pm_runtime_get_sync(dev);
-	if (ret < 0)
+	if (ret < 0) {
+		printk(KERN_INFO "pm_runtime_get_sync: %d\n", ret);
 		goto out;
+	}
 
 	/* Set the default block size so the driver is sure it's something
 	 * sensible. */

  reply	other threads:[~2010-10-31 21:51 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-31 17:16 regression: b43-sdio: probe of mmc0:0001:1 failed with error -16 Arnd Hannemann
2010-10-31 17:25 ` Chris Ball
2010-10-31 17:35 ` Arnd Hannemann
2010-10-31 19:14 ` Ohad Ben-Cohen
2010-10-31 21:51   ` Arnd Hannemann [this message]
2010-11-01  4:50     ` Ohad Ben-Cohen
2010-11-01  8:05       ` Arnd Hannemann
2010-11-01  9:02         ` Ohad Ben-Cohen
2010-11-01 14:22           ` Arnd Hannemann
2010-11-01 14:33             ` Ohad Ben-Cohen

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=4CCDE4EB.7060001@arndnet.de \
    --to=arnd@arndnet.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).