• Bjorn Helgaas's avatar
    PCI: designware: Return data directly from dw_pcie_readl_rc() · 446fc23f
    Bjorn Helgaas authored
    dw_pcie_readl_rc() reads a u32 value.  Previously we stored that value in
    space supplied by the caller.  Return the u32 value directly instead.
    
    This makes the calling code read better and makes it obvious that the
    caller need not initialize the storage.  In the following example it isn't
    clear whether "val" is initialized before being used:
    
      dw_pcie_readl_rc(pp, PCI_COMMAND, &val);
      if (val & PCI_COMMAND_MEMORY)
        ...
    
    No functional change intended.
    Signed-off-by: default avatarBjorn Helgaas <bhelgaas@google.com>
    446fc23f
pcie-designware.h 2.81 KB