diff options
author | Minghao Chi <chi.minghao@zte.com.cn> | 2022-01-04 12:20:24 +0100 |
---|---|---|
committer | Thomas Bogendoerfer <tsbogend@alpha.franken.de> | 2022-01-05 09:54:08 +0100 |
commit | 6bcfdc49f38e274e3016c45284bfb286aa5a35d6 (patch) | |
tree | b27edec001f8f503ed7388398bb04661f31f8310 /arch/mips/pci | |
parent | MIPS: Loongson64: Add missing of_node_put() in ls2k_reset_init() (diff) | |
download | linux-6bcfdc49f38e274e3016c45284bfb286aa5a35d6.tar.xz linux-6bcfdc49f38e274e3016c45284bfb286aa5a35d6.zip |
mips/pci: remove redundant ret variable
Return value from rt3883_pci_r32() directly instead
of taking this in another redundant variable.
Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: Minghao Chi <chi.minghao@zte.com.cn>
Signed-off-by: CGEL ZTE <cgel.zte@gmail.com>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Diffstat (limited to 'arch/mips/pci')
-rw-r--r-- | arch/mips/pci/pci-rt3883.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/arch/mips/pci/pci-rt3883.c b/arch/mips/pci/pci-rt3883.c index d3c947fa2969..e07ae098bdd8 100644 --- a/arch/mips/pci/pci-rt3883.c +++ b/arch/mips/pci/pci-rt3883.c @@ -102,14 +102,12 @@ static u32 rt3883_pci_read_cfg32(struct rt3883_pci_controller *rpc, unsigned func, unsigned reg) { u32 address; - u32 ret; address = rt3883_pci_get_cfgaddr(bus, slot, func, reg); rt3883_pci_w32(rpc, address, RT3883_PCI_REG_CFGADDR); - ret = rt3883_pci_r32(rpc, RT3883_PCI_REG_CFGDATA); - return ret; + return rt3883_pci_r32(rpc, RT3883_PCI_REG_CFGDATA); } static void rt3883_pci_write_cfg32(struct rt3883_pci_controller *rpc, |