diff options
author | Srinivas Kandagatla <srinivas.kandagatla@linaro.org> | 2014-07-08 14:16:14 +0100 |
---|---|---|
committer | Andrey Konovalov <andrey.konovalov@linaro.org> | 2014-07-25 20:54:55 +0400 |
commit | d0fc2fd5b10fdc70a1973a466343f8bdc0d2dc02 (patch) | |
tree | 97d90af558b739ebbb277d7e7d8b6cba40db5951 | |
parent | c34fc1b2df9f1ffa58d7ab802f6deec4cd1bb14f (diff) |
pci: qcom: remove static declaration of functions.
This patch removes declaration of the local function, by re-ordering the
usage.
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
-rw-r--r-- | drivers/pci/host/pci-qcom.c | 84 |
1 files changed, 39 insertions, 45 deletions
diff --git a/drivers/pci/host/pci-qcom.c b/drivers/pci/host/pci-qcom.c index 665943baed4e..5b49bfde3351 100644 --- a/drivers/pci/host/pci-qcom.c +++ b/drivers/pci/host/pci-qcom.c @@ -130,51 +130,6 @@ struct qcom_pcie { }; -static int qcom_pcie_map_irq(const struct pci_dev *dev, u8 slot, u8 pin); -static int qcom_pcie_setup(int nr, struct pci_sys_data *sys); -static int msm_pcie_rd_conf(struct pci_bus *bus, u32 devfn, int where, - int size, u32 *val); -static int msm_pcie_wr_conf(struct pci_bus *bus, u32 devfn, - int where, int size, u32 val); - -static struct pci_ops qcom_pcie_ops = { - .read = msm_pcie_rd_conf, - .write = msm_pcie_wr_conf, -}; - -static struct hw_pci qcom_hw_pci[MAX_RC_NUM] = { - { -#ifdef CONFIG_PCI_DOMAINS - .domain = 0, -#endif - .ops = &qcom_pcie_ops, - .nr_controllers = 1, - .swizzle = pci_common_swizzle, - .setup = qcom_pcie_setup, - .map_irq = qcom_pcie_map_irq, - }, - { -#ifdef CONFIG_PCI_DOMAINS - .domain = 1, -#endif - .ops = &qcom_pcie_ops, - .nr_controllers = 1, - .swizzle = pci_common_swizzle, - .setup = qcom_pcie_setup, - .map_irq = qcom_pcie_map_irq, - }, - { -#ifdef CONFIG_PCI_DOMAINS - .domain = 2, -#endif - .ops = &qcom_pcie_ops, - .nr_controllers = 1, - .swizzle = pci_common_swizzle, - .setup = qcom_pcie_setup, - .map_irq = qcom_pcie_map_irq, - }, -}; - static int nr_controllers; static DEFINE_SPINLOCK(qcom_hw_pci_lock); @@ -348,6 +303,45 @@ static int qcom_pcie_setup(int nr, struct pci_sys_data *sys) return 1; } +static struct pci_ops qcom_pcie_ops = { + .read = msm_pcie_rd_conf, + .write = msm_pcie_wr_conf, +}; + +static struct hw_pci qcom_hw_pci[MAX_RC_NUM] = { + { +#ifdef CONFIG_PCI_DOMAINS + .domain = 0, +#endif + .ops = &qcom_pcie_ops, + .nr_controllers = 1, + .swizzle = pci_common_swizzle, + .setup = qcom_pcie_setup, + .map_irq = qcom_pcie_map_irq, + .add_bus = qcom_pcie_add_bus, + }, + { +#ifdef CONFIG_PCI_DOMAINS + .domain = 1, +#endif + .ops = &qcom_pcie_ops, + .nr_controllers = 1, + .swizzle = pci_common_swizzle, + .setup = qcom_pcie_setup, + .map_irq = qcom_pcie_map_irq, + }, + { +#ifdef CONFIG_PCI_DOMAINS + .domain = 2, +#endif + .ops = &qcom_pcie_ops, + .nr_controllers = 1, + .swizzle = pci_common_swizzle, + .setup = qcom_pcie_setup, + .map_irq = qcom_pcie_map_irq, + }, +}; + static inline void qcom_elbi_writel_relaxed(struct qcom_pcie *pcie, u32 val, u32 reg) { |