From patchwork Tue Aug 3 19:29:01 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Andy Shevchenko X-Patchwork-Id: 491788 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7F793C4320E for ; Tue, 3 Aug 2021 19:28:58 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 6129E60EC0 for ; Tue, 3 Aug 2021 19:28:58 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239905AbhHCT3I (ORCPT ); Tue, 3 Aug 2021 15:29:08 -0400 Received: from mga17.intel.com ([192.55.52.151]:13482 "EHLO mga17.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230376AbhHCT3I (ORCPT ); Tue, 3 Aug 2021 15:29:08 -0400 X-IronPort-AV: E=McAfee;i="6200,9189,10065"; a="194045227" X-IronPort-AV: E=Sophos;i="5.84,292,1620716400"; d="scan'208";a="194045227" Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Aug 2021 12:28:57 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.84,292,1620716400"; d="scan'208";a="585103661" Received: from black.fi.intel.com ([10.237.72.28]) by fmsmga001.fm.intel.com with ESMTP; 03 Aug 2021 12:28:53 -0700 Received: by black.fi.intel.com (Postfix, from userid 1003) id 32976169; Tue, 3 Aug 2021 22:29:22 +0300 (EEST) From: Andy Shevchenko To: Andy Shevchenko , Hans de Goede , Maximilian Luz , Lee Jones , Greg Kroah-Hartman , linux-bluetooth@vger.kernel.org, linux-kernel@vger.kernel.org, platform-driver-x86@vger.kernel.org, linux-serial@vger.kernel.org Cc: Marcel Holtmann , Johan Hedberg , Luiz Augusto von Dentz , Mark Gross , Rob Herring , Jiri Slaby Subject: [PATCH v1 1/5] serdev: Split and export serdev_acpi_get_uart_resource() Date: Tue, 3 Aug 2021 22:29:01 +0300 Message-Id: <20210803192905.72246-1-andriy.shevchenko@linux.intel.com> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org The same as for I²C Serial Bus resource split and export serdev_acpi_get_uart_resource(). We have already 3 users one of which is converted here. Rationale of this is to consolidate parsing UART Serial Bus resource in one place as it's done, e.g., for I²C Serial Bus. Signed-off-by: Andy Shevchenko --- drivers/tty/serdev/core.c | 36 +++++++++++++++++++++++++++++------- include/linux/serdev.h | 14 ++++++++++++++ 2 files changed, 43 insertions(+), 7 deletions(-) diff --git a/drivers/tty/serdev/core.c b/drivers/tty/serdev/core.c index 92498961fd92..436e3d1ba92c 100644 --- a/drivers/tty/serdev/core.c +++ b/drivers/tty/serdev/core.c @@ -562,23 +562,45 @@ struct acpi_serdev_lookup { int index; }; +/** + * serdev_acpi_get_uart_resource - Gets UARTSerialBus resource if type matches + * @ares: ACPI resource + * @uart: Pointer to UARTSerialBus resource will be returned here + * + * Checks if the given ACPI resource is of type UARTSerialBus. + * In this case, returns a pointer to it to the caller. + * + * Returns true if resource type is of UARTSerialBus, otherwise false. + */ +bool serdev_acpi_get_uart_resource(struct acpi_resource *ares, + struct acpi_resource_uart_serialbus **uart) +{ + struct acpi_resource_uart_serialbus *sb; + + if (ares->type != ACPI_RESOURCE_TYPE_SERIAL_BUS) + return false; + + sb = &ares->data.uart_serial_bus; + if (sb->type != ACPI_RESOURCE_SERIAL_TYPE_UART) + return false; + + *uart = sb; + return true; +} +EXPORT_SYMBOL_GPL(serdev_acpi_get_uart_resource); + static int acpi_serdev_parse_resource(struct acpi_resource *ares, void *data) { struct acpi_serdev_lookup *lookup = data; struct acpi_resource_uart_serialbus *sb; acpi_status status; - if (ares->type != ACPI_RESOURCE_TYPE_SERIAL_BUS) - return 1; - - if (ares->data.common_serial_bus.type != ACPI_RESOURCE_SERIAL_TYPE_UART) + if (!serdev_acpi_get_uart_resource(ares, &sb)) return 1; if (lookup->index != -1 && lookup->n++ != lookup->index) return 1; - sb = &ares->data.uart_serial_bus; - status = acpi_get_handle(lookup->device_handle, sb->resource_source.string_ptr, &lookup->controller_handle); @@ -586,7 +608,7 @@ static int acpi_serdev_parse_resource(struct acpi_resource *ares, void *data) return 1; /* - * NOTE: Ideally, we would also want to retreive other properties here, + * NOTE: Ideally, we would also want to retrieve other properties here, * once setting them before opening the device is supported by serdev. */ diff --git a/include/linux/serdev.h b/include/linux/serdev.h index 9f14f9c12ec4..3368c261ab62 100644 --- a/include/linux/serdev.h +++ b/include/linux/serdev.h @@ -327,4 +327,18 @@ static inline int serdev_tty_port_unregister(struct tty_port *port) } #endif /* CONFIG_SERIAL_DEV_CTRL_TTYPORT */ +struct acpi_resource; +struct acpi_resource_uart_serialbus; + +#ifdef CONFIG_ACPI +bool serdev_acpi_get_uart_resource(struct acpi_resource *ares, + struct acpi_resource_uart_serialbus **uart); +#else +static inline bool serdev_acpi_get_uart_resource(struct acpi_resource *ares, + struct acpi_resource_uart_serialbus **uart) +{ + return false; +} +#endif /* CONFIG_ACPI */ + #endif /*_LINUX_SERDEV_H */ From patchwork Tue Aug 3 19:29:02 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andy Shevchenko X-Patchwork-Id: 491787 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 77C82C4338F for ; Tue, 3 Aug 2021 19:29:13 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 5BBD661103 for ; Tue, 3 Aug 2021 19:29:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239932AbhHCT3N (ORCPT ); Tue, 3 Aug 2021 15:29:13 -0400 Received: from mga12.intel.com ([192.55.52.136]:8486 "EHLO mga12.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239917AbhHCT3M (ORCPT ); Tue, 3 Aug 2021 15:29:12 -0400 X-IronPort-AV: E=McAfee;i="6200,9189,10065"; a="193356374" X-IronPort-AV: E=Sophos;i="5.84,292,1620716400"; d="scan'208";a="193356374" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Aug 2021 12:28:58 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.84,292,1620716400"; d="scan'208";a="670622357" Received: from black.fi.intel.com ([10.237.72.28]) by fmsmga005.fm.intel.com with ESMTP; 03 Aug 2021 12:28:54 -0700 Received: by black.fi.intel.com (Postfix, from userid 1003) id 429751C8; Tue, 3 Aug 2021 22:29:24 +0300 (EEST) From: Andy Shevchenko To: Andy Shevchenko , Hans de Goede , Maximilian Luz , Lee Jones , Greg Kroah-Hartman , linux-bluetooth@vger.kernel.org, linux-kernel@vger.kernel.org, platform-driver-x86@vger.kernel.org, linux-serial@vger.kernel.org Cc: Marcel Holtmann , Johan Hedberg , Luiz Augusto von Dentz , Mark Gross , Rob Herring , Jiri Slaby Subject: [PATCH v1 2/5] platform/surface: aggregator: Use serdev_acpi_get_uart_resource() helper Date: Tue, 3 Aug 2021 22:29:02 +0300 Message-Id: <20210803192905.72246-2-andriy.shevchenko@linux.intel.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210803192905.72246-1-andriy.shevchenko@linux.intel.com> References: <20210803192905.72246-1-andriy.shevchenko@linux.intel.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org serdev provides a generic helper to get UART Serial Bus resources. Use it instead of open coded variant. Signed-off-by: Andy Shevchenko --- drivers/platform/surface/aggregator/core.c | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/drivers/platform/surface/aggregator/core.c b/drivers/platform/surface/aggregator/core.c index 279d9df19c01..c61bbeeec2df 100644 --- a/drivers/platform/surface/aggregator/core.c +++ b/drivers/platform/surface/aggregator/core.c @@ -301,20 +301,13 @@ static acpi_status ssam_serdev_setup_via_acpi_crs(struct acpi_resource *rsc, void *ctx) { struct serdev_device *serdev = ctx; - struct acpi_resource_common_serialbus *serial; struct acpi_resource_uart_serialbus *uart; bool flow_control; int status = 0; - if (rsc->type != ACPI_RESOURCE_TYPE_SERIAL_BUS) + if (!serdev_acpi_get_uart_resource(rsc, &uart)) return AE_OK; - serial = &rsc->data.common_serial_bus; - if (serial->type != ACPI_RESOURCE_SERIAL_TYPE_UART) - return AE_OK; - - uart = &rsc->data.uart_serial_bus; - /* Set up serdev device. */ serdev_device_set_baudrate(serdev, uart->default_baud_rate); From patchwork Tue Aug 3 19:29:03 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andy Shevchenko X-Patchwork-Id: 491040 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 57B67C4320A for ; Tue, 3 Aug 2021 19:29:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 3ECC261029 for ; Tue, 3 Aug 2021 19:29:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239921AbhHCT3M (ORCPT ); Tue, 3 Aug 2021 15:29:12 -0400 Received: from mga12.intel.com ([192.55.52.136]:8486 "EHLO mga12.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231978AbhHCT3L (ORCPT ); Tue, 3 Aug 2021 15:29:11 -0400 X-IronPort-AV: E=McAfee;i="6200,9189,10065"; a="193356375" X-IronPort-AV: E=Sophos;i="5.84,292,1620716400"; d="scan'208";a="193356375" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Aug 2021 12:28:59 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.84,292,1620716400"; d="scan'208";a="670622359" Received: from black.fi.intel.com ([10.237.72.28]) by fmsmga005.fm.intel.com with ESMTP; 03 Aug 2021 12:28:55 -0700 Received: by black.fi.intel.com (Postfix, from userid 1003) id 05ECE1CB; Tue, 3 Aug 2021 22:29:24 +0300 (EEST) From: Andy Shevchenko To: Andy Shevchenko , Hans de Goede , Maximilian Luz , Lee Jones , Greg Kroah-Hartman , linux-bluetooth@vger.kernel.org, linux-kernel@vger.kernel.org, platform-driver-x86@vger.kernel.org, linux-serial@vger.kernel.org Cc: Marcel Holtmann , Johan Hedberg , Luiz Augusto von Dentz , Mark Gross , Rob Herring , Jiri Slaby Subject: [PATCH v1 3/5] Bluetooth: hci_bcm: Use serdev_acpi_get_uart_resource() helper Date: Tue, 3 Aug 2021 22:29:03 +0300 Message-Id: <20210803192905.72246-3-andriy.shevchenko@linux.intel.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210803192905.72246-1-andriy.shevchenko@linux.intel.com> References: <20210803192905.72246-1-andriy.shevchenko@linux.intel.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org serdev provides a generic helper to get UART Serial Bus resources. Use it instead of open coded variant. Signed-off-by: Andy Shevchenko --- drivers/bluetooth/hci_bcm.c | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/drivers/bluetooth/hci_bcm.c b/drivers/bluetooth/hci_bcm.c index 3cd57fc56ade..16f854ac19b6 100644 --- a/drivers/bluetooth/hci_bcm.c +++ b/drivers/bluetooth/hci_bcm.c @@ -899,9 +899,9 @@ static const struct acpi_gpio_mapping acpi_bcm_int_first_gpios[] = { static int bcm_resource(struct acpi_resource *ares, void *data) { struct bcm_device *dev = data; + struct acpi_resource_uart_serialbus *uart; struct acpi_resource_extended_irq *irq; struct acpi_resource_gpio *gpio; - struct acpi_resource_uart_serialbus *sb; switch (ares->type) { case ACPI_RESOURCE_TYPE_EXTENDED_IRQ: @@ -920,18 +920,15 @@ static int bcm_resource(struct acpi_resource *ares, void *data) dev->gpio_count++; break; - case ACPI_RESOURCE_TYPE_SERIAL_BUS: - sb = &ares->data.uart_serial_bus; - if (sb->type == ACPI_RESOURCE_SERIAL_TYPE_UART) { - dev->init_speed = sb->default_baud_rate; - dev->oper_speed = 4000000; - } - break; - default: break; } + if (serdev_acpi_get_uart_resource(ares, &uart)) { + dev->init_speed = uart->default_baud_rate; + dev->oper_speed = 4000000; + } + return 0; } From patchwork Tue Aug 3 19:29:04 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andy Shevchenko X-Patchwork-Id: 491039 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 990C8C4320A for ; Tue, 3 Aug 2021 19:29:13 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 7C14D610FC for ; Tue, 3 Aug 2021 19:29:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239946AbhHCT3O (ORCPT ); Tue, 3 Aug 2021 15:29:14 -0400 Received: from mga09.intel.com ([134.134.136.24]:32499 "EHLO mga09.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239930AbhHCT3N (ORCPT ); Tue, 3 Aug 2021 15:29:13 -0400 X-IronPort-AV: E=McAfee;i="6200,9189,10065"; a="213747206" X-IronPort-AV: E=Sophos;i="5.84,292,1620716400"; d="scan'208";a="213747206" Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Aug 2021 12:29:00 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.84,292,1620716400"; d="scan'208";a="511459759" Received: from black.fi.intel.com ([10.237.72.28]) by FMSMGA003.fm.intel.com with ESMTP; 03 Aug 2021 12:28:56 -0700 Received: by black.fi.intel.com (Postfix, from userid 1003) id A5544269; Tue, 3 Aug 2021 22:29:25 +0300 (EEST) From: Andy Shevchenko To: Andy Shevchenko , Hans de Goede , Maximilian Luz , Lee Jones , Greg Kroah-Hartman , linux-bluetooth@vger.kernel.org, linux-kernel@vger.kernel.org, platform-driver-x86@vger.kernel.org, linux-serial@vger.kernel.org Cc: Marcel Holtmann , Johan Hedberg , Luiz Augusto von Dentz , Mark Gross , Rob Herring , Jiri Slaby Subject: [PATCH v1 4/5] Bluetooth: hci_bcm: Use acpi_gpio_get_*_resource() helpers Date: Tue, 3 Aug 2021 22:29:04 +0300 Message-Id: <20210803192905.72246-4-andriy.shevchenko@linux.intel.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210803192905.72246-1-andriy.shevchenko@linux.intel.com> References: <20210803192905.72246-1-andriy.shevchenko@linux.intel.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org ACPI provides generic helpers to get GPIO interrupt and IO resources. Use it instead of open coded variant. Signed-off-by: Andy Shevchenko --- drivers/bluetooth/hci_bcm.c | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/drivers/bluetooth/hci_bcm.c b/drivers/bluetooth/hci_bcm.c index 16f854ac19b6..ed99fcde2523 100644 --- a/drivers/bluetooth/hci_bcm.c +++ b/drivers/bluetooth/hci_bcm.c @@ -911,15 +911,6 @@ static int bcm_resource(struct acpi_resource *ares, void *data) dev->irq_active_low = true; break; - case ACPI_RESOURCE_TYPE_GPIO: - gpio = &ares->data.gpio; - if (gpio->connection_type == ACPI_RESOURCE_GPIO_TYPE_INT) { - dev->gpio_int_idx = dev->gpio_count; - dev->irq_active_low = gpio->polarity == ACPI_ACTIVE_LOW; - } - dev->gpio_count++; - break; - default: break; } @@ -927,6 +918,12 @@ static int bcm_resource(struct acpi_resource *ares, void *data) if (serdev_acpi_get_uart_resource(ares, &uart)) { dev->init_speed = uart->default_baud_rate; dev->oper_speed = 4000000; + } else if (acpi_gpio_get_irq_resource(ares, &gpio)) { + dev->gpio_int_idx = dev->gpio_count; + dev->irq_active_low = gpio->polarity == ACPI_ACTIVE_LOW; + dev->gpio_count++; + } else if (acpi_gpio_get_io_resource(ares, &gpio)) { + dev->gpio_count++; } return 0; From patchwork Tue Aug 3 19:29:05 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andy Shevchenko X-Patchwork-Id: 491786 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id B1020C19F34 for ; Tue, 3 Aug 2021 19:29:14 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 98C8560F93 for ; Tue, 3 Aug 2021 19:29:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240035AbhHCT3Y (ORCPT ); Tue, 3 Aug 2021 15:29:24 -0400 Received: from mga09.intel.com ([134.134.136.24]:32499 "EHLO mga09.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239936AbhHCT3N (ORCPT ); Tue, 3 Aug 2021 15:29:13 -0400 X-IronPort-AV: E=McAfee;i="6200,9189,10065"; a="213747208" X-IronPort-AV: E=Sophos;i="5.84,292,1620716400"; d="scan'208";a="213747208" Received: from orsmga003.jf.intel.com ([10.7.209.27]) by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Aug 2021 12:29:01 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.84,292,1620716400"; d="scan'208";a="419770650" Received: from black.fi.intel.com ([10.237.72.28]) by orsmga003.jf.intel.com with ESMTP; 03 Aug 2021 12:28:56 -0700 Received: by black.fi.intel.com (Postfix, from userid 1003) id 433DE403; Tue, 3 Aug 2021 22:29:26 +0300 (EEST) From: Andy Shevchenko To: Andy Shevchenko , Hans de Goede , Maximilian Luz , Lee Jones , Greg Kroah-Hartman , linux-bluetooth@vger.kernel.org, linux-kernel@vger.kernel.org, platform-driver-x86@vger.kernel.org, linux-serial@vger.kernel.org Cc: Marcel Holtmann , Johan Hedberg , Luiz Augusto von Dentz , Mark Gross , Rob Herring , Jiri Slaby Subject: [PATCH v1 5/5] Bluetooth: hci_bcm: Fix kernel doc comments Date: Tue, 3 Aug 2021 22:29:05 +0300 Message-Id: <20210803192905.72246-5-andriy.shevchenko@linux.intel.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210803192905.72246-1-andriy.shevchenko@linux.intel.com> References: <20210803192905.72246-1-andriy.shevchenko@linux.intel.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org Kernel doc validator complains about few missed parameter descriptions. Fill the gap by describing them. Signed-off-by: Andy Shevchenko --- drivers/bluetooth/hci_bcm.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/drivers/bluetooth/hci_bcm.c b/drivers/bluetooth/hci_bcm.c index ed99fcde2523..fd0acadb9102 100644 --- a/drivers/bluetooth/hci_bcm.c +++ b/drivers/bluetooth/hci_bcm.c @@ -51,6 +51,7 @@ /** * struct bcm_device_data - device specific data * @no_early_set_baudrate: Disallow set baudrate before driver setup() + * @drive_rts_on_open: drive RTS signal on ->open() when platform requires it */ struct bcm_device_data { bool no_early_set_baudrate; @@ -77,6 +78,8 @@ struct bcm_device_data { * @btlp: Apple ACPI method to toggle BT_WAKE pin ("Bluetooth Low Power") * @btpu: Apple ACPI method to drive BT_REG_ON pin high ("Bluetooth Power Up") * @btpd: Apple ACPI method to drive BT_REG_ON pin low ("Bluetooth Power Down") + * @gpio_count: internal counter for GPIO resources associated with ACPI device + * @gpio_int_idx: index in _CRS for GpioInt() resource * @txco_clk: external reference frequency clock used by Bluetooth device * @lpo_clk: external LPO clock used by Bluetooth device * @supplies: VBAT and VDDIO supplies used by Bluetooth device @@ -88,10 +91,13 @@ struct bcm_device_data { * set to 0 if @init_speed is already the preferred baudrate * @irq: interrupt triggered by HOST_WAKE_BT pin * @irq_active_low: whether @irq is active low + * @irq_acquired: flag to show if IRQ handler has been assigned * @hu: pointer to HCI UART controller struct, * used to disable flow control during runtime suspend and system sleep * @is_suspended: whether flow control is currently disabled * @no_early_set_baudrate: don't set_baudrate before setup() + * @drive_rts_on_open: drive RTS signal on ->open() when platform requires it + * @pcm_int_params: keep the initial PCM configuration */ struct bcm_device { /* Must be the first member, hci_serdev.c expects this. */