[Xenial master-next][PATCH] UBUNTU: SAUCE: Bluetooth: Use host bridge subsystem IDs to identify Edge Gateways

Mario_Limonciello at Dell.com Mario_Limonciello at Dell.com
Fri Aug 26 13:55:40 UTC 2016


> -----Original Message-----
> From: Wen-chien Jesse Sung [mailto:jesse.sung at canonical.com]
> Sent: Friday, August 26, 2016 5:20 AM
> To: kernel-team at lists.ubuntu.com
> Cc: Kabir, Rezwanul <Rezwanul_Kabir at Dell.com>; Limonciello, Mario
> <Mario_Limonciello at Dell.com>
> Subject: [Xenial master-next][PATCH] UBUNTU: SAUCE: Bluetooth: Use host
> bridge subsystem IDs to identify Edge Gateways
> 
> BugLink: https://launchpad.net/bugs/1512999
> 
> Since DMI IDs may be different between models while subsystem IDs of
> host bridge will stay the same, use pci_get_subsys() instead of
> dmi_match() to identify Edge Gateways.
> 
> Signed-off-by: Wen-chien Jesse Sung <jesse.sung at canonical.com>
> ---
>  drivers/bluetooth/btusb.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/bluetooth/btusb.c b/drivers/bluetooth/btusb.c
> index 5d0c92e..00c251c 100644
> --- a/drivers/bluetooth/btusb.c
> +++ b/drivers/bluetooth/btusb.c
> @@ -24,7 +24,7 @@
>  #include <linux/module.h>
>  #include <linux/usb.h>
>  #include <linux/firmware.h>
> -#include <linux/dmi.h>
> +#include <linux/pci.h>
>  #include <asm/unaligned.h>
> 
>  #include <net/bluetooth/bluetooth.h>
> @@ -2975,8 +2975,8 @@ static int btusb_probe(struct usb_interface *intf,
> 
>  	if (id->driver_info & BTUSB_MARVELL) {
>  		hdev->set_bdaddr = btusb_set_bdaddr_marvell;
> -		if (dmi_match(DMI_PRODUCT_NAME, "Edge Gateway 5000")
> ||
> -			dmi_match(DMI_PRODUCT_NAME, "Edge Gateway
> 5100")) {
> +		if (pci_get_subsys(PCI_ANY_ID, PCI_ANY_ID, 0x1028, 0x0720,
> NULL) ||
> +			pci_get_subsys(PCI_ANY_ID, PCI_ANY_ID, 0x1028,
> 0x0733, NULL)) {
>  			hdev->post_open = btusb_edge_post_open;
>  			hdev->shutdown = btusb_edge_shutdown;
>  		}
> --
> 2.7.4

LGTM.




More information about the kernel-team mailing list