From: Luiz Carlos Ramos <lramos.prof@yahoo.com.br>
To: Marcel Holtmann <marcel@holtmann.org>,
Johan Hedberg <johan.hedberg@gmail.com>
Cc: linux-bluetooth@vger.kernel.org
Subject: [PATCH] ath3k: add warning when switch pid is not working
Date: Fri, 7 Sep 2018 20:35:49 -0300 [thread overview]
Message-ID: <20180907233549.GE3379@giustizia.org> (raw)
This patch adds a warning message in the ath3k driver when
ath3k_switch_pid() returns error.
This event happens in a specific laptop, with an adapter which
identifies itself as 0cf3:0036. Surprisingly, the adapter works even
after this event - hence a warning is chosen instead of an error.
The current version of ath3k doesn't check the return value of
ath3k_switch_pid() and so this event may remain undetected in the
original version.
Signed-off-by: Luiz Carlos Ramos <lramos.prof@yahoo.com.br>
---
drivers/bluetooth/ath3k.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/bluetooth/ath3k.c b/drivers/bluetooth/ath3k.c
index 3d7a5c149af3..3a8c47efea55 100644
--- a/drivers/bluetooth/ath3k.c
+++ b/drivers/bluetooth/ath3k.c
@@ -546,7 +546,10 @@ static int ath3k_probe(struct usb_interface *intf,
BT_ERR("Set normal mode failed");
return ret;
}
- ath3k_switch_pid(udev);
+ ret = ath3k_switch_pid(udev);
+ if (ret < 0)
+ BT_WARN("Warning: switch pid failed (ret=%d)", ret);
+
return 0;
}
--
2.14.4
next reply other threads:[~2018-09-07 23:35 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-09-07 23:35 Luiz Carlos Ramos [this message]
2018-09-27 10:48 ` [PATCH] ath3k: add warning when switch pid is not working Marcel Holtmann
2018-09-27 16:15 ` Luiz Carlos Ramos
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=20180907233549.GE3379@giustizia.org \
--to=lramos.prof@yahoo.com.br \
--cc=johan.hedberg@gmail.com \
--cc=linux-bluetooth@vger.kernel.org \
--cc=marcel@holtmann.org \
/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).