fsl_pci_init Fix command register initialization issue.
PATCH 1/1 fsl_pci_init Fix command register initialization issue.
Use generic setup_device to initialize standard pci regs for the host will lost the initilization for the command register. This patch initilize those regs including command register directly.
Signed-off-by Jason Jin <[email protected]>
--- drivers/fsl_pci_init.c | 15 ++++++++------- 1 files changed, 8 insertions(+), 7 deletions(-)
drivers/fsl_pci_init.c +8 -7
@@ -130,13 +130,14 @@ fsl_pci_init(struct pci_controller *hose) } -/* Use generic setup_device to initialize standard pci regs, -* but do not allocate any windows since any BAR found (such -* as PCSRBAR) is not in this cpu's memory space. -*/ - -pciauto_setup_device (hose, dev,0 , hose->pci_mem, - hose->pci_prefetch, hose->pci_io); +/* Initialize standard pci regs directly, do not allocate any windows +* since any BAR found (such as PCSRBAR) is not in this cpu's memory space. +*/ +pci_hose_read_config_dword (hose, dev,PCI_COMMAND , &temp32); + temp32 |= (PCI_COMMAND_IO |PCI_COMMAND_MEMORY ); +pci_hose_write_config_dword (hose, dev,PCI_COMMAND , temp32); +pci_hose_write_config_byte (hose, dev,PCI_CACHE_LINE_SIZE ,0x08 ); +pci_hose_write_config_byte (hose, dev,PCI_LATENCY_TIMER ,0x80 );#ifndef CONFIG_PCI_NOSCAN printf (" Scanning PCI bus %02x\n" , hose->current_busno);
Signature · 1 line
1.5.2