From patchwork Wed Nov 7 10:13:06 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: 10672097 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 B59F31751 for ; Wed, 7 Nov 2018 10:16:50 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9BF66284E9 for ; Wed, 7 Nov 2018 10:16:50 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8BF2928C93; Wed, 7 Nov 2018 10:16:50 +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 2F816284E9 for ; Wed, 7 Nov 2018 10:16:50 +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=H/3cxL+qOiMYqQVn9ZAXYbt7PeBwiRF6s0kHBnO9RQ0=; b=QCjm8s8EWEGov6 r7NFEc4DMegxrcPyT5GGrIyrTNm1MVVpwq87o1aDZr7EnOICRwlrbl7fpQG3BnJpc1zCghNvjBUE1 RnE5A/EzxdgwnzWZS5y74K8tIJ16LAgZYbm3GUEa3AuEJN39h+yXZsryjQ+nXrRJxan78uZwyBgRm bqTljcbeMYON33R1YF+FyH7Q39cSjMemr7B/ZgpodbQ5ddhBeKwwd5s4wx9EkowHc7ML/rar/3lNw sfM/prNdulFEPt1BdzQrs6mkEAsYYXIMcwBLZR0SIp4Eic4hK8omZMFtz/fQIYuZFmMBATL1nRcOc 4JeBonIbcPC6wGy4qgVA==; 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 1gKKtB-0007Sl-80; Wed, 07 Nov 2018 10:16:45 +0000 Received: from casper.infradead.org ([2001:8b0:10b:1236::1]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gKKqS-0003YW-KE for linux-arm-kernel@bombadil.infradead.org; Wed, 07 Nov 2018 10:13:56 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.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=ZyuhIAR5tXvYogE+IM1BdyhTGcCO5t58gltbbUIEqJ4=; b=K+6pAYkjrVamMmM3GG6B/UzVPX GrBJcnJJh2rHwta7EUWurv7Z1XUwsJjnCx3VgYr1YO5mSMJ7I48NBTJ3ov0ZxqfXC2rDgfKAHOJyU 9saLvGoDQdcaM1lLzKuTvKqRvA2CBdLv+M4SsWS12kgteoSzzafsQaFSLRP9McJXTp2Au+zn4L5Xs 8Zc2b8xK9kildMBjlpyrvU0cOshV/o7yqFTB+xiCeO7nnQ5Z+r/nPGfdmD0I69t9l8Cz5WYDhNGFW yHQgA1d3fU8TDmC6iXZQTon5Vme7c4UcAt+Q6knQg2QICDWfmgexf8DIKW9DeGj0o0rnr7DX606SK n3l2rUZQ==; Received: from mirror2.csie.ntu.edu.tw ([140.112.30.76] helo=wens.csie.org) by casper.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gKKqP-0003BX-4j for linux-arm-kernel@lists.infradead.org; Wed, 07 Nov 2018 10:13:55 +0000 Received: by wens.csie.org (Postfix, from userid 1000) id BBB605FDA6; 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 13/15] Bluetooth: btbcm: Add default address for BCM43430A0 Date: Wed, 7 Nov 2018 18:13:06 +0800 Message-Id: <20181107101308.7626-14-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_101353_556382_7786EE5D X-CRM114-Status: GOOD ( 14.04 ) 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, Chen-Yu Tsai , linux-kernel@vger.kernel.org, linux-bluetooth@vger.kernel.org, linux-sunxi@googlegroups.com, Loic Poulain , 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 The BCM43430A0 has the default MAC address 43:43:A0:12:1F:AC if none is given. This address was found when enabling Bluetooth on a bunch of boards with the AMPAK AP6210 module, all sharing the same address. It also contains the sequence 4343A0, which is suspicious as that is also the name the chip identifies itself as. Add this to the list of default MAC addresses and leave it to the user to configure a valid one. Signed-off-by: Chen-Yu Tsai --- drivers/bluetooth/btbcm.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/drivers/bluetooth/btbcm.c b/drivers/bluetooth/btbcm.c index 22d4b530da03..08e1f3dd4e03 100644 --- a/drivers/bluetooth/btbcm.c +++ b/drivers/bluetooth/btbcm.c @@ -34,6 +34,7 @@ #define BDADDR_BCM20702A0 (&(bdaddr_t) {{0x00, 0xa0, 0x02, 0x70, 0x20, 0x00}}) #define BDADDR_BCM20702A1 (&(bdaddr_t) {{0x00, 0x00, 0xa0, 0x02, 0x70, 0x20}}) +#define BDADDR_BCM43430A0 (&(bdaddr_t) {{0xac, 0x1f, 0x12, 0xa0, 0x43, 0x43}}) #define BDADDR_BCM4324B3 (&(bdaddr_t) {{0x00, 0x00, 0x00, 0xb3, 0x24, 0x43}}) #define BDADDR_BCM4330B1 (&(bdaddr_t) {{0x00, 0x00, 0x00, 0xb1, 0x30, 0x43}}) @@ -73,11 +74,15 @@ int btbcm_check_bdaddr(struct hci_dev *hdev) * * The address 43:30:B1:00:00:00 indicates a BCM4330B1 controller * with waiting for configuration state. + * + * The address 43:43:A0:12:1F:AC indicates a BCM43430A0 controller + * with no configured address. */ if (!bacmp(&bda->bdaddr, BDADDR_BCM20702A0) || !bacmp(&bda->bdaddr, BDADDR_BCM20702A1) || !bacmp(&bda->bdaddr, BDADDR_BCM4324B3) || - !bacmp(&bda->bdaddr, BDADDR_BCM4330B1)) { + !bacmp(&bda->bdaddr, BDADDR_BCM4330B1) || + !bacmp(&bda->bdaddr, BDADDR_BCM43430A0)) { bt_dev_info(hdev, "BCM: Using default device address (%pMR)", &bda->bdaddr); set_bit(HCI_QUIRK_INVALID_BDADDR, &hdev->quirks);