aboutsummaryrefslogtreecommitdiff
path: root/arch/powerpc/platforms
AgeCommit message (Collapse)Author
2007-10-08[POWERPC] Use for_each_ matching routinues for pci PHBsKumar Gala
On the Freescale embedded (83xx, 85xx, 86xx) and a few of the discrete bridges (mpc10x, tsi108) use the new for_each_compatible_node() or for_each_node_by_type() to provide more exact matching when looking for PHBs in the device tree. With the previous code it was possible to match on pci bridges since we were only matching on device_type. Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-10-08[POWERPC] Add initial MPC8610 HPCD Platform files.Xianghua Xiao
Add basic board support for the MPC8610 HPCD. This does not include any support the SoC Display or Audio controllers. Signed-off-by: Xianghua Xiao <x.xiao@freescale.com> Signed-off-by: Jason Jin <Jason.jin@freescale.com> Signed-off-by: Jon Loelier <jdl@freescale.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-10-04[POWERPC] bootwrapper: adds cuboot for MPC7448HPC2 platformRoy Zang
This patch adds cuboot support for MPC7448HPC2 platform. The cuImage can be used with legacy u-boot without FDT support. Signed-off-by: Roy Zang <tie-fei.zang@freescale.com> Acked-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-10-04[POWERPC] mpc82xx: Add pq2fads board support.Scott Wood
Signed-off-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-10-04[POWERPC] mpc82xx: Update mpc8272ads, and factor out PCI and reset.Scott Wood
1. PCI and reset are factored out into pq2.c. I renamed them from m82xx to pq2 because they won't work on the Integrated Host Processor line of 82xx chips (i.e. 8240, 8245, and such). 2. The PCI PIC, which is nominally board-specific, is used on multiple boards, and thus is used into pq2ads-pci-pic.c. 3. The new CPM binding is used. 4. General cleanup. Signed-off-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-10-04[POWERPC] 8xx/wrapper: Embedded Planet EP88xC supportScott Wood
This board is also resold by Freescale under the names "QUICCStart MPC885 Evaluation System" and "CWH-PPC-885XN-VE". Signed-off-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-10-04[POWERPC] 8xx: mpc885ads cleanupScott Wood
It now uses the new CPM binding and the generic pin/clock functions, and has assorted fixes and cleanup. Signed-off-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-10-04[POWERPC] mpc8272ads: Change references from 82xx_ADS to 8272_ADS.Scott Wood
Signed-off-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-10-04[POWERPC] mpc82xx: Rename mpc82xx_ads to mpc8272_ads.Scott Wood
This is just a rename patch; internal references to mpc82xx_ads will be changed in the next one. Signed-off-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-10-04[POWERPC] mpc82xx: Remove a bunch of cruft that duplicates generic ↵Scott Wood
functionality. m82xx_calibrate_decr(), mpc82xx_ads_show_cpuinfo(), and mpc82xx_halt() do anything useful beyond what the generic code does. Signed-off-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-10-03[POWERPC] 8xx: Work around CPU15 erratum.Scott Wood
The CPU15 erratum on MPC8xx chips can cause incorrect code execution under certain circumstances, where there is a conditional or indirect branch in the last word of a page, with a target in the last cache line of the next page. This patch implements one of the suggested workarounds, by forcing a TLB miss whenever execution crosses a page boundary. This is done by invalidating the pages before and after the one being loaded into the TLB in the ITLB miss handler. Signed-off-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-10-03[POWERPC] 8xx: Infrastructure code cleanup.Scott Wood
1. Keep a global mpc8xx_immr mapping, rather than constantly creating temporary mappings. 2. Look for new fsl,cpm1 and fsl,cpm1-pic names. 3. Always reset the CPM when not using the udbg console; this is required in case the firmware initialized a device that is incompatible with one that the kernel is about to use. 4. Remove some superfluous casts and header includes. 5. Change a usage of IMAP_ADDR to get_immrbase(). 6. Use phys_addr_t, not uint, for dpram_pbase. 7. Various sparse-related fixes, such as __iomem annotations. 8. Remove mpc8xx_show_cpuinfo, which doesn't provide anything useful beyond the generic cpuinfo handler. 9. Move prototypes for 8xx support functions from board files to sysdev/commproc.h. Signed-off-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-10-03[POWERPC] Add early debug console for CPM serial ports.Scott Wood
This code assumes that the ports have been previously set up, with buffers in DPRAM. Signed-off-by: Scott Wood <scottwood@freescale.com> Acked-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-10-03[POWERPC] Introduce new CPM device bindings.Scott Wood
This introduces a new device binding for the CPM and other devices on these boards. Some of the changes include: 1. Proper namespace scoping for Freescale compatibles and properties. 2. Use compatible rather than things like device_type and model to determine which particular variant of a device is present. 3. Give the drivers the relevant CPM command word directly, rather than requiring it to have a lookup table based on device-id, SCC v. SMC, and CPM version. 4. Specify the CPCR and the usable DPRAM region in the CPM's reg property. Boards that do not require the legacy bindings should select CONFIG_PPC_CPM_NEW_BINDING to enable the of_platform CPM devices. Once all existing boards are converted and tested, the config option can become default y to prevent new boards from using the old model. Once arch/ppc is gone, the config option can be removed altogether. Signed-off-by: Scott Wood <scottwood@freescale.com> Acked-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-10-03[POWERPC] Virtex: Add generic Xilinx Virtex board supportGrant Likely
Adds support for generic Xilinx Virtex boards. Any board which specifies "xilinx,virtex" in the compatible property will make use of this board support. Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
2007-10-03[POWERPC] Virtex: Add Kconfig macros for Xilinx Virtex board supportGrant Likely
Add the needed kconfig macros to enable Xilinx Virtex board support Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
2007-10-03[POWERPC] Enable tickless idle and high res timers for powerpcTony Breeds
Signed-off-by: Tony Breeds <tony@bakeyournoodle.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-10-03Merge branch 'linux-2.6' into for-2.6.24Paul Mackerras
2007-10-03[POWERPC] Fix panic in RTAS codeTony Breeds
Some older pSeries machines were panicking in pSeries_log_error because it was getting called before it was ready. This is a result of commit "[POWERPC] pseries: Fix jumbled no_logging flag." (79c0108d1b9db4864ab77b2a95dfa04f2dcf264c). This fixes it by explicitly enabling RTAS error logging when it has been initialized, and also makes the code clearer by renaming the "no_more_logging" variable to "logging_enabled". Signed-off-by: Tony Breeds <tony@bakeyournoodle.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-10-03[POWERPC] Celleb: update for PCIIshizaki Kou
This adds support for the PCI bus on Celleb with new "I/O routines for PowerPC." External PCI on Celleb must do explicit synchronization with devices (Bus has no automatic synchronization feature). Signed-off-by: Kou Ishizaki <Kou.Ishizaki@toshiba.co.jp> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-10-03[POWERPC] Celleb: Serial I/O updateIshizaki Kou
This is an update for Serial I/O on Celleb. - Detection algorithm has been changed Signed-off-by: Kou Ishizaki <Kou.Ishizaki@toshiba.co.jp> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-10-03[POWERPC] Celleb: New HTAB Guest OS Interface on BeatIshizaki Kou
This changes the Celleb code to work with new Guest OS Interface to tweak HTAB on Beat. It detects old and new Guest OS Interfaces automatically. Signed-off-by: Kou Ishizaki <Kou.Ishizaki@toshiba.co.jp> Acked-by: Arnd Bergmann <arnd.bergmann@de.ibm.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-10-03[POWERPC] Celleb: Support for Power/Reset buttonsIshizaki Kou
This supports Power/Reset buttons on Beat on Celleb. On Beat, we have an event from Beat if Power button or Reset button is pressed. This patch catches the event and convert it to a signal to INIT process by calling ctrl_alt_del() function. /sbin/inittab have no entry to turn the machine power off so we have to detect if power button is pressed or not internally in our driver. This idea is taken from PS3's event handling subsystem. Signed-off-by: Kou Ishizaki <Kou.Ishizaki@toshiba.co.jp> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-10-03[POWERPC] Celleb: Move pause, kexec_cpu_down to beat.cIshizaki Kou
This is an update for "Beat on Celleb" - Move beat_pause(), beat_kexec_cpu_down() from setup.c to beat.c Signed-off-by: <Kou.Ishizaki@toshiba.co.jp> Acked-by: Arnd Bergmann <arnd.bergmann@de.ibm.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-10-03[POWERPC] Update axon_msi to use dcr_host_t.baseMichael Ellerman
Now that dcr_host_t contains the base address, we can use that in the axon_msi code, rather than storing it separately. Signed-off-by: Michael Ellerman <michael@ellerman.id.au> Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-10-03[POWERPC] clk.h interface for platformsDomen Puncer
This provides an implementation of the <linux/clk.h> interface for arch/powerpc using a set of function pointers in clk_functions. Platforms that want to support this interface should fill clk_functions and select CONFIG_PPC_CLOCK in Kconfig. Signed-off-by: Domen Puncer <domen.puncer@telargo.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-10-03[POWERPC] Simplify rtas_change_msi() error semanticsMichael Ellerman
Currently rtas_change_msi() returns either the error code from RTAS, or if the RTAS call succeeded the number of irqs that were configured by RTAS. This makes checking the return value more complicated than it needs to be. Instead, have rtas_change_msi() check that the number of irqs configured by RTAS is equal to what we requested - and return an error otherwise. This makes the return semantics match the usual 0 for success, something else for error. Signed-off-by: Michael Ellerman <michael@ellerman.id.au> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-10-03[POWERPC] Simplify error logic in rtas_setup_msi_irqs()Michael Ellerman
rtas_setup_msi_irqs() doesn't need to call teardown() itself, the generic code will do this for us as long as we return a non-zero value. Signed-off-by: Michael Ellerman <michael@ellerman.id.au> Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-10-03[POWERPC] Make sure to of_node_get() the result of pci_device_to_OF_node()Michael Ellerman
pci_device_to_OF_node() returns the device node attached to a PCI device, but doesn't actually grab a reference - we need to do it ourselves. Signed-off-by: Michael Ellerman <michael@ellerman.id.au> Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-10-03[POWERPC] Move embedded6xx into multiplatformArnd Bergmann
The various embedded 6xx systems can easily coexist in one kernel together with the other 6xx based systems, so there is no strict reason to keep them separate. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-10-02[POWERPC] pseries: device node status can be "ok" or "okay"Linas Vepstas
It seems that some versions of firmware will report a device node status as the string "okay". As we are not expecting this string, the device node will be ignored by the EEH subsystem. Which means EEH will not be enabled. When EEH is not enabled, PCI errors will be converted into Machine Check exceptions, and we'll have a very unhappy system. Signed-off-by: Linas Vepstas <linas@austin.ibm.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-10-02[POWERPC] Fix xics set_affinity codeAnton Blanchard
On a POWER6 machine running 2.6.23-rc8 I sometimes see the following error: xics_set_affinity: No online cpus in the mask 00000000,00000000,00000000,00000001 for irq 20 In a desperate attempt to get a changelog entry in 2.6.23, I took a look into it. It turns out we are passing a real and not a virtual irq into get_irq_server. This works for the case where hwirq < NR_IRQS and we set virq = hwirq. In my case however hwirq = 590082 and we try and access irq_desc[590082], slightly past the end at 512 entries. Lucky we ship lots of memory with our machines. Signed-off-by: Anton Blanchard <anton@samba.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-09-28[POWERPC] Fix mpc834x USB-MPH configuration.jacmet@sunsite.dk
mpc834x USB-MPH configuration got broken by commit 6f442560021aecf08658e26ed9a37e6928ef0fa1. The selection bits in SICRL should be cleared rather than set to configure the USB MUXes for the MPH. Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-09-26[POWERPC] spufs: fix mismerge, making context signal{1,2} files readable againJeremy Kerr
The commit 8b6f50ef1d5cc86b278eb42bc91630fad455fb10 seems to have been affected by a mismerge of a duplicate patch (d054b36ffd302ec65aabec16a0c60ddd9e6b5a62) - both the spufs_dir_contents and spufs_dir_nosched_contents have been given write-only signal notification files. This change reverts the spufs_dir_contents array to use the readable signal notification file implementation. Signed-off-by: Jeremy Kerr <jk@ozlabs.org> Acked-by: Arnd Bergmann <arnd.bergmann@de.ibm.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-09-22[POWERPC] add Kconfig option for optimizing for cellArnd Bergmann
Since the PPE on cell is an in-order core, it suffers significantly from wrong instruction scheduling. This adds a Kconfig option that enables passing -mtune=cell to gcc in order to generate object code that runs well on cell. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-09-22[POWERPC] cell: Don't cast the result of of_get_property()Jeremy Kerr
The cast to u32 * isn't required, of_get_property returns a void *. Signed-off-by: Jeremy Kerr <jk@ozlabs.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-09-22[POWERPC] Convert define_machine(mpc885_ads) to C99 initializer syntaxTony Breeds
Make the define_machine() block for mpc885_ads more greppable and consistent with other examples in tree. Signed-off-by: Tony Breeds <tony@bakeyournoodle.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-09-22[POWERPC] mpc5200: Add cuimage support for mpc5200 boardsGrant Likely
Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Acked-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-09-22[POWERPC] Add Marvell mv64x60 udbg putc/getc functionsDale Farnsworth
Commit 69331af, "Fixes and cleanups for earlyprintk aka boot console", resulted in printk output prior to the initialization of the mpsc console driver not being printed. That commit causes the mpsc's CON_PRINTBUFFER flag to be cleared since udbg should have printed the previous output. I guess we can no longer ignore udbg. :) This patch provides udbg_putc() and udbg_getc() functions for the Marvell mv64x60 chips. These functions are enabled if an mv64x60 port is to be used as the console as determined from the device tree. Signed-off-by: Dale Farnsworth <dale@farnsworth.org> Acked-by: Mark A. Greer <mgreer@mvista.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-09-20Merge branch 'linux-2.6'Paul Mackerras
2007-09-19[POWERPC] spusched: Fix null pointer dereference in find_victimChristoph Hellwig
find_victim can dereference a NULL pointer when iterating over the list of victim spus because list_mutex only guarantees spu->ct to be stable, but of course not to be non-NULL. Also fix find_victim to not call spu_unbind_context without list_mutex because that violates the above guarantee. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Arnd Bergmann <arnd.bergmann@de.ibm.com> Signed-off-by: Jeremy Kerr <jk@ozlabs.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-09-19[POWERPC] Fix section mismatch in PCI codeStephen Rothwell
Create a helper function (alloc_maybe_bootmem) that is marked __init_refok to limit the chances of mistakenly referring to other __init routines. WARNING: vmlinux.o(.text+0x2a9c4): Section mismatch: reference to .init.text:.__alloc_bootmem (between '.update_dn_pci_info' and '.pci_dn_reconfig_notifier') WARNING: vmlinux.o(.text+0x36430): Section mismatch: reference to .init.text:.__alloc_bootmem (between '.mpic_msi_init_allocator' and '.find_ht_magic_addr') WARNING: vmlinux.o(.text+0x5e804): Section mismatch: reference to .init.text:.__alloc_bootmem (between '.celleb_setup_phb' and '.celleb_fake_pci_write_config') WARNING: vmlinux.o(.text+0x5e8e8): Section mismatch: reference to .init.text:.__alloc_bootmem (between '.celleb_setup_phb' and '.celleb_fake_pci_write_config') WARNING: vmlinux.o(.text+0x5e968): Section mismatch: reference to .init.text:.__alloc_bootmem (between '.celleb_setup_phb' and '.celleb_fake_pci_write_config') Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-09-19[POWERPC] MPC5200 low power modeDomen Puncer
Low-power mode implementation for Lite5200b. Some I/O registers are also saved here. A recent U-Boot that supports this (lite5200b_PM_config) is needed. Signed-off-by: Domen Puncer <domen.puncer@telargo.com> Signed-off-by: Sylvain Munaut <tnt@246tNt.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-09-19[POWERPC] spufs: Add DEFINE_SPUFS_ATTRIBUTE()Michael Ellerman
This patch adds DEFINE_SPUFS_ATTRIBUTE(), a wrapper around DEFINE_SIMPLE_ATTRIBUTE which does the specified locking for the get routine for us. Unfortunately we need two get routines (a locked and unlocked version) to support the coredump code. This hides one of those (the locked version) inside the macro foo. Signed-off-by: Michael Ellerman <michael@ellerman.id.au> Signed-off-by: Jeremy Kerr <jk@ozlabs.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-09-19[POWERPC] spufs: Respect RLIMIT_CORE in spu coredump codeMichael Ellerman
Currently the spu coredump code doesn't respect the ulimit, it should. Signed-off-by: Michael Ellerman <michael@ellerman.id.au> Signed-off-by: Jeremy Kerr <jk@ozlabs.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-09-19[POWERPC] spufs: Handle errors in SPU coredump code, and support coredump to ↵Michael Ellerman
a pipe Rework spufs_coredump_extra_notes_write() to check for and return errors. If we're coredumping to a pipe we can't trust file->f_pos, we need to maintain the foffset value passed to us. The cleanest way to do this is to have the low level write routine increment foffset when we've successfully written. Signed-off-by: Michael Ellerman <michael@ellerman.id.au> Signed-off-by: Jeremy Kerr <jk@ozlabs.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-09-19[POWERPC] spufs: Cleanup ELF coredump extra notes logicMichael Ellerman
To start with, arch_notes_size() etc. is a little too ambiguous a name for my liking, so change the function names to be more explicit. Calling through macros is ugly, especially with hidden parameters, so don't do that, call the routines directly. Use ARCH_HAVE_EXTRA_ELF_NOTES as the only flag, and based on it decide whether we want the extern declarations or the empty versions. Since we have empty routines, actually use them in the coredump code to save a few #ifdefs. We want to change the handling of foffset so that the write routine updates foffset as it goes, instead of using file->f_pos (so that writing to a pipe works). So pass foffset to the write routine, and for now just set it to file->f_pos at the end of writing. It should also be possible for the write routine to fail, so change it to return int and treat a non-zero return as failure. Signed-off-by: Michael Ellerman <michael@ellerman.id.au> Signed-off-by: Jeremy Kerr <jk@ozlabs.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-09-19[POWERPC] spufs: Combine spufs_coredump_calls with spufs_callsMichael Ellerman
Because spufs might be built as a module, we can't have other parts of the kernel calling directly into it, we need stub routines that check first if the module is loaded. Currently we have two structures which hold callbacks for these stubs, the syscalls are in spufs_calls and the coredump calls are in spufs_coredump_calls. In both cases the logic for registering/unregistering is essentially the same, so we can simplify things by combining the two. Signed-off-by: Michael Ellerman <michael@ellerman.id.au> Signed-off-by: Jeremy Kerr <jk@ozlabs.org> Acked-by: Arnd Bergmann <arnd.bergmann@de.ibm.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-09-19[POWERPC] spufs: Add contents of npc file to SPU coredumpsMichael Ellerman
Signed-off-by: Michael Ellerman <michael@ellerman.id.au> Signed-off-by: Jeremy Kerr <jk@ozlabs.org> Acked-by: Arnd Bergmann <arnd.bergmann@de.ibm.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-09-19[POWERPC] spufs: Internal __spufs_get_foo() routines should take a spu_context *Michael Ellerman
The SPUFS attribute get routines take a void * because the generic attribute code doesn't know what sort of data it's passing around. However our internal __spufs_get_foo() routines can take a spu_context * directly, which saves plonking it in and out of a void * again. Signed-off-by: Michael Ellerman <michael@ellerman.id.au> Signed-off-by: Jeremy Kerr <jk@ozlabs.org> Acked-by: Arnd Bergmann <arnd.bergmann@de.ibm.com> Signed-off-by: Paul Mackerras <paulus@samba.org>