All of lore.kernel.org
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Alexey Charkov <alchark@gmail.com>
Cc: Alan Stern <stern@rowland.harvard.edu>,
	Benjamin Herrenschmidt <benh@kernel.crashing.org>,
	linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org,
	stable@vger.kernel.org
Subject: Re: [PATCH] usb: uhci-platform: Make the clock really optional
Date: Fri, 25 Apr 2025 16:20:33 +0200	[thread overview]
Message-ID: <2025042549-comma-whoever-ffe7@gregkh> (raw)
In-Reply-To: <20250425-uhci-clock-optional-v1-1-a1d462592f29@gmail.com>

On Fri, Apr 25, 2025 at 06:11:11PM +0400, Alexey Charkov wrote:
> Device tree bindings state that the clock is optional for UHCI platform
> controllers, and some existing device trees don't provide those - such
> as those for VIA/WonderMedia devices.
> 
> The driver however fails to probe now if no clock is provided, because
> devm_clk_get returns an error pointer in such case.
> 
> Switch to devm_clk_get_optional instead, so that it could probe again
> on those platforms where no clocks are given.
> 
> Cc: stable@vger.kernel.org
> Fixes: 26c502701c52 ("usb: uhci: Add clk support to uhci-platform")
> Signed-off-by: Alexey Charkov <alchark@gmail.com>
> ---
>  drivers/usb/host/uhci-platform.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/usb/host/uhci-platform.c b/drivers/usb/host/uhci-platform.c
> index a7c934404ebc7ed74f64265fafa7830809979ba5..62318291f5664c9ec94f24535c71d962e28354f3 100644
> --- a/drivers/usb/host/uhci-platform.c
> +++ b/drivers/usb/host/uhci-platform.c
> @@ -121,7 +121,7 @@ static int uhci_hcd_platform_probe(struct platform_device *pdev)
>  	}
>  
>  	/* Get and enable clock if any specified */
> -	uhci->clk = devm_clk_get(&pdev->dev, NULL);
> +	uhci->clk = devm_clk_get_optional(&pdev->dev, NULL);

Why does this need to go to all stable trees all of a sudden?  This has
been "broken" for years, what changed recently to cause this to show up?

thanks,

greg k-h

  reply	other threads:[~2025-04-25 14:20 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-25 14:11 [PATCH] usb: uhci-platform: Make the clock really optional Alexey Charkov
2025-04-25 14:20 ` Greg Kroah-Hartman [this message]
2025-04-25 14:47   ` Alexey Charkov

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=2025042549-comma-whoever-ffe7@gregkh \
    --to=gregkh@linuxfoundation.org \
    --cc=alchark@gmail.com \
    --cc=benh@kernel.crashing.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=stable@vger.kernel.org \
    --cc=stern@rowland.harvard.edu \
    /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 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.