linux/arch/arm
Simon Horman f45b114991 ARM: 6617/1: mmc, Add zboot from MMC support for SuperH Mobile ARM
This allows a ROM-able zImage to be written to MMC and
for SuperH Mobile ARM to boot directly from the MMCIF
hardware block.

This is achieved by the MaskROM loading the first portion
of the image into MERAM and then jumping to it. This portion
contains loader code which copies the entire image to SDRAM
and jumps to it. From there the zImage boot code proceeds
as normal, uncompressing the image into its final location
and then jumping to it.

Cc: Magnus Damm <magnus.damm@gmail.com>

Russell, please consider merging this for 2.6.38.

This patch depends on:
* "mmc, sh: Move MMCIF_PROGRESS_* into sh_mmcif.h"
  which will be merged though Paul Mundt's rmobile sh-2.6.
  The absence of this patch will break the build if
  the (new) CONFIG_ZBOOT_ROM_MMCIF option is set.
  There are no subtle side-effects.

v2:
Addressed comments by Magnus Damm
* Fix copyright in vrl4.c
* Fix use of #define CONFIG_ZBOOT_ROM_MMCIF in mmcif-sh7372.c
* Initialise LED GPIO lines in head-ap4evb.txt instead of mmcif-sh7372.c
  as this is considered board-specific.

v3:
Addressed comments made in person by Magnus Damm
* Move mmcif_loader to be earlier in the image and
  reduce the number of blocks of boot program loaded by the MaskRom
  from 40 to 8 accordingly.
* Move LED GPIO initialisation into mmcif_progress_init
  - This leaves the partner jet script unbloated
Other
* inline mmcif_update_progress so it is a static inline in a header file

v4:
* Use htole16() and htole32() in v4rl.c to ensure
  that the output is little endian

v5:
Addressed comments by Russell King
* Simplify assembly code
* Jump to code rather than an address <- bug fix
* Use (void __iomem *) as appropriate
Roll in mackerel support
* This was previously a separate patch, only because of the order
  in which this code was developed
