aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sh
Commit message (Collapse)AuthorAgeFilesLines
...
| | * | | | sh: Add ap325rxa specific memory pre/post sleep codeMagnus Damm2009-10-303-1/+83
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add self-refresh handling code for the AP325RXA board. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: Move ap325rxa board code into separate directoryMagnus Damm2009-10-304-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Move the AP325RXA board code from a single board file to a separate directory. This to make it easy to add support for sdram sleep mode code. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: Add migor specific memory pre/post sleep codeMagnus Damm2009-10-303-2/+82
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add self-refresh handling code for the Migo-R board. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: Add ms7724se specific memory pre/post sleep codeMagnus Damm2009-10-303-1/+65
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add self-refresh handling code for the MS7724SE board. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: Add kfr2r09 specific memory pre/post sleep codeMagnus Damm2009-10-303-1/+66
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add self-refresh handling code for the KFR2R09 board. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: Allow boards to register memory pre/post sleep codeMagnus Damm2009-10-302-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add code to allow boards registering self-contained functions for going to/from self-refresh. At this point the board code is unused. When all supported boards have been converted then the new sleep code will make use of these functions. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: Add sh7724 notifier for R-standby save/restoreMagnus Damm2009-10-301-0/+167
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make use of the recently added notifier chains for sh7724 r-standby register save/restore handling. At this point only the BSC and INTC are handled. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: Add notifiers chains for cpu/board codeMagnus Damm2009-10-302-0/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds atomic notifier chains for pre/post sleep events. Useful for cpu code and boards that need to save and restore register state before and after entering a sleep mode. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: Do not apply virt_to_phys() to a physical addressMatt Fleming2009-10-301-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The variable 'phys' already contains the physical address to flush. It is not a virtual address and should not be passed to virt_to_phys(). Signed-off-by: Matt Fleming <matt@console-pimps.org> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: perf events: Kill off left over debugging cruft.Paul Mundt2009-10-281-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | num_events should be compared > MAX_HWEVENTS and not >=. The latter was used as a debugging test which accidentally slipped in. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: perf events: Add preliminary support for SH-4A counters.Paul Mundt2009-10-285-2/+576
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds in preliminary support for the SH-4A performance counters. Presently only the first 2 counters are supported, as these are the ones of the most interest to the perf tool and end users. Counter chaining is not presently handled, so these are simply implemented as 32-bit counters. This also establishes a perf event support framework for other hardware counters, which the existing SH-4 oprofile code will migrate over to as the SH-4A support evolves. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: mach-ecovec24: Add USB1 gadget supportKuninori Morimoto2009-10-281-21/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | USB1 can change to host/function by checking PTB3. This patch add USB1 gadget support and check PTB3 when boot, and change name to usb1_common_XXX from usb1_host_XXX. Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: add SDHI1 support to ms7724seMagnus Damm2009-10-281-0/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add support for cn8 and SDHI1 to the ms7724se board. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: mac address through private data for sh_eth on ms7724seMagnus Damm2009-10-281-10/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Convert the ms7724se board code to pass the mac address to the sh_eth driver using platform data. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | Merge branch 'sh/stable-updates'Paul Mundt2009-10-273-1/+7
| | |\ \ \ \ | | | | |_|/ | | | |/| |
| | * | | | sh: enable PERF_USE_VMALLOC across the board.Paul Mundt2009-10-271-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The vast majority of SH platforms want this, and the few that don't aren't going to care one way or the other. Enable it across the board. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: Bump up dma_ops initialization far earlier in the boot process.Paul Mundt2009-10-272-2/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Presently this was tacked on to the dma debug init bits from fs_initcall(), which is far too late for devices setting up their own per-device coherent areas. Throw this in the beginning of mem_init(), as per the x86 iommu allocation. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: Clean up more superfluous symbol exports.Paul Mundt2009-10-274-51/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Many of these symbols went away completely, or we just never cared about them in the first place. Trim the exports down to the essential set. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh64: cache flush symbol exports.Paul Mundt2009-10-272-11/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These were previously hidden in sh_ksyms_32, despite also being needed for sh64 now that the cache.c code is shared. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: Fix up dma_is_consistent().Paul Mundt2009-10-271-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes up the dma_is_consistent() definition for the various coherence options. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: Kill off superfluous arch/sh/drivers/pci/Kconfig.Paul Mundt2009-10-272-8/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that this contains a grand total of 1 Kconfig option, it's hardly worth keeping split out. Roll CONFIG_PCI back in to the top-level architecture Kconfig, along with the other bus types. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: Revamp PCI DMA coherence Kconfig bits.Paul Mundt2009-10-274-25/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Leaving this configurable caused more trouble than it was ever worth, so just make it explicit. Boards that are verified one way or the other can fix up their selects accordingly. We presently default to non-coherent for most platforms. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: Annotate irq functions with "notrace"Matt Fleming2009-10-272-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that SH's irqflags functions are out of line it becomes necessary to mark them as "notrace" so that we don't try to trace them. [ Do the same for irq_64.c -- PFM. ] Signed-off-by: Matt Fleming <matt@console-pimps.org> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: fix watchdog timer for sh7780/sh7785Valentin R Sitsikov2009-10-272-1/+71
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Valentin Sitdikov <valentin.sitdikov@siemens.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: mac address through private data for sh_eth on ecovec24Magnus Damm2009-10-261-29/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Convert the ecovec24 board code to pass the mac address to the sh_eth driver using platform data. Also, remove the static clock to allow Runtime PM. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | sh: add hwblk_id to sh_eth on ecovec24Magnus Damm2009-10-261-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add HWBLK_ETHER to the sh_eth platform device to allow Runtime PM of the ethernet hardware. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | Merge branch 'sh/stable-updates'Paul Mundt2009-10-264-15/+20
| | |\ \ \ \
| | * | | | | sh: fix kexec by removing check for old kexec-toolsMagnus Damm2009-10-261-6/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This unbreaks kexec support. Without this fix all cases of kexec fails since __pa() does not behave like PHYSADDR(). The downside is that we also kill the code blocking users running old kexec-tools. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | | Merge branch 'sh/stable-updates'Paul Mundt2009-10-263-1/+38
| | |\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: arch/sh/kernel/dwarf.c
| | * \ \ \ \ \ Merge branch 'sh/sdhi-mfd'Paul Mundt2009-10-265-49/+200
| | |\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: arch/sh/boards/mach-ecovec24/setup.c arch/sh/boards/mach-kfr2r09/setup.c
| | | * | | | | | sh: mach-ecevec24: Add SDHI supportKuninori Morimoto2009-10-261-0/+78
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | | * | | | | | sh: SDHI platform data to the kfr2r09 boardMagnus Damm2009-10-261-0/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add SD Card support to the kfr2r09 board using the sh_mobile_sdhi driver hooked up to SDHI0 and yc304. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | | * | | | | | sh: SDHI platform data to the SE7724 boardMagnus Damm2009-10-261-0/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add SD Card support to the se7724 board using the sh_mobile_sdhi driver hooked up to SDHI0 and CN7. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | | * | | | | | sh: SDHI platform data to the AP325RXA boardMagnus Damm2009-10-261-24/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Convert the AP325 board to use sh_mobile_sdhi for the SD Card connected to CN3 instead of mmc_spi. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | | * | | | | | sh: SDHI platform data to the Migo-R boardMagnus Damm2009-10-261-24/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Convert the Migo-R board to use sh_mobile_sdhi for the SD Card connected to CN9 instead of mmc_spi. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | | | | sh: Add dma-mapping support for dma_alloc/free_coherent() overrides.Paul Mundt2009-10-263-25/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This moves the current dma_alloc/free_coherent() calls to a generic variant and plugs them in for the nommu default. Other variants can override the defaults in the dma mapping ops directly. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | | | | sh: Convert to asm-generic/dma-mapping-common.hPaul Mundt2009-10-206-184/+112
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This converts the old DMA mapping support to the new generic dma-mapping-common.h abstraction. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | | | | sh: Fix up cacheflush routine symbol exports.Paul Mundt2009-10-191-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes up flush_dcache_page() references by modules with run-time cache disabling. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | | | | sh: Fix up uninitialized variable warning in dwarf unwinder.Paul Mundt2009-10-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | | | | sh: Fix up smp_mb__xxx() memory barriers for SH-4A SMP.Paul Mundt2009-10-182-7/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In the past these were simply wrapping to barrier() which was sufficient on SH SMP platforms predating SH-4A. Unfortunately due to ll/sc semantics an explicit synco is needed in these cases, which is sorted for us by just switching these over to smp_mb(). smp_mb() also has the benefit of being wrapped to barrier() in the UP and non-SH4A cases, so old behaviour is maintained for those parts. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | | | | sh: Disable SCIF2 on the SH-X3 proto CPU.Paul Mundt2009-10-183-46/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | SCIF2 and the FPU exceptions happen to share vector numbers, one in EXPEVT and the other in INTEVT. This is a violation of the interface and should have never made it in to silicon. On top of that, the demux hack that was added for special dispatch is rather error prone, and introduces more problems than it solves. Kill all of it off, and just refuse to deal with SCIF2 outright. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | | | | sh: Convert to asm-generic/irqflags.h.Paul Mundt2009-10-178-214/+168
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This simplifies the irqflags support by switching over to the asm-generic version. The necessary support functions are brought out-of-line for both SHcompact and SHmedia instruction sets. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | | | | sh: Kill off legacy UBC wakeup cruft.Paul Mundt2009-10-165-93/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This code was added for some ancient SH-4 solution engines with peculiar boot ROMs that did silly things to the UBC MSTP bits. None of these have been in the wild for years, and these days the clock framework wraps up the MSTP bits, meaning that the UBC code is one of the few interfaces that is stomping MSTP bits underneath the clock framework. At this point the risks far outweigh any benefit this code provided, so just kill it off. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | | | | Merge branch 'sh/stable-updates'Paul Mundt2009-10-161-1/+0
| | |\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: arch/sh/Kconfig
| | * | | | | | | | sh: Support SCHED_MC for SH-X3 multi-cores.Paul Mundt2009-10-163-0/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This enables SCHED_MC support for SH-X3 multi-cores. Presently this is just a simple wrapper around the possible map, but this allows for tying in support for some of the more exotic NUMA clusters where we can actually do something with the topology. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | | | | | sh: Fix up IRQ re-enabling for the need_resched() case.Paul Mundt2009-10-161-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In the case where need_resched() is set in between the cpu_idle() and pm_idle() calls we were missing an else case for just re-enabling local IRQs and bailing out. This was noticed by the irqs_disabled() warning, even though IRQs were being re-enabled elsewhere. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | | | | | sh: Make check_pgt_cache() more aggressive while idling.Paul Mundt2009-10-161-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This follows the x86 change and moves check_pgt_cache() up under the !need_resched() tight loop, rather than simply calling in to it when exiting idle. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | | | | | sh: Idle loop chainsawing for SMP-based light sleep.Paul Mundt2009-10-162-16/+61
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This does a bit of chainsawing of the idle loop code to get light sleep working on SMP. Previously this was forcing secondary CPUs in to sleep mode with them not coming back if they didn't have their own local timers. Given that we use clockevents broadcasting by default, the CPU managing the clockevents can't have IRQs disabled before entering its sleep state. This unfortunately leaves us with the age-old need_resched() race in between local_irq_enable() and cpu_sleep(), but at present this is unavoidable. After some more experimentation it may be possible to layer on SR.BL bit manipulation over top of this scheme to inhibit the race condition, but given the current potential for missing wakeups, this is left as a future exercise. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | | | | | sh: Force boot CPU in to light sleep mode for SH-X3 SMP.Paul Mundt2009-10-161-18/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | All of the secondary CPUs are forced in to light sleep mode, but we were missing the same initialization for the boot CPU. This resulted in inconsistent sleep modes depending on which CPU we were on, confusing the idle loop when not polling. Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| | * | | | | | | | Merge branch 'sh/stable-updates'Paul Mundt2009-10-163-20/+26
| | |\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: arch/sh/mm/cache-sh4.c