kernel: import series to support Renesas Bluetooth HCI
[openwrt/staging/dangole.git] / target / linux / generic / pending-6.1 / 900-0004-Bluetooth-hci_renesas-Fix-issue-with-reset-pin-direc.patch
diff --git a/target/linux/generic/pending-6.1/900-0004-Bluetooth-hci_renesas-Fix-issue-with-reset-pin-direc.patch b/target/linux/generic/pending-6.1/900-0004-Bluetooth-hci_renesas-Fix-issue-with-reset-pin-direc.patch
new file mode 100644 (file)
index 0000000..8a7d7c1
--- /dev/null
@@ -0,0 +1,24 @@
+From 31defedfd6a8e0c0b3265f86a4d82e28358662d6 Mon Sep 17 00:00:00 2001
+From: Fabrizio Castro <fabrizio.castro.jz@renesas.com>
+Date: Mon, 15 Aug 2022 15:49:32 +0100
+Subject: [PATCH] Bluetooth: hci_renesas: Fix issue with reset pin direction
+
+Making the reset pin an input after resetting may not work
+if there is a pullup or a pulldown on the pin, therefore just
+keep the direction of the pin as output throughout.
+
+Signed-off-by: Fabrizio Castro <fabrizio.castro.jz@renesas.com>
+---
+ drivers/bluetooth/hci_renesas.c | 1 -
+ 1 file changed, 1 deletion(-)
+
+--- a/drivers/bluetooth/hci_renesas.c
++++ b/drivers/bluetooth/hci_renesas.c
+@@ -176,7 +176,6 @@ static void reset_device(struct gpio_des
+       }
+       gpiod_set_value_cansleep(gpio, 0);
+       usleep_range(5000, 10000);
+-      gpiod_direction_input(gpio);
+ }
+ static void renesas_reset(struct hci_uart *hu)