From: Philipp Zabel <p.zabel@pengutronix.de>
To: Sven Peter <sven@kernel.org>, Janne Grunau <j@jannau.net>,
Neal Gompa <neal@gompa.dev>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Thinh Nguyen <Thinh.Nguyen@synopsys.com>
Cc: asahi@lists.linux.dev, linux-arm-kernel@lists.infradead.org,
linux-usb@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH usb-next v2 5/5] usb: dwc3: Add Apple Silicon DWC3 glue layer driver
Date: Thu, 16 Oct 2025 12:44:49 +0200 [thread overview]
Message-ID: <47112ace39ea096242e68659d67a401e931abf3a.camel@pengutronix.de> (raw)
In-Reply-To: <20251015-b4-aplpe-dwc3-v2-5-cbd65a2d511a@kernel.org>
On Mi, 2025-10-15 at 15:40 +0000, Sven Peter wrote:
> The dwc3 controller present on Apple Silicon SoCs like the M1 requires
> a specific order of operations synchronized between its PHY and its
> Type-C controller. Specifically, the PHY first has to go through initial
> bringup (which requires knowledge of the lane mode and orientation)
> before dwc3 itself can be brought up and can then finalize the PHY
> configuration.
> Additionally, dwc3 has to be teared down and re-initialized whenever
> the cable is changed due to hardware quirks that prevent a new device
> from being recognized and due to the PHY being unable to switch lane
> mode or orientation while dwc3 is up and running.
>
> These controllers also have a Apple-specific MMIO region after the
> common dwc3 region where some controls have to be updated. PHY bringup
> and shutdown also requires SUSPHY to be enabled for the ports to work
> correctly.
>
> In the future, this driver will also gain support for USB3-via-USB4
> tunneling which will require additional tweaks.
>
> Add a glue driver that takes of all of these constraints.
>
> Reviewed-by: Neal Gompa <neal@gompa.dev>
> Acked-by: Thinh Nguyen <Thinh.Nguyen@synopsys.com>
> Signed-off-by: Sven Peter <sven@kernel.org>
> ---
> MAINTAINERS | 1 +
> drivers/usb/dwc3/Kconfig | 11 +
> drivers/usb/dwc3/Makefile | 1 +
> drivers/usb/dwc3/dwc3-apple.c | 489 ++++++++++++++++++++++++++++++++++++++++++
> 4 files changed, 502 insertions(+)
>
[...]
> diff --git a/drivers/usb/dwc3/dwc3-apple.c b/drivers/usb/dwc3/dwc3-apple.c
> new file mode 100644
> index 0000000000000000000000000000000000000000..6e41bd0e34f461b0c3db9b8a646116458ff816b6
> --- /dev/null
> +++ b/drivers/usb/dwc3/dwc3-apple.c
> @@ -0,0 +1,489 @@
[...]
> +static int dwc3_apple_probe(struct platform_device *pdev)
> +{
> + struct device *dev = &pdev->dev;
> + struct dwc3_apple *appledwc;
> + int ret;
> +
> + appledwc = devm_kzalloc(&pdev->dev, sizeof(*appledwc), GFP_KERNEL);
> + if (!appledwc)
> + return -ENOMEM;
> +
> + appledwc->dev = &pdev->dev;
> + mutex_init(&appledwc->lock);
> +
> + appledwc->resets = devm_reset_control_array_get_exclusive(dev);
Why is this using an array? The bindings say there is only a single
reset.
regards
Philipp
prev parent reply other threads:[~2025-10-16 10:45 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-15 15:40 [PATCH usb-next v2 0/5] Apple Silicon USB3 support - dwc3 Sven Peter
2025-10-15 15:40 ` [PATCH usb-next v2 1/5] dt-bindings: usb: Add Apple dwc3 Sven Peter
2025-10-15 15:40 ` [PATCH usb-next v2 2/5] usb: dwc3: dwc3_power_off_all_roothub_ports: Use ioremap_np when required Sven Peter
2025-10-15 15:40 ` [PATCH usb-next v2 3/5] usb: dwc3: glue: Add documentation Sven Peter
2025-10-15 15:40 ` [PATCH usb-next v2 4/5] usb: dwc3: glue: Allow more fine grained control over mode switches Sven Peter
2025-10-15 15:40 ` [PATCH usb-next v2 5/5] usb: dwc3: Add Apple Silicon DWC3 glue layer driver Sven Peter
2025-10-16 10:44 ` Philipp Zabel [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=47112ace39ea096242e68659d67a401e931abf3a.camel@pengutronix.de \
--to=p.zabel@pengutronix.de \
--cc=Thinh.Nguyen@synopsys.com \
--cc=asahi@lists.linux.dev \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=gregkh@linuxfoundation.org \
--cc=j@jannau.net \
--cc=krzk+dt@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=neal@gompa.dev \
--cc=robh@kernel.org \
--cc=sven@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).