Lines Matching refs:ohci

74 #define	OKAY_TO_TAKEBACK(ohci, ed)			\  argument
75 ((int) (ohci->wdh_cnt - ed->takeback_wdh_cnt) >= 0)
383 void (*start_hnp)(struct ohci_hcd *ohci);
442 static inline int quirk_nec(struct ohci_hcd *ohci) in quirk_nec() argument
444 return ohci->flags & OHCI_QUIRK_NEC; in quirk_nec()
446 static inline int quirk_zfmicro(struct ohci_hcd *ohci) in quirk_zfmicro() argument
448 return ohci->flags & OHCI_QUIRK_ZFMICRO; in quirk_zfmicro()
450 static inline int quirk_amdiso(struct ohci_hcd *ohci) in quirk_amdiso() argument
452 return ohci->flags & OHCI_QUIRK_AMD_PLL; in quirk_amdiso()
454 static inline int quirk_amdprefetch(struct ohci_hcd *ohci) in quirk_amdprefetch() argument
456 return ohci->flags & OHCI_QUIRK_AMD_PREFETCH; in quirk_amdprefetch()
459 static inline int quirk_nec(struct ohci_hcd *ohci) in quirk_nec() argument
463 static inline int quirk_zfmicro(struct ohci_hcd *ohci) in quirk_zfmicro() argument
467 static inline int quirk_amdiso(struct ohci_hcd *ohci) in quirk_amdiso() argument
471 static inline int quirk_amdprefetch(struct ohci_hcd *ohci) in quirk_amdprefetch() argument
482 static inline struct usb_hcd *ohci_to_hcd (const struct ohci_hcd *ohci) in ohci_to_hcd() argument
484 return container_of ((void *) ohci, struct usb_hcd, hcd_priv); in ohci_to_hcd()
489 #define ohci_dbg(ohci, fmt, args...) \ argument
490 dev_dbg (ohci_to_hcd(ohci)->self.controller , fmt , ## args )
491 #define ohci_err(ohci, fmt, args...) \ argument
492 dev_err (ohci_to_hcd(ohci)->self.controller , fmt , ## args )
493 #define ohci_info(ohci, fmt, args...) \ argument
494 dev_info (ohci_to_hcd(ohci)->self.controller , fmt , ## args )
495 #define ohci_warn(ohci, fmt, args...) \ argument
496 dev_warn (ohci_to_hcd(ohci)->self.controller , fmt , ## args )
537 #define big_endian_desc(ohci) (ohci->flags & OHCI_QUIRK_BE_DESC) argument
539 #define big_endian_desc(ohci) 1 /* only big endian */ argument
542 #define big_endian_desc(ohci) 0 /* only little endian */ argument
547 #define big_endian_mmio(ohci) (ohci->flags & OHCI_QUIRK_BE_MMIO) argument
549 #define big_endian_mmio(ohci) 1 /* only big endian */ argument
552 #define big_endian_mmio(ohci) 0 /* only little endian */ argument
560 static inline unsigned int _ohci_readl (const struct ohci_hcd *ohci, in _ohci_readl() argument
564 return big_endian_mmio(ohci) ? in _ohci_readl()
572 static inline void _ohci_writel (const struct ohci_hcd *ohci, in _ohci_writel() argument
576 big_endian_mmio(ohci) ? in _ohci_writel()
591 static inline __hc16 cpu_to_hc16 (const struct ohci_hcd *ohci, const u16 x) in cpu_to_hc16() argument
593 return big_endian_desc(ohci) ? in cpu_to_hc16()
598 static inline __hc16 cpu_to_hc16p (const struct ohci_hcd *ohci, const u16 *x) in cpu_to_hc16p() argument
600 return big_endian_desc(ohci) ? in cpu_to_hc16p()
605 static inline __hc32 cpu_to_hc32 (const struct ohci_hcd *ohci, const u32 x) in cpu_to_hc32() argument
607 return big_endian_desc(ohci) ? in cpu_to_hc32()
612 static inline __hc32 cpu_to_hc32p (const struct ohci_hcd *ohci, const u32 *x) in cpu_to_hc32p() argument
614 return big_endian_desc(ohci) ? in cpu_to_hc32p()
620 static inline u16 hc16_to_cpu (const struct ohci_hcd *ohci, const __hc16 x) in hc16_to_cpu() argument
622 return big_endian_desc(ohci) ? in hc16_to_cpu()
627 static inline u16 hc16_to_cpup (const struct ohci_hcd *ohci, const __hc16 *x) in hc16_to_cpup() argument
629 return big_endian_desc(ohci) ? in hc16_to_cpup()
634 static inline u32 hc32_to_cpu (const struct ohci_hcd *ohci, const __hc32 x) in hc32_to_cpu() argument
636 return big_endian_desc(ohci) ? in hc32_to_cpu()
641 static inline u32 hc32_to_cpup (const struct ohci_hcd *ohci, const __hc32 *x) in hc32_to_cpup() argument
643 return big_endian_desc(ohci) ? in hc32_to_cpup()
660 static inline u16 ohci_frame_no(const struct ohci_hcd *ohci) in ohci_frame_no() argument
663 if (big_endian_desc(ohci)) { in ohci_frame_no()
664 tmp = be32_to_cpup((__force __be32 *)&ohci->hcca->frame_no); in ohci_frame_no()
665 if (!(ohci->flags & OHCI_QUIRK_FRAME_NO)) in ohci_frame_no()
668 tmp = le32_to_cpup((__force __le32 *)&ohci->hcca->frame_no); in ohci_frame_no()
673 static inline __hc16 *ohci_hwPSWp(const struct ohci_hcd *ohci, in ohci_hwPSWp() argument
676 return (__hc16 *)(big_endian_desc(ohci) ? in ohci_hwPSWp()
680 static inline u16 ohci_hwPSW(const struct ohci_hcd *ohci, in ohci_hwPSW() argument
683 return hc16_to_cpup(ohci, ohci_hwPSWp(ohci, td, index)); in ohci_hwPSW()
693 static inline void periodic_reinit (struct ohci_hcd *ohci) in periodic_reinit() argument
695 u32 fi = ohci->fminterval & 0x03fff; in periodic_reinit()
696 u32 fit = ohci_readl(ohci, &ohci->regs->fminterval) & FIT; in periodic_reinit()
698 ohci_writel (ohci, (fit ^ FIT) | ohci->fminterval, in periodic_reinit()
699 &ohci->regs->fminterval); in periodic_reinit()
700 ohci_writel (ohci, ((9 * fi) / 10) & 0x3fff, in periodic_reinit()
701 &ohci->regs->periodicstart); in periodic_reinit()
736 extern int ohci_restart(struct ohci_hcd *ohci);