From patchwork Wed Nov 7 10:13:04 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chen-Yu Tsai X-Patchwork-Id: 10672091 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id B3FF515E9 for ; Wed, 7 Nov 2018 10:15:55 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A0F17284E9 for ; Wed, 7 Nov 2018 10:15:55 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 94BF628C93; Wed, 7 Nov 2018 10:15:55 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.6 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 96F3F284E9 for ; Wed, 7 Nov 2018 10:15:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=15jzJXXjXeGGO3zl3fOIVvFRwF5KeUXvuPevLfcGbEA=; b=MF880tlD/F34L9 6UK5+J1fp6qpUeJHXU6OS1C5wz6iLz4qRC8r0zNJMvRiw8sjfnmRQyevtZcnL5t+TFQk/G1A8lOtw D553DrqHpPPOmaY94HInRM/6DFVQCBKA2dhqHrn+6KKEM/68/3wNboINjlbz2xzDl2p6f+p68HQZ1 qMcX2zciLhkPYxL0pOq9RWfwLJPW3RtLQ9yEWhycJ9bwuwg6SRLBUyETxH10x3dKlCl4/6sWHS4jh p79ZQwMFu5tlti4GDvxcH8Evehg6S9Cmve0LU2H1re9Oi3VxaaNq+kFuaFxTL7yWcSsc0rbF0B1qm d9hoj5Girg38joV0K9DQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gKKsJ-0006dW-AM; Wed, 07 Nov 2018 10:15:51 +0000 Received: from merlin.infradead.org ([2001:8b0:10b:1231::1]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gKKqR-0003XB-U8 for linux-arm-kernel@bombadil.infradead.org; Wed, 07 Nov 2018 10:13:55 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=Content-Transfer-Encoding:MIME-Version: References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To: Content-Type:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help: List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=pvXQsixDEROa3n0jn3opNTz3lklAilxLmX/5eF57eGE=; b=XwOOLr8kQF7WmF2G4yQRr2BaYv AawqJ7UnuVGKY5RlmjXoAp7Eiql+f6oeOUKeKkxdqSih/HDQREHBZFFtCi9RN6blsZYSMwVLwdmyu nLASSS/osVf27uBUEUU5N4TlsNYt9yw2b3Xdp6lNSEn0mH80PfwzRdJyYjhKqosDoZzc2V/oH3bGW wd2miqrMzufmnRfZGZ6jRJneyJIyBmipTla/I6yi4Pj4DSFK7j7MXk772JAQxBN3xKGBKW0HHsHni NO8moDXg408goVx76/Hq6KxQkEklGrXg2Gr7y49/o8nrC+0l58MDleK6dX/nldcyiH6h3IAyiE3M5 u/fgwUeA==; Received: from mirror2.csie.ntu.edu.tw ([140.112.30.76] helo=wens.csie.org) by merlin.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gKKqO-00040r-En for linux-arm-kernel@lists.infradead.org; Wed, 07 Nov 2018 10:13:54 +0000 Received: by wens.csie.org (Postfix, from userid 1000) id AF06F5FD96; Wed, 7 Nov 2018 18:13:16 +0800 (CST) From: Chen-Yu Tsai To: Marcel Holtmann , Johan Hedberg , Rob Herring , Mark Rutland , Maxime Ripard Subject: [PATCH 11/15] Bluetooth: hci_bcm: Add BCM20702A1 variant Date: Wed, 7 Nov 2018 18:13:04 +0800 Message-Id: <20181107101308.7626-12-wens@csie.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181107101308.7626-1-wens@csie.org> References: <20181107101308.7626-1-wens@csie.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181107_051352_904734_803C6446 X-CRM114-Status: GOOD ( 11.96 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-bluetooth@vger.kernel.org, linux-sunxi@googlegroups.com, Loic Poulain , Maxime Ripard , Chen-Yu Tsai , linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP From: Maxime Ripard The BCM20702A1 chip is a single-chip Bluetooth 4.0 controller and transceiver. It is found in the AMPAK AP6210 WiFi+BT package. Signed-off-by: Maxime Ripard Signed-off-by: Chen-Yu Tsai --- drivers/bluetooth/btbcm.c | 6 ++++++ drivers/bluetooth/hci_bcm.c | 1 + 2 files changed, 7 insertions(+) diff --git a/drivers/bluetooth/btbcm.c b/drivers/bluetooth/btbcm.c index e3e4d929e74f..22d4b530da03 100644 --- a/drivers/bluetooth/btbcm.c +++ b/drivers/bluetooth/btbcm.c @@ -33,6 +33,7 @@ #define VERSION "0.1" #define BDADDR_BCM20702A0 (&(bdaddr_t) {{0x00, 0xa0, 0x02, 0x70, 0x20, 0x00}}) +#define BDADDR_BCM20702A1 (&(bdaddr_t) {{0x00, 0x00, 0xa0, 0x02, 0x70, 0x20}}) #define BDADDR_BCM4324B3 (&(bdaddr_t) {{0x00, 0x00, 0x00, 0xb3, 0x24, 0x43}}) #define BDADDR_BCM4330B1 (&(bdaddr_t) {{0x00, 0x00, 0x00, 0xb1, 0x30, 0x43}}) @@ -64,6 +65,9 @@ int btbcm_check_bdaddr(struct hci_dev *hdev) * The address 00:20:70:02:A0:00 indicates a BCM20702A0 controller * with no configured address. * + * The address 20:70:02:A0:00:00 indicates a BCM20702A1 controller + * with no configured address. + * * The address 43:24:B3:00:00:00 indicates a BCM4324B3 controller * with waiting for configuration state. * @@ -71,6 +75,7 @@ int btbcm_check_bdaddr(struct hci_dev *hdev) * with waiting for configuration state. */ if (!bacmp(&bda->bdaddr, BDADDR_BCM20702A0) || + !bacmp(&bda->bdaddr, BDADDR_BCM20702A1) || !bacmp(&bda->bdaddr, BDADDR_BCM4324B3) || !bacmp(&bda->bdaddr, BDADDR_BCM4330B1)) { bt_dev_info(hdev, "BCM: Using default device address (%pMR)", @@ -330,6 +335,7 @@ static const struct bcm_subver_table bcm_uart_subver_table[] = { { 0x2209, "BCM43430A1" }, /* 001.002.009 */ { 0x6119, "BCM4345C0" }, /* 003.001.025 */ { 0x230f, "BCM4356A2" }, /* 001.003.015 */ + { 0x220e, "BCM20702A1" }, /* 001.002.014 */ { } }; diff --git a/drivers/bluetooth/hci_bcm.c b/drivers/bluetooth/hci_bcm.c index bf5dee9b04d8..73b520622a24 100644 --- a/drivers/bluetooth/hci_bcm.c +++ b/drivers/bluetooth/hci_bcm.c @@ -1396,6 +1396,7 @@ static void bcm_serdev_remove(struct serdev_device *serdev) #ifdef CONFIG_OF static const struct of_device_id bcm_bluetooth_of_match[] = { + { .compatible = "brcm,bcm20702a1" }, { .compatible = "brcm,bcm43438-bt" }, { }, };