aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/platforms/52xx/mpc52xx_pci.c
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'next/cross-platform' of ↵Linus Torvalds2011-07-261-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/arm/linux-arm-soc * 'next/cross-platform' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/linux-arm-soc: ARM: Consolidate the clkdev header files ARM: set vga memory base at run-time ARM: convert PCI defines to variables ARM: pci: make pcibios_assign_all_busses use pci_has_flag ARM: remove unnecessary mach/hardware.h includes pci: move microblaze and powerpc pci flag functions into asm-generic powerpc: rename ppc_pci_*_flags to pci_*_flags Fix up conflicts in arch/microblaze/include/asm/pci-bridge.h
| * powerpc: rename ppc_pci_*_flags to pci_*_flagsRob Herring2011-07-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This renames pci flags functions and enums in preparation for creating generic version in asm-generic/pci-bridge.h. The following search and replace is done: s/ppc_pci_/pci_/ s/PPC_PCI_/PCI_/ Direct accesses to ppc_pci_flag variable are replaced with helper functions. Signed-off-by: Rob Herring <rob.herring@calxeda.com> Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org>
* | treewide: Convert uses of struct resource to resource_size(ptr)Joe Perches2011-06-101-4/+4
|/ | | | | | | | | | | | | | | | | | | | Several fixes as well where the +1 was missing. Done via coccinelle scripts like: @@ struct resource *ptr; @@ - ptr->end - ptr->start + 1 + resource_size(ptr) and some grep and typing. Mostly uncompiled, no cross-compilers. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
* tree-wide: fix assorted typos all over the placeAndré Goddard Rosa2009-12-041-1/+1
| | | | | | | | | | That is "success", "unknown", "through", "performance", "[re|un]mapping" , "access", "default", "reasonable", "[con]currently", "temperature" , "channel", "[un]used", "application", "example","hierarchy", "therefore" , "[over|under]flow", "contiguous", "threshold", "enough" and others. Signed-off-by: André Goddard Rosa <andre.goddard@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
* powerpc/pci: Clean up direct access to sysdata by 52xx platformsKumar Gala2009-05-211-2/+2
| | | | | | | | | | We shouldn't directly access sysdata to get the pci_controller. Instead use pci_bus_to_host() for this purpose. In the future we might have sysdata be a device_node to match ppc64 and unify the code between ppc32 & ppc64. Signed-off-by: Kumar Gala <galak@kernel.crashing.org> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
* powerpc/5200: Bugfix for PCI mapping of memory and IMMRGrant Likely2009-01-291-14/+10
| | | | | | | | | | | | | | | | | | This patch ensures that memory gets properly mapped into the PCI address space. Without this patch, the memory window BAR is left at whatever value happened to be loaded into the BAR when Linux was booted. Without this patch, memory could end up getting mapped at any of the 1G address boundaries instead of at '0' where Linux expects it. Similarly, this patch also ensures that the internally memory mapped registers (IMMR) are mapped to the correct PCI address range. Without this patch, PCI appears to work correctly until a PCI device is inserted which DMAs into memory. Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Tested-by: Wolfram Sang <w.sang@pengutronix.de>
* powerpc: Introduce ppc_pci_flags accessorsJosh Boyer2008-12-161-1/+1
| | | | | | | | | | | | | Currently there are a number of platforms that open code access to the ppc_pci_flags global variable. However, that variable is not present if CONFIG_PCI is not set, which can lead to a build break. This introduces a number of accessor functions that are defined to be empty in the case of CONFIG_PCI being disabled. The various platform files in the kernel are updated to use these. Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
* powerpc/mpc5200: Silence warnings in arch/powerpc/platforms/52xx/mpc52xx_pci.cTony Breeds2008-10-081-4/+9
| | | | | | | | Explicitly cast resource fields to unsigned long long, and match format specifier. Signed-off-by: Tony Breeds <tony@bakeyournoodle.com> Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
* powerpc/mpc5200: PCI write combine timerAndre Schwarz2008-07-121-1/+2
| | | | | | | | | | | | | | On MPC5200 the PCI target control register (PCITCR) @ MBAR + 0xD6C is initialized with only bit 7 (Latrule disable) set. The 8-Bit write combine timer (Bits 24..31) should be also set to a reasonable value _greater zero_ (0x08 = default) since setting it to 0x00 leads to _very poor_ performance as a PCI target since external burst won't be possible at all. Setting the WCT to 0x08 (cache-line size) leads to good overall perfomance. Signed-off-by: Andre Schwarz <andre.schwarz@matrix-vision.de> Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
* [POWERPC] mpc5200: normalize compatible property bindingsGrant Likely2008-01-261-3/+7
| | | | | | | | | | | | | | Update MPC5200 drivers to also look for compatible properties in the form "fsl,mpc5200-*" to better conform to open firmware generic names recommended practice as published here: http://www.openfirmware.org/1275/practice/gnames/gnamv14a.html This patch should *not* break compatibility with older device trees which do not use the 'fsl,' prefix. The drivers will still bind against the older names also. Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
* [POWERPC] mpc5200: Add common mpc52xx_setup_pci() routineMarian Balakowicz2008-01-181-0/+14
| | | | | | | | | This patch moves a generic pci init code from lite5200 platform file to a common mpc52xx_setup_pci() routine and adds additional compatibility property verification. Signed-off-by: Marian Balakowicz <m8@semihalf.com> Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
* [POWERPC] pci32: Add flags modifying the PCI code behaviourBenjamin Herrenschmidt2007-12-201-1/+1
| | | | | | | | | | | | | | This adds to the 32 bits PCI code some flags, replacing the old pci_assign_all_busses global, that allow us to control various aspects of the PCI probing, such as whether to re-assign all resources or not, or to not try to assign anything at all. This also adds the flag x86 already has to avoid ISA alignment on bridges that don't have ISA forwarding enabled (no legacy devices on the top level bus) and sets it for PowerMacs. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
* [POWERPC] Merge ppc32 and ppc64 pcibios_alloc_controller() prototypesKumar Gala2007-06-291-3/+1
| | | | | | | Make the ppc32 pcibios_alloc_controller take a device node to match the ppc64 prototypes and have it set arch_data. Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
* [POWERPC] Pass the pci_controller into pci_exclude_deviceKumar Gala2007-06-291-2/+2
| | | | | | | | | | There are times that we need to know which controller we are on to decide how to exclude devices properly. We now pass the pci_controller that we are going to use down to the pci_exclude_device function. This will greatly simplify being able to exclude the PHBs in multiple controller setups. Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
* [POWERPC] 52xx: Remove support for PCI bus_offsetKumar Gala2007-06-291-5/+4
| | | | | | | The hose->bus_offset is only used for PCI config cycles and the 52xx PCI config code doesn't actually ever set bus_offset to a non-zero value. Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
* [POWERPC] Remove set_cfg_type for PCI indirect users that don't need itKumar Gala2007-06-291-1/+0
| | | | | | | | | | | The Freescale and Marvell PCI controllers dont require explicit setting for type 1 config cycles. They handle producing them by implicitly looking at the bus, devfn. The TSI108 and 52xx don't use the generic PCI indirect code and thus don't bother with set_cfg_type. Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
* [POWERPC] Rename get_property to of_get_property: arch/powerpcStephen Rothwell2007-04-131-1/+1
| | | | | | Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
* [POWERPC] Add mpc52xx/lite5200 PCI supportGrant Likely2007-02-081-0/+412
Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Acked-by: Sylvain Munaut <tnt@246tNt.com> Signed-off-by: Paul Mackerras <paulus@samba.org>