Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

USB: EHCI: ehci-w90x900: remove unuseful functions

The ehci_w90x900_probe function is not doing anything other than
calling usb_w90x900_probe function so ehci_w90x900_probe function
is unuseful that is why removed ehci_w90x900_probe functions and
renamed usb_w90x900_probe function to ehci_w90x900_probe for proper
naming.

The ehci_w90x900_remove function is also not doing anything other
than calling usb_w90x900_remove that is why removed ehci_w90x900_remove
function and renamed usb_w90x900_remove to ehci_w90x900_remove for proper
naming.

This also removes warning of checkpatch.pl script.

Signed-off-by: Manjunath Goudar <csmanjuvijay@gmail.com>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Alan Stern <stern@rowland.harvard.edu>
Cc: Wan ZongShun <mcuos.com@gmail.com>
Cc: linux-usb@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Manjunath Goudar and committed by
Greg Kroah-Hartman
fd3ed14e 96cad6ff

+8 -22
+8 -22
drivers/usb/host/ehci-w90x900.c
··· 33 33 34 34 static struct hc_driver __read_mostly ehci_w90x900_hc_driver; 35 35 36 - static int usb_w90x900_probe(const struct hc_driver *driver, 37 - struct platform_device *pdev) 36 + static int ehci_w90x900_probe(struct platform_device *pdev) 38 37 { 39 38 struct usb_hcd *hcd; 40 39 struct ehci_hcd *ehci; ··· 41 42 int retval = 0, irq; 42 43 unsigned long val; 43 44 44 - hcd = usb_create_hcd(driver, &pdev->dev, "w90x900 EHCI"); 45 + hcd = usb_create_hcd(&ehci_w90x900_hc_driver, 46 + &pdev->dev, "w90x900 EHCI"); 45 47 if (!hcd) { 46 48 retval = -ENOMEM; 47 49 goto err1; ··· 63 63 HC_LENGTH(ehci, ehci_readl(ehci, &ehci->caps->hc_capbase)); 64 64 65 65 /* enable PHY 0,1,the regs only apply to w90p910 66 - * 0xA4,0xA8 were offsets of PHY0 and PHY1 controller of 67 - * w90p910 IC relative to ehci->regs. 68 - */ 66 + * 0xA4,0xA8 were offsets of PHY0 and PHY1 controller of 67 + * w90p910 IC relative to ehci->regs. 68 + */ 69 69 val = __raw_readl(ehci->regs+PHY0_CTR); 70 70 val |= ENPHY; 71 71 __raw_writel(val, ehci->regs+PHY0_CTR); ··· 92 92 return retval; 93 93 } 94 94 95 - static void usb_w90x900_remove(struct usb_hcd *hcd, 96 - struct platform_device *pdev) 97 - { 98 - usb_remove_hcd(hcd); 99 - usb_put_hcd(hcd); 100 - } 101 - 102 - static int ehci_w90x900_probe(struct platform_device *pdev) 103 - { 104 - if (usb_disabled()) 105 - return -ENODEV; 106 - 107 - return usb_w90x900_probe(&ehci_w90x900_hc_driver, pdev); 108 - } 109 - 110 95 static int ehci_w90x900_remove(struct platform_device *pdev) 111 96 { 112 97 struct usb_hcd *hcd = platform_get_drvdata(pdev); 113 98 114 - usb_w90x900_remove(hcd, pdev); 99 + usb_remove_hcd(hcd); 100 + usb_put_hcd(hcd); 115 101 116 102 return 0; 117 103 }