pci-quirks.h 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. #ifndef __LINUX_USB_PCI_QUIRKS_H
  3. #define __LINUX_USB_PCI_QUIRKS_H
  4. #ifdef CONFIG_USB_PCI_AMD
  5. int usb_hcd_amd_remote_wakeup_quirk(struct pci_dev *pdev);
  6. bool usb_amd_hang_symptom_quirk(void);
  7. bool usb_amd_prefetch_quirk(void);
  8. void usb_amd_dev_put(void);
  9. bool usb_amd_quirk_pll_check(void);
  10. void usb_amd_quirk_pll_disable(void);
  11. void usb_amd_quirk_pll_enable(void);
  12. void sb800_prefetch(struct device *dev, int on);
  13. bool usb_amd_pt_check_port(struct device *device, int port);
  14. #else
  15. static inline bool usb_amd_hang_symptom_quirk(void)
  16. {
  17. return false;
  18. };
  19. static inline bool usb_amd_prefetch_quirk(void)
  20. {
  21. return false;
  22. }
  23. static inline void usb_amd_quirk_pll_disable(void) {}
  24. static inline void usb_amd_quirk_pll_enable(void) {}
  25. static inline void usb_amd_dev_put(void) {}
  26. static inline bool usb_amd_quirk_pll_check(void)
  27. {
  28. return false;
  29. }
  30. static inline void sb800_prefetch(struct device *dev, int on) {}
  31. static inline bool usb_amd_pt_check_port(struct device *device, int port)
  32. {
  33. return false;
  34. }
  35. #endif /* CONFIG_USB_PCI_AMD */
  36. #ifdef CONFIG_USB_PCI
  37. void uhci_reset_hc(struct pci_dev *pdev, unsigned long base);
  38. int uhci_check_and_reset_hc(struct pci_dev *pdev, unsigned long base);
  39. void usb_asmedia_modifyflowcontrol(struct pci_dev *pdev);
  40. void usb_enable_intel_xhci_ports(struct pci_dev *xhci_pdev);
  41. void usb_disable_xhci_ports(struct pci_dev *xhci_pdev);
  42. #else
  43. struct pci_dev;
  44. static inline void usb_asmedia_modifyflowcontrol(struct pci_dev *pdev) {}
  45. static inline void usb_disable_xhci_ports(struct pci_dev *xhci_pdev) {}
  46. #endif /* CONFIG_USB_PCI */
  47. #endif /* __LINUX_USB_PCI_QUIRKS_H */