From: Jui-Hao Chiang <windtracekimo@gmail.com>
To: bluez-devel@lists.sourceforge.net
Subject: Re: [Bluez-devel] Problem automatic flush timeout
Date: Fri, 22 Aug 2008 14:03:09 +0000 (UTC) [thread overview]
Message-ID: <loom.20080822T132657-838@post.gmane.org> (raw)
In-Reply-To: loom.20080822T022926-635@post.gmane.org
Hi,
What I found in net/bluetooth/hci_core.c and net/bluetooth/hci_event.c are
(1) the "Flush Occured Event" (ocf 0x11) is not handled in hci_event
(2) while the user socket keeps pushing the data via
l2cap_sock_sendmsg->l2cap_do_send->hci_send_acl
->hci_sched_tx->hci_tx_task->hci_sched_acl
Eventually it stops in hci_sched_acl when checking hdev->acl_cnt.
I consider that hdev->acl_cnt means: "the number of ACL packet we can push to
hci_usb".
Thus, I think the possible way to handle this event is to
(1) add in "include/net/bluetooth/hci.h"
#define HCI_EV_FLUSH_OCCURED 0x11
(2) catch the event in hci_event_packet, and do the following (same as
hci_num_comp_pkts_evt)
if ((++ hdev->acl_cnt) > hdev->acl_pkts) hdev->acl_cnt = hdev->acl_pkts;
(3) decrement the conn->sent by
atomic_sub(count, &conn->sent);
Please correct me if I am wrong.
Jui-Hao
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Bluez-devel mailing list
Bluez-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-devel
next prev parent reply other threads:[~2008-08-22 14:03 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-08-22 2:41 [Bluez-devel] Problem automatic flush timeout Jui-Hao Chiang
2008-08-22 14:03 ` Jui-Hao Chiang [this message]
2008-08-23 19:33 ` [Bluez-devel] [Patch] Flush Occurred Event Jui-Hao Chiang
2008-08-23 20:22 ` Marcel Holtmann
2008-08-23 21:13 ` Jui-Hao Chiang
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=loom.20080822T132657-838@post.gmane.org \
--to=windtracekimo@gmail.com \
--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