Re: [PATCH] Bluetooth: Fix redundant device (un)blocked events

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Johan,

> For the Block/Unblock Device mgmt commands we should only emit the
> Blocked/Unblocked events on any socket except for the one which received
> the command. The code was previously incorrectly trying to look up a
> non-existent pending command and thereby ending up not skipping the
> command socket for the event.
> 
> We can simplify the code a lot by simply sending the event directly from
> the command handler functions. We have the reference to the command
> socket available there which makes it easy to pass to the mgmt_event
> function for skipping.
> 
> The only notable side-effect of this is that the old blacklisting
> ioctl's no-longer cause mgmt events to be emitted, however as user space
> versions using these ioctl's are not mgmt-aware this is acceptable.
> 
> Signed-off-by: Johan Hedberg <johan.hedberg@xxxxxxxxx>
> ---
> include/net/bluetooth/hci_core.h |  2 --
> net/bluetooth/hci_core.c         |  4 ++--
> net/bluetooth/mgmt.c             | 50 +++++++++++++---------------------------
> 3 files changed, 18 insertions(+), 38 deletions(-)

patch has been applied to bluetooth-next tree.

Regards

Marcel

--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux