Re: [PATCH 2/3] usb: xhci: Add support for Google XHCI controller

Krzysztof Kozlowski
2024-02-19T12:21:57Z

On 19/02/2024 07:10, Puma Hsu wrote:
> In our SoC platform, we support allocating dedicated memory spaces
> other than system memory for XHCI, which also requires IOMMU mapping.
> The rest of driver probing and executing will use the generic
> xhci-plat driver.
>
> We support USB dual roles and switch roles by generic dwc3 driver,
> the dwc3 driver always probes xhci-plat driver now, so we introduce
> a device tree property to probe a XHCI glue driver.
>
> Sample:
> xhci_dma: xhci_dma@99C0000 {
> compatible = "shared-dma-pool";
> reg = <0x00000000 0x99C0000 0x00000000 0x40000>;
> no-map;
> };
>
> dwc3: dwc3@c400000 {
> compatible = "snps,dwc3";
> reg = <0 0x0c400000 0 0x10000>;
> xhci-glue = "xhci-hcd-goog";

NAK, that's not DWC3 hardware in such case.

...

> return -ENOMEM;
> diff --git a/drivers/usb/host/Kconfig b/drivers/usb/host/Kconfig
> index 4448d0ab06f0..1c1613c548d9 100644
> --- a/drivers/usb/host/Kconfig
> +++ b/drivers/usb/host/Kconfig
> @@ -61,6 +61,12 @@ config USB_XHCI_PLATFORM
>
> If unsure, say N.
>
> +config USB_XHCI_GOOG
> + tristate "xHCI support for Google Tensor SoCs"
> + help

Please always Cc Google Tensor SoC maintainers and Samsung SoC
maintainers on your contributions around Google Tensor SoC.

Anyway you just tried to push vendor code to upstream without aligning
it to usptream code style and to proper driver model. That's not good.
Please work with your colleagues in Google to explain how to upstream
vendor code. There were many, many trainings and presentations. One
coming from Dmitry will be in EOSS24 in two months.

Best regards,
Krzysztof