Skip to content

Commit

Permalink
Bluetooth: hci_bcm: Fix unwanted error reporting if no bcm dev
Browse files Browse the repository at this point in the history
The hci_bcm proto is able to operate without bcm platform device linked
to its uart port. In that case, firmware can be applied, but there is
no power operation (no gpio/irq resources mgmt).

However, the current implementation breaks this use case because of
reporting a ENODEV error in the bcm setup procedure if bcm_request_irq
fails (which is the case if no bcm device linked).

Fix this by removing bcm_request_irq error forwarding.

Signed-off-by: Loic Poulain <loic.poulain@intel.com>
Reported-by: Ian Molton <ian@mnementh.co.uk>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
  • Loading branch information
Loic Poulain authored and Marcel Holtmann committed Jun 27, 2017
1 parent 640e32c commit cdd24a2
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions drivers/bluetooth/hci_bcm.c
Original file line number Diff line number Diff line change
Expand Up @@ -419,8 +419,7 @@ static int bcm_setup(struct hci_uart *hu)
if (err)
return err;

err = bcm_request_irq(bcm);
if (!err)
if (!bcm_request_irq(bcm))
err = bcm_setup_sleep(hu);

return err;
Expand Down

0 comments on commit cdd24a2

Please sign in to comment.