diff mbox series

usb: olpi: Remove unused otg_ulpi_create

Message ID 20250223160602.91916-1-linux@treblig.org (mailing list archive)
State New
Headers show
Series usb: olpi: Remove unused otg_ulpi_create | expand

Commit Message

Dr. David Alan Gilbert Feb. 23, 2025, 4:06 p.m. UTC
From: "Dr. David Alan Gilbert" <linux@treblig.org>

otg_ulpi_create() has been unused since 2022's
commit 8ca79aaad8be ("ARM: pxa: remove unused pxa3xx-ulpi")

Remove it.

The devm_ variant is still used.

Signed-off-by: Dr. David Alan Gilbert <linux@treblig.org>
---
 drivers/usb/phy/phy-ulpi.c | 23 -----------------------
 include/linux/usb/ulpi.h   |  9 ---------
 2 files changed, 32 deletions(-)

Comments

Sergey Shtylyov Feb. 23, 2025, 6:05 p.m. UTC | #1
On 2/23/25 7:06 PM, linux@treblig.org wrote:

> From: "Dr. David Alan Gilbert" <linux@treblig.org>
> 
> otg_ulpi_create() has been unused since 2022's
> commit 8ca79aaad8be ("ARM: pxa: remove unused pxa3xx-ulpi")
> 
> Remove it.
> 
> The devm_ variant is still used.
> 
> Signed-off-by: Dr. David Alan Gilbert <linux@treblig.org>
> ---
>  drivers/usb/phy/phy-ulpi.c | 23 -----------------------

   Probably s/olpi/ulpi/ in the subject then?

>  include/linux/usb/ulpi.h   |  9 ---------
>  2 files changed, 32 deletions(-)
> [...]
MBR, Sergey
Dr. David Alan Gilbert Feb. 23, 2025, 9:43 p.m. UTC | #2
* Sergey Shtylyov (s.shtylyov@omp.ru) wrote:
> On 2/23/25 7:06 PM, linux@treblig.org wrote:
> 
> > From: "Dr. David Alan Gilbert" <linux@treblig.org>
> > 
> > otg_ulpi_create() has been unused since 2022's
> > commit 8ca79aaad8be ("ARM: pxa: remove unused pxa3xx-ulpi")
> > 
> > Remove it.
> > 
> > The devm_ variant is still used.
> > 
> > Signed-off-by: Dr. David Alan Gilbert <linux@treblig.org>
> > ---
> >  drivers/usb/phy/phy-ulpi.c | 23 -----------------------
> 
>    Probably s/olpi/ulpi/ in the subject then?

Oops, thanks!

Dave

> >  include/linux/usb/ulpi.h   |  9 ---------
> >  2 files changed, 32 deletions(-)
> > [...]
> MBR, Sergey
>
diff mbox series

Patch

diff --git a/drivers/usb/phy/phy-ulpi.c b/drivers/usb/phy/phy-ulpi.c
index e683a37e3a7a..4df63e67bb37 100644
--- a/drivers/usb/phy/phy-ulpi.c
+++ b/drivers/usb/phy/phy-ulpi.c
@@ -255,29 +255,6 @@  static void otg_ulpi_init(struct usb_phy *phy, struct usb_otg *otg,
 	otg->set_vbus	= ulpi_set_vbus;
 }
 
-struct usb_phy *
-otg_ulpi_create(struct usb_phy_io_ops *ops,
-		unsigned int flags)
-{
-	struct usb_phy *phy;
-	struct usb_otg *otg;
-
-	phy = kzalloc(sizeof(*phy), GFP_KERNEL);
-	if (!phy)
-		return NULL;
-
-	otg = kzalloc(sizeof(*otg), GFP_KERNEL);
-	if (!otg) {
-		kfree(phy);
-		return NULL;
-	}
-
-	otg_ulpi_init(phy, otg, ops, flags);
-
-	return phy;
-}
-EXPORT_SYMBOL_GPL(otg_ulpi_create);
-
 struct usb_phy *
 devm_otg_ulpi_create(struct device *dev,
 		     struct usb_phy_io_ops *ops,
diff --git a/include/linux/usb/ulpi.h b/include/linux/usb/ulpi.h
index 5050f502c1ed..4b651065738a 100644
--- a/include/linux/usb/ulpi.h
+++ b/include/linux/usb/ulpi.h
@@ -49,19 +49,10 @@ 
 /*-------------------------------------------------------------------------*/
 
 #if IS_ENABLED(CONFIG_USB_ULPI)
-struct usb_phy *otg_ulpi_create(struct usb_phy_io_ops *ops,
-					unsigned int flags);
-
 struct usb_phy *devm_otg_ulpi_create(struct device *dev,
 				     struct usb_phy_io_ops *ops,
 				     unsigned int flags);
 #else
-static inline struct usb_phy *otg_ulpi_create(struct usb_phy_io_ops *ops,
-					      unsigned int flags)
-{
-	return NULL;
-}
-
 static inline struct usb_phy *devm_otg_ulpi_create(struct device *dev,
 						   struct usb_phy_io_ops *ops,
 						   unsigned int flags)