mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-09 12:26:41 +07:00
PCI: armada: Add local base pointer
Add a local "base" pointer, as is done for other uses, to simplify a subsequent patch. No functional change intended. Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
This commit is contained in:
parent
e4aea9c4ad
commit
afb374f8ac
@ -73,10 +73,11 @@ struct armada8k_pcie {
|
|||||||
static int armada8k_pcie_link_up(struct pcie_port *pp)
|
static int armada8k_pcie_link_up(struct pcie_port *pp)
|
||||||
{
|
{
|
||||||
struct armada8k_pcie *pcie = to_armada8k_pcie(pp);
|
struct armada8k_pcie *pcie = to_armada8k_pcie(pp);
|
||||||
|
void __iomem *base = pcie->base;
|
||||||
u32 reg;
|
u32 reg;
|
||||||
u32 mask = PCIE_GLB_STS_RDLH_LINK_UP | PCIE_GLB_STS_PHY_LINK_UP;
|
u32 mask = PCIE_GLB_STS_RDLH_LINK_UP | PCIE_GLB_STS_PHY_LINK_UP;
|
||||||
|
|
||||||
reg = readl(pcie->base + PCIE_GLOBAL_STATUS_REG);
|
reg = readl(base + PCIE_GLOBAL_STATUS_REG);
|
||||||
|
|
||||||
if ((reg & mask) == mask)
|
if ((reg & mask) == mask)
|
||||||
return 1;
|
return 1;
|
||||||
|
Loading…
Reference in New Issue
Block a user