Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c1ceee5e authored by David S. Miller's avatar David S. Miller
Browse files

Merge branch 'for-upstream' of...

Merge branch 'for-upstream' of git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth-next



Johan Hedberg says:

====================
pull request: bluetooth-next 2017-02-19

Here's a set of Bluetooth patches for the 4.11 kernel:

 - New USB IDs to the btusb driver
 - Race fix in btmrvl driver
 - Added out-of-band wakeup support to the btusb driver
 - NULL dereference fix to bt_sock_recvmsg

Please let me know if there are any issues pulling. Thanks.
====================

Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parents 24045a03 8f91566f
Loading
Loading
Loading
Loading
+43 −0
Original line number Diff line number Diff line
Generic Bluetooth controller over USB (btusb driver)
---------------------------------------------------

Required properties:

  - compatible : should comply with the format "usbVID,PID" specified in
		 Documentation/devicetree/bindings/usb/usb-device.txt
		 At the time of writing, the only OF supported devices
		 (more may be added later) are:

		  "usb1286,204e" (Marvell 8997)

Also, vendors that use btusb may have device additional properties, e.g:
Documentation/devicetree/bindings/net/marvell-bt-8xxx.txt

Optional properties:

  - interrupt-parent: phandle of the parent interrupt controller
  - interrupt-names: (see below)
  - interrupts : The interrupt specified by the name "wakeup" is the interrupt
		 that shall be used for out-of-band wake-on-bt. Driver will
		 request this interrupt for wakeup. During system suspend, the
		 irq will be enabled so that the bluetooth chip can wakeup host
		 platform out of band. During system resume, the irq will be
		 disabled to make sure unnecessary interrupt is not received.

Example:

Following example uses irq pin number 3 of gpio0 for out of band wake-on-bt:

&usb_host1_ehci {
    status = "okay";
    #address-cells = <1>;
    #size-cells = <0>;

    mvl_bt1: bt@1 {
	compatible = "usb1286,204e";
	reg = <1>;
	interrupt-parent = <&gpio0>;
	interrupt-name = "wakeup";
	interrupts = <3 IRQ_TYPE_LEVEL_LOW>;
    };
};
+38 −8
Original line number Diff line number Diff line
Marvell 8897/8997 (sd8897/sd8997) bluetooth SDIO devices
Marvell 8897/8997 (sd8897/sd8997) bluetooth devices (SDIO or USB based)
------
The 8997 devices supports multiple interfaces. When used on SDIO interfaces,
the btmrvl driver is used and when used on USB interface, the btusb driver is
used.

Required properties:

  - compatible : should be one of the following:
	* "marvell,sd8897-bt"
	* "marvell,sd8997-bt"
	* "marvell,sd8897-bt" (for SDIO)
	* "marvell,sd8997-bt" (for SDIO)
	* "usb1286,204e"      (for USB)

Optional properties:

  - marvell,cal-data: Calibration data downloaded to the device during
		      initialization. This is an array of 28 values(u8).
		      This is only applicable to SDIO devices.

  - marvell,wakeup-pin: It represents wakeup pin number of the bluetooth chip.
		        firmware will use the pin to wakeup host system (u16).
@@ -18,10 +23,15 @@ Optional properties:
		      platform. The value will be configured to firmware. This
		      is needed to work chip's sleep feature as expected (u16).
  - interrupt-parent: phandle of the parent interrupt controller
  - interrupts : interrupt pin number to the cpu. Driver will request an irq based
		 on this interrupt number. During system suspend, the irq will be
		 enabled so that the bluetooth chip can wakeup host platform under
		 certain condition. During system resume, the irq will be disabled
  - interrupt-names: Used only for USB based devices (See below)
  - interrupts : specifies the interrupt pin number to the cpu. For SDIO, the
		 driver will use the first interrupt specified in the interrupt
		 array. For USB based devices, the driver will use the interrupt
		 named "wakeup" from the interrupt-names and interrupt arrays.
		 The driver will request an irq based on this interrupt number.
		 During system suspend, the irq will be enabled so that the
		 bluetooth chip can wakeup host platform under certain
		 conditions. During system resume, the irq will be disabled
		 to make sure unnecessary interrupt is not received.

Example:
@@ -29,7 +39,9 @@ Example:
IRQ pin 119 is used as system wakeup source interrupt.
wakeup pin 13 and gap 100ms are configured so that firmware can wakeup host
using this device side pin and wakeup latency.
calibration data is also available in below example.

Example for SDIO device follows (calibration data is also available in
below example).

&mmc3 {
	status = "okay";
@@ -54,3 +66,21 @@ calibration data is also available in below example.
		marvell,wakeup-gap-ms = /bits/ 16 <0x64>;
	};
};

Example for USB device:

&usb_host1_ohci {
    status = "okay";
    #address-cells = <1>;
    #size-cells = <0>;

    mvl_bt1: bt@1 {
	compatible = "usb1286,204e";
	reg = <1>;
	interrupt-parent = <&gpio0>;
	interrupt-names = "wakeup";
	interrupts = <119 IRQ_TYPE_LEVEL_LOW>;
	marvell,wakeup-pin = /bits/ 16 <0x0d>;
	marvell,wakeup-gap-ms = /bits/ 16 <0x64>;
    };
};
+1 −1
Original line number Diff line number Diff line
@@ -344,7 +344,7 @@ config BT_WILINK

config BT_QCOMSMD
	tristate "Qualcomm SMD based HCI support"
	depends on QCOM_SMD && QCOM_WCNSS_CTRL
	depends on (QCOM_SMD && QCOM_WCNSS_CTRL) || COMPILE_TEST
	select BT_QCA
	help
	  Qualcomm SMD based HCI driver.
+2 −0
Original line number Diff line number Diff line
@@ -94,6 +94,7 @@ static const struct usb_device_id ath3k_table[] = {
	{ USB_DEVICE(0x04CA, 0x300f) },
	{ USB_DEVICE(0x04CA, 0x3010) },
	{ USB_DEVICE(0x04CA, 0x3014) },
	{ USB_DEVICE(0x04CA, 0x3018) },
	{ USB_DEVICE(0x0930, 0x0219) },
	{ USB_DEVICE(0x0930, 0x021c) },
	{ USB_DEVICE(0x0930, 0x0220) },
@@ -162,6 +163,7 @@ static const struct usb_device_id ath3k_blist_tbl[] = {
	{ USB_DEVICE(0x04ca, 0x300f), .driver_info = BTUSB_ATH3012 },
	{ USB_DEVICE(0x04ca, 0x3010), .driver_info = BTUSB_ATH3012 },
	{ USB_DEVICE(0x04ca, 0x3014), .driver_info = BTUSB_ATH3012 },
	{ USB_DEVICE(0x04ca, 0x3018), .driver_info = BTUSB_ATH3012 },
	{ USB_DEVICE(0x0930, 0x0219), .driver_info = BTUSB_ATH3012 },
	{ USB_DEVICE(0x0930, 0x021c), .driver_info = BTUSB_ATH3012 },
	{ USB_DEVICE(0x0930, 0x0220), .driver_info = BTUSB_ATH3012 },
+3 −0
Original line number Diff line number Diff line
@@ -178,6 +178,9 @@ static int btbcm_reset(struct hci_dev *hdev)
	}
	kfree_skb(skb);

	/* 100 msec delay for module to complete reset process */
	msleep(100);

	return 0;
}

Loading