Signed-off-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2011-01-25 15:06:52 +00:00
..
boot ARM: 6617/1: mmc, Add zboot from MMC support for SuperH Mobile ARM 2011-01-25 15:06:52 +00:00
common Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
configs kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT 2011-01-20 17:02:05 -08:00
include/asm Merge branch 'fixes' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:29:50 -08:00
kernel Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
lib ARM: udelay: prevent math rounding resulting in short udelays 2011-01-10 23:55:59 +00:00
mach-aaec2000 ARM: aaec2000: irq_data conversion. 2011-01-13 17:18:21 +01:00
mach-at91 Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-bcmring Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-clps711x ARM: clps711x: irq_data conversion. 2011-01-13 17:18:24 +01:00
mach-cns3xxx Merge branch 'devel-stable' into devel 2011-01-06 22:33:32 +00:00
mach-davinci Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-dove ARM: dove: irq_data conversion. 2011-01-13 17:18:27 +01:00
mach-ebsa110 ARM: ebsa110: irq_data conversion. 2011-01-13 17:18:28 +01:00
mach-ep93xx ARM: ep93xx: irq_data conversion. 2011-01-13 17:18:29 +01:00
mach-footbridge ARM: footbridge: irq_data conversion. 2011-01-13 17:18:30 +01:00
mach-gemini Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-h720x Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-imx Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-integrator Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-iop13xx ARM: iop13xx: irq_data conversion. 2011-01-13 17:18:35 +01:00
mach-iop32x ARM: iop32x: irq_data conversion. 2011-01-13 17:18:36 +01:00
mach-iop33x ARM: iop33x: irq_data conversion. 2011-01-13 17:18:37 +01:00
mach-ixp4xx ARM: ixp4xx: irq_data conversion. 2011-01-13 17:18:40 +01:00
mach-ixp23xx ARM: ixp23xx: irq_data conversion. 2011-01-13 17:18:39 +01:00
mach-ixp2000 ARM: ixp2000: irq_data conversion. 2011-01-13 17:18:38 +01:00
mach-kirkwood Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6 2011-01-13 10:32:54 -08:00
mach-ks8695 ARM: ks8695: irq_data conversion. 2011-01-13 17:18:41 +01:00
mach-l7200/include/mach arm: return both physical and virtual addresses from addruart 2010-10-20 00:27:33 -04:00
mach-lh7a40x ARM: lh7a40x: irq_data conversion. 2011-01-13 17:18:43 +01:00
mach-loki arm: remove machine_desc.io_pg_offst and .phys_io 2010-10-20 00:27:46 -04:00
mach-lpc32xx Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-mmp ARM: mmp: PXA910 drive strength FAST using wrong value 2011-01-15 04:29:20 -06:00
mach-msm Merge branch 'for-38-rc2' of git://codeaurora.org/quic/kernel/davidb/linux-msm 2011-01-20 16:30:22 -08:00
mach-mv78xx0 [ARM] mv78xx: wrong cpu1 window base register address 2010-11-29 10:42:05 -05:00
mach-mx3 Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-mx5 Merge branch 'for-rmk' of git://git.pengutronix.de/git/imx/linux-2.6 into devel-stable 2011-01-14 12:12:42 +00:00
mach-mxc91231 Merge branch 'devel-stable' into devel 2011-01-06 22:33:32 +00:00
mach-mxs ARM mxs: clkdev related compile fixes 2011-01-14 10:19:27 +01:00
mach-netx ARM: netx: irq_data conversion. 2011-01-13 17:18:48 +01:00
mach-nomadik ARM: 6483/1: arm & sh: factorised duplicated clkdev.c 2010-11-26 10:51:04 +00:00
mach-ns9xxx ARM: ns9xxx: irq_data conversion. 2011-01-13 17:18:49 +01:00
mach-nuc93x ARM: nuc93x: irq_data conversion. 2011-01-13 17:18:50 +01:00
mach-omap1 Merge git://git.infradead.org/mtd-2.6 2011-01-17 11:15:30 -08:00
mach-omap2 Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-orion5x Merge branch 'devel-stable' into devel 2011-01-06 22:33:32 +00:00
mach-pnx4008 Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-pxa Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-realview Merge branch 'misc' into devel 2011-01-06 22:32:52 +00:00
mach-rpc ARM: rpc: irq_data conversion. 2011-01-13 17:18:57 +01:00
mach-s3c24a0/include/mach Merge branch 'for-rmk' of git://git.kernel.org/pub/scm/linux/kernel/git/kgene/linux-samsung into devel-stable 2010-10-28 12:27:34 +01:00
mach-s3c64xx Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-s3c2400
mach-s3c2410 Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-s3c2412 Merge branch 'for-rmk' of git://git.kernel.org/pub/scm/linux/kernel/git/kgene/linux-samsung into devel-stable 2011-01-15 13:24:02 +00:00
mach-s3c2416 Merge branch 'next-s3c24xx' into for-next 2011-01-06 18:44:09 +09:00
mach-s3c2440 Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-s3c2443 Merge branch 'next-s3c24xx' into for-next 2011-01-06 18:44:09 +09:00
mach-s5p64x0 ARM: S5P6450: Add missing virtual ASoC DMA device 2011-01-18 14:44:32 +09:00
mach-s5p6442 ARM: S5P6442: Enable I2S device to work on SMDK6442 2011-01-18 14:44:32 +09:00
mach-s5pc100 Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-s5pv210 ARM: S5PV210: Add missing virtual ASoC DMA device 2011-01-18 14:45:33 +09:00
mach-s5pv310 ARM: S5PV310: Add missing virtual ASoC DMA device 2011-01-18 14:47:07 +09:00
mach-sa1100 Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-shark ARM: shark: irq_data conversion. 2011-01-13 17:19:00 +01:00
mach-shmobile ARM: 6617/1: mmc, Add zboot from MMC support for SuperH Mobile ARM 2011-01-25 15:06:52 +00:00
mach-spear3xx tree-wide: fix comment/printk typos 2010-11-01 15:38:34 -04:00
mach-spear6xx tree-wide: fix comment/printk typos 2010-11-01 15:38:34 -04:00
mach-stmp37xx ARM: stmp37xx: irq_data conversion. 2011-01-13 17:19:02 +01:00
mach-stmp378x ARM: stmp378x: irq_data conversion. 2011-01-13 17:19:01 +01:00
mach-tcc8k ARM: tcc8k: irq_data conversion. 2011-01-13 17:19:03 +01:00
mach-tegra Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
mach-u300 Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2011-01-13 10:05:56 -08:00
mach-ux500 mach-ux500: Updated and connected ab8500 regulator board configuration 2011-01-12 14:33:03 +00:00
mach-versatile ARM: versatile: irq_data conversion. 2011-01-13 17:19:06 +01:00
mach-vexpress Merge branch 'misc' into devel 2011-01-06 22:32:52 +00:00
mach-w90x900 ARM: w90x900: irq_data conversion. 2011-01-13 17:19:07 +01:00
mm Merge branch 'fixes' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:29:50 -08:00
nwfpe Update broken web addresses in arch directory. 2010-10-18 11:03:21 +02:00
oprofile oprofile: Abstract the perf-events backend 2010-10-11 17:46:16 +02:00
plat-iop Merge branch 'clksrc' into devel 2011-01-05 18:09:03 +00:00
plat-mxc Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
plat-nomadik Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/djbw/async_tx 2011-01-17 10:54:41 -08:00
plat-omap Merge git://git.infradead.org/mtd-2.6 2011-01-17 11:15:30 -08:00
plat-orion ARM: plat-orion: irq_data conversion. 2011-01-13 17:19:12 +01:00
plat-pxa ARM: PXA SoCs: irq_data conversion. 2011-01-13 17:18:56 +01:00
plat-s3c24xx Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
plat-s5p ARM: S5P: Add Support System MMU 2011-01-13 13:35:31 +09:00
plat-samsung Merge branch 'devel-stable' of master.kernel.org:/home/rmk/linux-2.6-arm 2011-01-15 12:33:40 -08:00
plat-spear ARM: plat-spear: irq_data conversion. 2011-01-13 17:19:13 +01:00
plat-stmp3xxx ARM: plat-stmp3xxx: irq_data conversion. 2011-01-13 17:19:14 +01:00
plat-tcc arm: return both physical and virtual addresses from addruart 2010-10-20 00:27:33 -04:00
plat-versatile Merge branch 'clksrc' into devel 2011-01-05 18:09:03 +00:00
tools ARM: Update mach-types 2010-12-12 23:31:02 +00:00
vfp Merge branch 'misc' into devel 2011-01-06 22:32:52 +00:00
Kconfig ARM: 6617/1: mmc, Add zboot from MMC support for SuperH Mobile ARM 2011-01-25 15:06:52 +00:00
Kconfig-nommu
Kconfig.debug Merge branch 'misc' into devel 2011-01-06 22:32:52 +00:00
Makefile Merge branch 'sgu/mxs-core-v8' of git://git.pengutronix.de/git/ukl/linux-2.6 into imx-for-2.6.38-new 2011-01-03 10:15:11 +01:00