public inbox for linux-bluetooth@vger.kernel.org
 help / color / mirror / Atom feed
From: Guillaume Bedot <littletux@zarb.org>
To: BlueZ development <bluez-devel@lists.sourceforge.net>
Subject: Re: [Bluez-devel] [PATCH] HT820, capture and  eSCO
Date: Mon, 28 Jan 2008 18:26:18 +0100	[thread overview]
Message-ID: <1201541178.7254.22.camel@localhost> (raw)
In-Reply-To: <1201531946.7254.17.camel@localhost>

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

Re,

I'm really sorry, I forgot a part of the patch....

Here is a full version.

Regards,

Guillaume B.



[-- Attachment #2: kernel-2.6.24-check-both-ends-for-esco-feature-v3.patch --]
[-- Type: text/x-patch, Size: 1579 bytes --]

--- net/bluetooth/hci_conn.c.orig	2008-01-28 09:15:50.000000000 +0100
+++ net/bluetooth/hci_conn.c	2008-01-28 18:21:45.000000000 +0100
@@ -332,6 +332,8 @@
 	if (type == ACL_LINK)
 		return acl;
 
+	if (lmp_esco_capable(hdev) && lmp_esco_capable(acl))
+		type=ESCO_LINK;
 	if (!(sco = hci_conn_hash_lookup_ba(hdev, type, dst))) {
 		if (!(sco = hci_conn_add(hdev, type, dst))) {
 			hci_conn_put(acl);
@@ -346,7 +349,7 @@
 
 	if (acl->state == BT_CONNECTED &&
 			(sco->state == BT_OPEN || sco->state == BT_CLOSED)) {
-		if (lmp_esco_capable(hdev))
+		if (type==ESCO_LINK)
 			hci_setup_sync(sco, acl->handle);
 		else
 			hci_add_sco(sco, acl->handle);
--- net/bluetooth/sco.c.orig	2008-01-28 09:15:14.000000000 +0100
+++ net/bluetooth/sco.c	2008-01-28 09:21:00.000000000 +0100
@@ -189,7 +189,7 @@
 	struct sco_conn *conn;
 	struct hci_conn *hcon;
 	struct hci_dev  *hdev;
-	int err, type;
+	int err;
 
 	BT_DBG("%s -> %s", batostr(src), batostr(dst));
 
@@ -200,9 +200,7 @@
 
 	err = -ENOMEM;
 
-	type = lmp_esco_capable(hdev) ? ESCO_LINK : SCO_LINK;
-
-	hcon = hci_connect(hdev, type, dst);
+	hcon = hci_connect(hdev, SCO_LINK, dst);
 	if (!hcon)
 		goto done;
 
--- net/bluetooth/hci_event.c.orig	2008-01-28 09:15:31.000000000 +0100
+++ net/bluetooth/hci_event.c	2008-01-28 18:17:16.000000000 +0100
@@ -720,7 +720,7 @@
 		struct hci_conn *sco = conn->link;
 		if (sco) {
 			if (!ev->status) {
-				if (lmp_esco_capable(hdev))
+				if (lmp_esco_capable(hdev) && lmp_esco_capable(conn))
 					hci_setup_sync(sco, conn->handle);
 				else
 					hci_add_sco(sco, conn->handle);


[-- Attachment #3: Type: text/plain, Size: 228 bytes --]

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/

[-- Attachment #4: Type: text/plain, Size: 164 bytes --]

_______________________________________________
Bluez-devel mailing list
Bluez-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-devel

      reply	other threads:[~2008-01-28 17:26 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-01-26  8:39 [Bluez-devel] HT820, capture and eSCO Guillaume Bedot
2008-01-26  9:01 ` Guillaume Bedot
2008-01-26 10:04   ` Guillaume Bedot
2008-01-28  8:43     ` Guillaume Bedot
2008-01-28 14:52       ` [Bluez-devel] [PATCH] " Guillaume Bedot
2008-01-28 17:26         ` Guillaume Bedot [this message]

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=1201541178.7254.22.camel@localhost \
    --to=littletux@zarb.org \
    --cc=bluez-devel@lists.sourceforge.net \
    /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