Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

PCI: generic: Move structure definitions to separate header file

Move definitions for generic PCI host controller driver structures to a
separate header file so we can share them with other drivers. No
functional change intended.

[bhelgaas: split into separate patch, changelog]
Signed-off-by: David Daney <david.daney@cavium.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Will Deacon <will.deacon@arm.com>

authored by

David Daney and committed by
Bjorn Helgaas
7149b9fd 92e963f5

+45 -18
+44
drivers/pci/host/pci-host-common.h
··· 1 + /* 2 + * This program is free software; you can redistribute it and/or modify 3 + * it under the terms of the GNU General Public License version 2 as 4 + * published by the Free Software Foundation. 5 + * 6 + * This program is distributed in the hope that it will be useful, 7 + * but WITHOUT ANY WARRANTY; without even the implied warranty of 8 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 9 + * GNU General Public License for more details. 10 + * 11 + * You should have received a copy of the GNU General Public License 12 + * along with this program. If not, see <http://www.gnu.org/licenses/>. 13 + * 14 + * Copyright (C) 2014 ARM Limited 15 + * 16 + * Author: Will Deacon <will.deacon@arm.com> 17 + */ 18 + 19 + #ifndef _PCI_HOST_COMMON_H 20 + #define _PCI_HOST_COMMON_H 21 + 22 + #include <linux/kernel.h> 23 + #include <linux/platform_device.h> 24 + 25 + struct gen_pci_cfg_bus_ops { 26 + u32 bus_shift; 27 + struct pci_ops ops; 28 + }; 29 + 30 + struct gen_pci_cfg_windows { 31 + struct resource res; 32 + struct resource *bus_range; 33 + void __iomem **win; 34 + 35 + struct gen_pci_cfg_bus_ops *ops; 36 + }; 37 + 38 + struct gen_pci { 39 + struct pci_host_bridge host; 40 + struct gen_pci_cfg_windows cfg; 41 + struct list_head resources; 42 + }; 43 + 44 + #endif /* _PCI_HOST_COMMON_H */
+1 -18
drivers/pci/host/pci-host-generic.c
··· 25 25 #include <linux/of_pci.h> 26 26 #include <linux/platform_device.h> 27 27 28 - struct gen_pci_cfg_bus_ops { 29 - u32 bus_shift; 30 - struct pci_ops ops; 31 - }; 32 - 33 - struct gen_pci_cfg_windows { 34 - struct resource res; 35 - struct resource *bus_range; 36 - void __iomem **win; 37 - 38 - struct gen_pci_cfg_bus_ops *ops; 39 - }; 40 - 41 - struct gen_pci { 42 - struct pci_host_bridge host; 43 - struct gen_pci_cfg_windows cfg; 44 - struct list_head resources; 45 - }; 28 + #include "pci-host-common.h" 46 29 47 30 static void __iomem *gen_pci_map_cfg_bus_cam(struct pci_bus *bus, 48 31 unsigned int devfn,