diff options
author | Tom Rini <trini@ti.com> | 2013-08-13 09:14:02 -0400 |
---|---|---|
committer | Tom Rini <trini@ti.com> | 2013-08-13 09:14:02 -0400 |
commit | b98d934128bcd98106e764d2f492ac79c38ae53d (patch) | |
tree | 5e078614fccb51f34fa8f7aa8d92c4f5f518b686 /drivers | |
parent | 67cafc0861477bf19a587508ed13f4538c7a281e (diff) | |
parent | 3aab0cd852d7c9565c2559a7983cbb73852bac28 (diff) | |
download | u-boot-imx-b98d934128bcd98106e764d2f492ac79c38ae53d.zip u-boot-imx-b98d934128bcd98106e764d2f492ac79c38ae53d.tar.gz u-boot-imx-b98d934128bcd98106e764d2f492ac79c38ae53d.tar.bz2 |
Merge branch 'master' of git://git.denx.de/u-boot-mpc85xx
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/fm/fm.c | 2 | ||||
-rw-r--r-- | drivers/pci/fsl_pci_init.c | 20 |
2 files changed, 16 insertions, 6 deletions
diff --git a/drivers/net/fm/fm.c b/drivers/net/fm/fm.c index 4bc8f35..bca20b3 100644 --- a/drivers/net/fm/fm.c +++ b/drivers/net/fm/fm.c @@ -396,6 +396,8 @@ int fm_init_common(int index, struct ccsr_fman *reg) } #elif defined(CONFIG_SYS_QE_FMAN_FW_IN_REMOTE) void *addr = (void *)CONFIG_SYS_QE_FMAN_FW_ADDR; +#else + void *addr = NULL; #endif /* Upload the Fman microcode if it's present */ diff --git a/drivers/pci/fsl_pci_init.c b/drivers/pci/fsl_pci_init.c index 17ca961..d55db1a 100644 --- a/drivers/pci/fsl_pci_init.c +++ b/drivers/pci/fsl_pci_init.c @@ -28,12 +28,6 @@ DECLARE_GLOBAL_DATA_PTR; #include <asm/io.h> #include <asm/fsl_pci.h> -/* Freescale-specific PCI config registers */ -#define FSL_PCI_PBFR 0x44 -#define FSL_PCIE_CAP_ID 0x4c -#define FSL_PCIE_CFG_RDY 0x4b0 -#define FSL_PROG_IF_AGENT 0x1 - #ifndef CONFIG_SYS_PCI_MEMORY_BUS #define CONFIG_SYS_PCI_MEMORY_BUS 0 #endif @@ -424,6 +418,15 @@ void fsl_pci_init(struct pci_controller *hose, struct fsl_pci_info *pci_info) udelay(1); #endif if (pcie_cap == PCI_CAP_ID_EXP) { + if (block_rev >= PEX_IP_BLK_REV_3_0) { +#define PEX_CSR0_LTSSM_MASK 0xFC +#define PEX_CSR0_LTSSM_SHIFT 2 + ltssm = (in_be32(&pci->pex_csr0) + & PEX_CSR0_LTSSM_MASK) >> PEX_CSR0_LTSSM_SHIFT; + enabled = (ltssm == 0x11) ? 1 : 0; + } else { + /* pci_hose_read_config_word(hose, dev, PCI_LTSSM, <ssm); */ + /* enabled = ltssm >= PCI_LTSSM_L0; */ pci_hose_read_config_word(hose, dev, PCI_LTSSM, <ssm); enabled = ltssm >= PCI_LTSSM_L0; @@ -456,6 +459,7 @@ void fsl_pci_init(struct pci_controller *hose, struct fsl_pci_info *pci_info) PCI_BASE_ADDRESS_0, pcicsrbar); } #endif + } #ifdef CONFIG_SYS_P4080_ERRATUM_PCIE_A003 if (enabled == 0) { @@ -564,6 +568,10 @@ int fsl_is_pci_agent(struct pci_controller *hose) u8 prog_if; pci_hose_read_config_byte(hose, dev, PCI_CLASS_PROG, &prog_if); + /* Programming Interface (PCI_CLASS_PROG) + * 0 == pci host or pcie root-complex, + * 1 == pci agent or pcie end-point + */ return (prog_if == FSL_PROG_IF_AGENT); } } |