0323588e5a77c78cc28970258471264fb5ccd616
[openwrt/openwrt.git] / target / linux / ramips / patches-6.1 / 105-v5.17-PCI-mt7621-Remove-unused-function-pcie_rmw.patch
1 From: Sergio Paracuellos <sergio.paracuellos@gmail.com>
2 Date: Mon, 24 Jan 2022 12:30:03 +0100
3 Subject: [PATCH] PCI: mt7621: Remove unused function pcie_rmw()
4
5 Function pcie_rmw() is not being used at all and can be deleted. Hence get
6 rid of it, which fixes this warning:
7
8 drivers/pci/controller/pcie-mt7621.c:112:20: warning: unused function 'pcie_rmw' [-Wunused-function]
9
10 Fixes: 2bdd5238e756 ("PCI: mt7621: Add MediaTek MT7621 PCIe host controller driver")
11 Link: https://lore.kernel.org/r/20220124113003.406224-3-sergio.paracuellos@gmail.com
12 Link: https://lore.kernel.org/all/202201241754.igtHzgHv-lkp@intel.com/
13 Reported-by: kernel test robot <lkp@intel.com>
14 Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
15 Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
16 ---
17
18 --- a/drivers/pci/controller/pcie-mt7621.c
19 +++ b/drivers/pci/controller/pcie-mt7621.c
20 @@ -109,15 +109,6 @@ static inline void pcie_write(struct mt7
21 writel_relaxed(val, pcie->base + reg);
22 }
23
24 -static inline void pcie_rmw(struct mt7621_pcie *pcie, u32 reg, u32 clr, u32 set)
25 -{
26 - u32 val = readl_relaxed(pcie->base + reg);
27 -
28 - val &= ~clr;
29 - val |= set;
30 - writel_relaxed(val, pcie->base + reg);
31 -}
32 -
33 static inline u32 pcie_port_read(struct mt7621_pcie_port *port, u32 reg)
34 {
35 return readl_relaxed(port->base + reg);