All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFC PATCH 0/2] Add serdev support for hci h4
@ 2022-11-08  5:55 Dominique Martinet
  2022-11-08  5:55 ` [RFC PATCH 1/2] dt-bindings: net: h4-bluetooth: add new bindings for hci_h4 Dominique Martinet
  2022-11-08  5:55 ` [RFC PATCH 2/2] bluetooth/hci_h4: add serdev support Dominique Martinet
  0 siblings, 2 replies; 22+ messages in thread
From: Dominique Martinet @ 2022-11-08  5:55 UTC (permalink / raw)
  To: Marcel Holtmann, Rob Herring, Krzysztof Kozlowski,
	Luiz Augusto von Dentz, Johan Hedberg
  Cc: netdev, linux-kernel, devicetree, linux-bluetooth, Paolo Abeni,
	Jakub Kicinski, Eric Dumazet, David S . Miller, mizo,
	Dominique Martinet

Hello,


A couple of questions with this patch (hence status as RFC), first for
the dt bindings part:
 - I have no idea what to do with the compatible name.
I am not affiliated with nxp (except as a customer), so I'm not entierly
comfortable just adding a new property in the nxp, namespace.
The h4 protocol is very generic and I'd think a name such as
'hci-h4,generic' make more sense as other boards would be able to
benefit from it without extra modifications... But that doesn't seem to
be how things are done with dt bindings, so can I just add an arbitrary
name?
 - I've set Marcel (who maintains the hci_h4 driver) as maintainer of
he dt-bindings unilaterally without asking him for lack of a better
idea: Marcel, are you ok with that? My first idea was making it myself
but I don't really feel competent for this.

Second for the driver itself:
 - I've just monkeyed the simplest serdev support I could come up with
and it appears to work (I'm trying to replace the following command:
btattach -B /dev/ttymxc0 -S 3000000 -P h4); perhaps there are other
settings you'd want?
I've also tried suspend and with no handler it appears to work with
an idle controller, but I'd assume we might want some pm handling at
some point if possible... Right now this is no worse than btattach,
but unlike btattach it's not easy to restart (unbind/bind the driver?)
so that might come up sooner or later; will be happy to look then.


I confirmed this works with the following dts fragment over
imx8mp.dtsi, on a board with the AW-XM458 NXP wireless+BT module.

--8<------
&uart1 {
        pinctrl-names = "default";
        pinctrl-0 = <&pinctrl_uart1>;
        assigned-clocks = <&clk IMX8MP_CLK_UART1>;
        assigned-clock-parents = <&clk IMX8MP_SYS_PLL1_80M>;
        status = "okay";
        fsl,dte-mode = <1>;
        fsl,uart-has-rtscts;

        bluetooth {
                compatible = "nxp,aw-xm458-bt";
                max-speed = <3000000>;
        };
};

&iomuxc {
        pinctrl_uart1: uart1grp {
                fsl,pins = <
                        MX8MP_IOMUXC_UART1_RXD__UART1_DTE_TX    0x140
                        MX8MP_IOMUXC_UART1_TXD__UART1_DTE_RX    0x140
                        MX8MP_IOMUXC_UART3_RXD__UART1_DTE_RTS   0x140
                        MX8MP_IOMUXC_UART3_TXD__UART1_DTE_CTS   0x140
                >;
        };
}
--8<------


Dominique Martinet (2):
  dt-bindings: net: h4-bluetooth: add new bindings for hci_h4
  bluetooth/hci_h4: add serdev support

 .../devicetree/bindings/net/h4-bluetooth.yaml | 49 ++++++++++++++
 drivers/bluetooth/Kconfig                     |  1 +
 drivers/bluetooth/hci_h4.c                    | 64 +++++++++++++++++++
 3 files changed, 114 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/net/h4-bluetooth.yaml

-- 
2.35.1



^ permalink raw reply	[flat|nested] 22+ messages in thread

end of thread, other threads:[~2022-11-18  9:31 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-08  5:55 [RFC PATCH 0/2] Add serdev support for hci h4 Dominique Martinet
2022-11-08  5:55 ` [RFC PATCH 1/2] dt-bindings: net: h4-bluetooth: add new bindings for hci_h4 Dominique Martinet
2022-11-08  7:15   ` Add serdev support for hci h4 bluez.test.bot
2022-11-08 11:37   ` [RFC PATCH 1/2] dt-bindings: net: h4-bluetooth: add new bindings for hci_h4 Krzysztof Kozlowski
2022-11-08 23:54     ` Dominique Martinet
2022-11-09  7:29       ` Dominique Martinet
2022-11-09 22:00         ` Rob Herring
2022-11-10  7:37           ` Dominique Martinet
2022-11-10 16:27             ` Rob Herring
2022-11-08 12:54   ` Rob Herring
2022-11-08 13:59   ` Rob Herring
2022-11-18  3:50   ` Add serdev support for hci h4 bluez.test.bot
2022-11-18  4:38   ` bluez.test.bot
2022-11-18  5:34   ` bluez.test.bot
2022-11-18  6:34   ` bluez.test.bot
2022-11-18  7:33   ` bluez.test.bot
2022-11-18  8:37   ` bluez.test.bot
2022-11-18  9:31   ` bluez.test.bot
2022-11-08  5:55 ` [RFC PATCH 2/2] bluetooth/hci_h4: add serdev support Dominique Martinet
2022-11-08 20:38   ` Andrew Lunn
2022-11-08 20:58     ` Krzysztof Kozlowski
2022-11-09  9:17   ` kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.