From patchwork Mon Mar 13 14:40:25 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neeraj Sanjay Kale X-Patchwork-Id: 13172604 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id D828FC61DA4 for ; Mon, 13 Mar 2023 14:41:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231301AbjCMOlM (ORCPT ); Mon, 13 Mar 2023 10:41:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60872 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230515AbjCMOlL (ORCPT ); Mon, 13 Mar 2023 10:41:11 -0400 Received: from EUR05-AM6-obe.outbound.protection.outlook.com (mail-am6eur05on2045.outbound.protection.outlook.com [40.107.22.45]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7EFA548E35; Mon, 13 Mar 2023 07:41:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=AM+GXO+n+h18sEnoNdLSDjfkWcpyxY0qFxuVBLyAqPyKR3bA3a8WxFjYz8IqdCkbXhT3q84rNgGjU/gnu/SJufH9JWgt7FW3zUuoLcKLJDTe5+eg3xkxcrvRSs+fcxUM+KqYYSgj9sVkX9k1CNekvTuU1KOxtYC6kn4qqGdqTncM73o76cFszywddz9ciYjqh5LjP5A218zVGy2w65m/obKSbtzYlLzFAW3Zv6lxRhBA+wdaN7N8Sy3m2z7YzRNErWfDf8IWfYqWeLK5JdO8ESFvi3r54u4AodnuJpZMQXFQI8JbZPmYE124zmZIoPZr1MGsJD4dcsWipsNLlzURPw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=aMROdIwdrwhNN+iwm41m9w8HKuedgaA1/YxzkYHFOtA=; b=EZlyH2NFcaZZcpAdv0sjs47on6OpxQh/RiquTiMH4P9LbSY0tJlaoEX/okyTcVhUTZb/SNYHwklL2vWDpo0bcJUGRLO2HE/3jY9M35Dte5o+NBgpE0wzpsjt+6hjrvmVvm3DHBaeKUJ7GEomXo29awznBiN51IUPOOxbwZHQa64TiqCdY9XDnCnfI4QVmqAuoiTTlwB0EAjJfsVr8cfDMY6CZwt8AcRQ+05IHD9l1W3ukzfgVstgPeChog7wbQ5j/jC31GuNYMmr79SbPYVLRUFCNnqXLdHZMb1lGd74LpPj+TPV6UNEiIfltx6Wv5v/6Y8G57cw4HLvlMByhYI+Gg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=aMROdIwdrwhNN+iwm41m9w8HKuedgaA1/YxzkYHFOtA=; b=Z4LzziEXzjhKydPtZettzPAImcW6yxXJWDXD5yxMz1e9dedKOvVn2QlSrgB3OkUus0bUq19E5d2K7Rhav0lqtKLGe3pPYrxy9BgSg2/wXaoQYFZK6Fsn6ebxQahtGaXVB7DUgpnb9dAIRK8TnLx4hrTuXys4Q7sxJUw4wrqHdn0= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from AM9PR04MB8603.eurprd04.prod.outlook.com (2603:10a6:20b:43a::10) by DB9PR04MB8203.eurprd04.prod.outlook.com (2603:10a6:10:242::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6178.24; Mon, 13 Mar 2023 14:41:02 +0000 Received: from AM9PR04MB8603.eurprd04.prod.outlook.com ([fe80::45d2:ce51:a1c4:8762]) by AM9PR04MB8603.eurprd04.prod.outlook.com ([fe80::45d2:ce51:a1c4:8762%5]) with mapi id 15.20.6178.024; Mon, 13 Mar 2023 14:41:02 +0000 From: Neeraj Sanjay Kale To: davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, marcel@holtmann.org, johan.hedberg@gmail.com, luiz.dentz@gmail.com, gregkh@linuxfoundation.org, jirislaby@kernel.org, alok.a.tiwari@oracle.com, hdanton@sina.com, ilpo.jarvinen@linux.intel.com, leon@kernel.org, simon.horman@corigine.com Cc: netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-bluetooth@vger.kernel.org, linux-serial@vger.kernel.org, amitkumar.karwar@nxp.com, rohit.fule@nxp.com, sherry.sun@nxp.com, neeraj.sanjaykale@nxp.com Subject: [PATCH v10 0/3] Add support for NXP bluetooth chipsets Date: Mon, 13 Mar 2023 20:10:25 +0530 Message-Id: <20230313144028.3156825-1-neeraj.sanjaykale@nxp.com> X-Mailer: git-send-email 2.34.1 X-ClientProxiedBy: SG2PR02CA0115.apcprd02.prod.outlook.com (2603:1096:4:92::31) To AM9PR04MB8603.eurprd04.prod.outlook.com (2603:10a6:20b:43a::10) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AM9PR04MB8603:EE_|DB9PR04MB8203:EE_ X-MS-Office365-Filtering-Correlation-Id: 574a1458-ddac-49ad-ba69-08db23d0f7c9 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: x8zlDJNXVq4OdBZMfo7OOTNTdDmnDv2vAOylij+Q46pduorsyc/27GY6jkVfz46PLzHsLlgntMt7EedFGoyU7WKz2BAaEQdJdY1oi3kPMBX1eijgoJnlhE+ydMPJVxvvdx8JqSLPcE5DBD48B0FXdBihLugrdr9CMRzh2ZJXhY5L14+PaOI8jZNj5JMmJT3cpxm8bkPkWVnRsOIX9v7uhbnt7bvavCsijed2rnMMMca0I6iLHE9Rbndl/+gjU1+8JkTpcWIW3BhH/iyGUeiR4bFyIv8QY2kn5hYhwoLBvniantKIEMyWncVStRIYn+Oq2oYg8gSAqd/cBpKQJAJ92diRlZ9C6c4uQlJTryrZwj2mAO8yPo57o5mNCI1hv8E0NFxzVun7e7IVVsrD8NswQiTBsPklNH8ere47BqvVDdETSuDmiPOeqVRYiauEIkRyGgS2kALQCVTzfKHfk1MLMmxd99uUe7bEUhWb3snknPVesrc5OtCS3FzYmEhS9tBVG21y3pzdaMS8zTTnWoJvBB2hrsvynpMPSlypAhuWpfJpbzI4t8VaLV0GmQNBhoWpimiSF6sBitwypXFmj1U8cop/DvYdM7cUijZVJ+8+/MNwwK95oKfkmWXvNm8Mk4rC+enK32ewLFygZmOY23Ad1xUZoSAYIx9j+2UlMNXxyi9dJQUDos+vIiWsAVsmtZRBRSp5UEmMBQ4GvPceM0D8dIZ/ZxNCJd0jeRlXfQJtNCc= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:AM9PR04MB8603.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230025)(4636009)(136003)(396003)(376002)(346002)(39860400002)(366004)(451199018)(38100700002)(38350700002)(921005)(36756003)(86362001)(2906002)(8936002)(7416002)(5660300002)(66556008)(4326008)(41300700001)(66946007)(8676002)(66476007)(2616005)(83380400001)(186003)(26005)(316002)(6506007)(1076003)(6666004)(6512007)(52116002)(478600001)(6486002);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-Chun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f-8?q?f1jzGHA2PPAoTfPfsvOKFtlUc8zyoH+YtyTBN9qquYdt8eIEATXqeOcTByvhBI4P8?= =?utf-8?q?fwhSzpr6rsfKUBLAuDmPg2+RgDoboSeVMHbJInRkNhCf7OHit1VevfPtODSrfNMNA?= =?utf-8?q?FluDhncTv35sMhSe/SrI/1Zs9e0LdT7I7C80vGgXKY48RgPQ/2DRoNe+02ku+N7BN?= =?utf-8?q?p2O3UmjMUFMTbPU3Aku3Cg+fEUQCES/96gLt+EH1EJjo5DXqU/CvM+Ts3UC+Zp9pI?= =?utf-8?q?3/TWEQw3PyxvEoB6JnLyS23QMMMlOVaWsZGXiFinNe2mMF4ZiWevOEe6TVmRJcoxs?= =?utf-8?q?iY6PPdeftKBiiUFkFV6dn1TYcUDLMCd+tSA/6O2vtH1I0LRcKDKX5J2+4bZ9UuOgT?= =?utf-8?q?WW2DwhnbU3O/E6bb1yF3N4FBmtbmHMJEU3SHwL32Fl47n0ImdkQpMPbMG+P76+bdM?= =?utf-8?q?cT3q05MuICgMvCcRBP0zdt2igh8f5hFu9L3/F3OSSfwzlfWqBDLAYMX7zfrE5xkRn?= =?utf-8?q?+qQnq0YJNjSD2CWGpwGHJSc3dtuy1FxZfwPThbb0imVqEVzyfVBafHclIPzUZJ4Hn?= =?utf-8?q?WVHXN2IN2+xphhtEfCyhNdolAzZpGzClQd9cwZNmQWIZjLbY2xyanLajjEBbx0Cyu?= =?utf-8?q?RbmSs4U5Vp8W1yF5H3BUPZm+DWhiI2WigR8F5RP5ddZFjsw5HklsWZYXmSVOZryTH?= =?utf-8?q?CFhgisjd6XY8FreudolJBi9thYweEUM8Yw=3D=3D?= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 574a1458-ddac-49ad-ba69-08db23d0f7c9 X-MS-Exchange-CrossTenant-AuthSource: AM9PR04MB8603.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Mar 2023 14:41:02.2606 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: eQz3C2gshDJw6O0aDszBS2SjjTul0/Ooa0MIKmEzMWJbB+YAGpkb3vAfKrVgO8wzgX321y3jzpYzKF0ZZDcuuLPX1i/3t177H7yrJnyLnRg= X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB9PR04MB8203 Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org This patch adds a driver for NXP bluetooth chipsets. The driver is based on H4 protocol, and uses serdev APIs. It supports host to chip power save feature, which is signalled by the host by asserting break over UART TX lines, to put the chip into sleep state. To support this feature, break_ctl has also been added to serdev-tty along with a new serdev API serdev_device_break_ctl(). This driver is capable of downloading firmware into the chip over UART. The document specifying device tree bindings for this driver is also included in this patch series. Neeraj Sanjay Kale (3): serdev: Add method to assert break signal over tty UART port dt-bindings: net: bluetooth: Add NXP bluetooth support Bluetooth: NXP: Add protocol support for NXP Bluetooth chipsets .../net/bluetooth/nxp,88w8987-bt.yaml | 46 + MAINTAINERS | 7 + drivers/bluetooth/Kconfig | 12 + drivers/bluetooth/Makefile | 1 + drivers/bluetooth/btnxpuart.c | 1293 +++++++++++++++++ drivers/tty/serdev/core.c | 17 +- drivers/tty/serdev/serdev-ttyport.c | 16 +- include/linux/serdev.h | 6 + 8 files changed, 1393 insertions(+), 5 deletions(-) create mode 100644 Documentation/devicetree/bindings/net/bluetooth/nxp,88w8987-bt.yaml create mode 100644 drivers/bluetooth/btnxpuart.c