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

usb: ohci-da8xx: remove unused platform data

We no longer support any board files for DaVinci in mainline and so
struct da8xx_ohci_root_hub is no longer used. Remove it together with
all the code it's used for.

Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Link: https://patch.msgid.link/20251114-davinci-usb-v1-1-737380353a74@linaro.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Bartosz Golaszewski and committed by
Greg Kroah-Hartman
a75a5b14 363eb9bf

-39
-17
drivers/usb/host/ohci-da8xx.c
··· 18 18 #include <linux/of.h> 19 19 #include <linux/platform_device.h> 20 20 #include <linux/phy/phy.h> 21 - #include <linux/platform_data/usb-davinci.h> 22 21 #include <linux/regulator/consumer.h> 23 22 #include <linux/usb.h> 24 23 #include <linux/usb/hcd.h> ··· 165 166 return 0; 166 167 } 167 168 168 - static int ohci_da8xx_has_potpgt(struct usb_hcd *hcd) 169 - { 170 - struct device *dev = hcd->self.controller; 171 - struct da8xx_ohci_root_hub *hub = dev_get_platdata(dev); 172 - 173 - if (hub && hub->potpgt) 174 - return 1; 175 - 176 - return 0; 177 - } 178 - 179 169 static int ohci_da8xx_regulator_event(struct notifier_block *nb, 180 170 unsigned long event, void *data) 181 171 { ··· 216 228 static int ohci_da8xx_reset(struct usb_hcd *hcd) 217 229 { 218 230 struct device *dev = hcd->self.controller; 219 - struct da8xx_ohci_root_hub *hub = dev_get_platdata(dev); 220 231 struct ohci_hcd *ohci = hcd_to_ohci(hcd); 221 232 int result; 222 233 u32 rh_a; ··· 252 265 if (ohci_da8xx_has_oci(hcd)) { 253 266 rh_a &= ~RH_A_NOCP; 254 267 rh_a |= RH_A_OCPM; 255 - } 256 - if (ohci_da8xx_has_potpgt(hcd)) { 257 - rh_a &= ~RH_A_POTPGT; 258 - rh_a |= hub->potpgt << 24; 259 268 } 260 269 ohci_writel(ohci, rh_a, &ohci->regs->roothub.a); 261 270
-22
include/linux/platform_data/usb-davinci.h
··· 1 - /* 2 - * USB related definitions 3 - * 4 - * Copyright (C) 2009 MontaVista Software, Inc. <source@mvista.com> 5 - * 6 - * This file is licensed under the terms of the GNU General Public License 7 - * version 2. This program is licensed "as is" without any warranty of any 8 - * kind, whether express or implied. 9 - */ 10 - 11 - #ifndef __ASM_ARCH_USB_H 12 - #define __ASM_ARCH_USB_H 13 - 14 - /* Passed as the platform data to the OHCI driver */ 15 - struct da8xx_ohci_root_hub { 16 - /* Time from power on to power good (in 2 ms units) */ 17 - u8 potpgt; 18 - }; 19 - 20 - void davinci_setup_usb(unsigned mA, unsigned potpgt_ms); 21 - 22 - #endif /* ifndef __ASM_ARCH_USB_H */