]> git.baikalelectronics.ru Git - kernel.git/commit
Bluetooth: Refactor write_room() calculation
authorPeter Hurley <peter@hurleysoftware.com>
Mon, 10 Feb 2014 01:59:23 +0000 (20:59 -0500)
committerMarcel Holtmann <marcel@holtmann.org>
Fri, 14 Feb 2014 21:39:32 +0000 (13:39 -0800)
commit978dd6a013eb54fad64736f88e9494e077527ea6
tree4f5b863566aa2b255cd99b928bca2df96767deb8
parent06e8733d7d1d297e1bcc8fb3e5335045902fa61f
Bluetooth: Refactor write_room() calculation

Compute the amount of space available for a single write()
within rfcomm_room(); clamp to 0 for negative values. Note
this patch does not change the result of the computation.

Report the amount of room returned in the debug printk.

Signed-off-by: Peter Hurley <peter@hurleysoftware.com>
Tested-By: Alexander Holler <holler@ahsoftware.de>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
net/bluetooth/rfcomm/tty.c