Thread (10 messages) flat view 10 messages, 6 authors, 2011-06-02

Re: [PATCH] Bluetooth: Add BT_POWER L2CAP socket option.

From: Jaikumar Ganesh <hidden>
Date: 2011-05-25 01:07:05

Luiz:

On Tue, May 24, 2011 at 11:24 AM, Luiz Augusto von Dentz
[off-list ref] wrote:
Hi Jaikumar,

On Tue, May 24, 2011 at 7:44 PM, Jaikumar Ganesh [off-list ref] wrote:
quoted
Hi Luiz, Ville:

On Tue, May 24, 2011 at 9:20 AM, Luiz Augusto von Dentz
[off-list ref] wrote:
quoted
Hi Jaikumar,

On Tue, May 24, 2011 at 11:37 AM, Ville Tervo [off-list ref] wrote:
quoted
Hi Jaikumar,

On Mon, May 23, 2011 at 06:06:04PM -0700, ext Jaikumar Ganesh wrote:
quoted
Add BT_POWER socket option used to control the power
characteristics of the underlying ACL link. When the remote end
has put the link in sniff mode and the host stack wants to send
data we need need to explicitly exit sniff mode to work well with
certain devices (For example, A2DP on Plantronics Voyager 855).
However, this causes problems with HID devices.

Hence, moving into active mode when sending data, irrespective
of who set the sniff mode has been made as a socket option. By
default, we will move into active mode. HID devices can set the
L2CAP socket option to prevent this from happening.
I would prefer keeping old way the default way. Otherwise you need to update
all socket users in user space. Other that that this looks good to me.
What is wrong that we need such control to be done in userspace?
I don't think my emails reached the list so sending it again.

Ville:
   Its the other way round. With this approach and the default value,
only the HID
userspace socket needs to be modified - nothing else.

Luiz:
   The HID devices can send data even when in sniff mode and hence we
need to change the userspace
L2CAP socket option. While sending data without exiting sniff mode for
A2DP for example, causes problems
as explained in the commit message.
Now I get it, we should definitely fix it for a2dp/hfp, but still
introducing new socket options it is a quite dangerous game, I wonder
how much power do we really save in case of HID and at what cost since
it probably add latency to input devices while on sniff mode.
This has been discussed many times on this list and some patches posted before.
But they added socket options to the old style sockets. We need a
socket option for this case. I dug up this old discussion:
http://search.gmane.org/?query=What+is+the+motivation+for+conn-%3Epower_save&group=gmane.linux.bluez.kernel
--
Luiz Augusto von Dentz
Computer Engineer
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help