usbdebug: Refactor early enable
Always sanity check for EHCI class device and move PCI function power enablement up. Change-Id: I1eebe813fbb420738af2d572178213fc660f392a Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: https://review.coreboot.org/20826 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net> Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
This commit is contained in:
@@ -23,10 +23,13 @@
|
||||
#define EHCI_BAR_INDEX 0x10
|
||||
#define PCI_EHCI_CLASSCODE 0x0c0320 /* USB2.0 with EHCI controller */
|
||||
|
||||
/* Return PCI BDF for an EHCI controller by a given index. PCI function
|
||||
* must already be powered to respond to configuration requests.
|
||||
*/
|
||||
pci_devfn_t pci_ehci_dbg_dev(unsigned int hcd_idx);
|
||||
|
||||
u8 *pci_ehci_base_regs(pci_devfn_t dev);
|
||||
void pci_ehci_dbg_set_port(pci_devfn_t dev, unsigned int port);
|
||||
void pci_ehci_dbg_enable(pci_devfn_t dev, unsigned long base);
|
||||
|
||||
#ifndef __PRE_RAM__
|
||||
#if !IS_ENABLED(CONFIG_USBDEBUG)
|
||||
|
Reference in New Issue
Block a user