diff mbox

[Branch,~linaro-maintainers/linaro-image-tools/trunk] Rev 300: Merge lp:~lool/linaro-image-tools/efikasb-support; adds support for EfikaMX

Message ID 20110318134118.23165.82678.launchpad@loganberry.canonical.com
State Accepted
Headers show

Commit Message

Loïc Minier March 18, 2011, 1:41 p.m. UTC
Merge authors:
  Loïc Minier (lool)
Related merge proposals:
  https://code.launchpad.net/~lool/linaro-image-tools/efikasb-support/+merge/53864
  proposed by: Loïc Minier (lool)
  review: Approve - Guilherme Salgado (salgado)
------------------------------------------------------------
revno: 300 [merge]
committer: Loïc Minier <lool@dooz.org>
branch nick: linaro-image-tools
timestamp: Fri 2011-03-18 14:37:32 +0100
message:
  Merge lp:~lool/linaro-image-tools/efikasb-support; adds support for EfikaMX
  SmartBook and cleans up i.MX5x support.
modified:
  linaro_media_create/boards.py
  linaro_media_create/tests/test_media_create.py


--
lp:linaro-image-tools
https://code.launchpad.net/~linaro-maintainers/linaro-image-tools/trunk

You are subscribed to branch lp:linaro-image-tools.
To unsubscribe from this branch go to https://code.launchpad.net/~linaro-maintainers/linaro-image-tools/trunk/+edit-subscription
diff mbox

Patch

=== modified file 'linaro_media_create/boards.py'
--- linaro_media_create/boards.py	2011-03-10 23:28:21 +0000
+++ linaro_media_create/boards.py	2011-03-17 17:48:49 +0000
@@ -57,10 +57,11 @@ 
     """Round value to the next multiple of align."""
     return (value + align - 1) / align * align
 
-# optional bootloader partition; at least 1 MiB; in theory, an i.MX5 bootloader
-# partition could hold RedBoot, FIS table, RedBoot config, kernel, and initrd,
-# but we typically use U-Boot which is about 167 KiB as of 2011/02/11 and
-# currently doesn't even store its environment there, so this should be enough
+# optional bootloader partition; at least 1 MiB; in theory, an i.MX5x
+# bootloader partition could hold RedBoot, FIS table, RedBoot config, kernel,
+# and initrd, but we typically use U-Boot which is about 167 KiB as of
+# 2011/02/11 and currently doesn't even store its environment there, so this
+# should be enough
 LOADER_MIN_SIZE_S = align_up(1 * 1024 * 1024, SECTOR_SIZE) / SECTOR_SIZE
 # boot partition; at least 50 MiB; XXX this shouldn't be hardcoded
 BOOT_MIN_SIZE_S = align_up(50 * 1024 * 1024, SECTOR_SIZE) / SECTOR_SIZE
@@ -417,10 +418,6 @@ 
     serial_tty = 'ttymxc0'
     extra_serial_opts = 'console=tty0 console=%s,115200n8' % serial_tty
     live_serial_opts = 'serialtty=%s' % serial_tty
-    kernel_addr = '0x90000000'
-    initrd_addr = '0x90800000'
-    load_addr = '0x90008000'
-    kernel_suffix = 'linaro-mx51'
     boot_script = 'boot.scr'
     mmc_part_offset = 1
     mmc_option = '0:2'
@@ -465,22 +462,36 @@ 
         make_boot_script(boot_env, boot_script)
 
 
-class EfikamxConfig(Mx5Config):
-    uboot_flavor = 'efikamx'
-
-
-class Mx51evkConfig(Mx5Config):
-    uboot_flavor = 'mx51evk'
-
-
-class Mx53LoCoConfig(Mx5Config):
-    uboot_flavor = 'mx53loco'
+class Mx51Config(Mx5Config):
+    kernel_addr = '0x90000000'
+    initrd_addr = '0x90800000'
+    load_addr = '0x90008000'
+    kernel_suffix = 'linaro-mx51'
+
+
+class Mx53Config(Mx5Config):
     kernel_addr = '0x70800000'
     initrd_addr = '0x71800000'
     load_addr = '0x70008000'
     kernel_suffix = 'linaro-lt-mx53'
 
 
+class EfikamxConfig(Mx51Config):
+    uboot_flavor = 'efikamx'
+
+
+class EfikasbConfig(Mx51Config):
+    uboot_flavor = 'efikasb'
+
+
+class Mx51evkConfig(Mx51Config):
+    uboot_flavor = 'mx51evk'
+
+
+class Mx53LoCoConfig(Mx53Config):
+    uboot_flavor = 'mx53loco'
+
+
 class VexpressConfig(BoardConfig):
     uboot_flavor = 'ca9x4_ct_vxp'
     uboot_in_boot_part = True
@@ -589,6 +600,7 @@ 
     'vexpress': VexpressConfig,
     'ux500': Ux500Config,
     'efikamx': EfikamxConfig,
+    'efikasb': EfikasbConfig,
     'mx51evk': Mx51evkConfig,
     'mx53loco' : Mx53LoCoConfig,
     'overo': OveroConfig,

=== modified file 'linaro_media_create/tests/test_media_create.py'
--- linaro_media_create/tests/test_media_create.py	2011-03-17 18:30:07 +0000
+++ linaro_media_create/tests/test_media_create.py	2011-03-18 13:37:32 +0000
@@ -261,7 +261,9 @@ 
         self.assertEqual(expected, self.funcs_calls)
 
     def test_mx5_steps(self):
-        self.make_boot_files(boards.Mx51evkConfig)
+        class SomeMx5Config(boards.Mx5Config):
+            uboot_flavor = 'uboot_flavor'
+        self.make_boot_files(SomeMx5Config)
         expected = [
             'install_mx5_boot_loader', 'make_uImage', 'make_uInitrd',
             'make_boot_script']
@@ -418,8 +420,8 @@ 
                        'bootm 0x60008000 0x81000000'}
         self.assertEqual(expected, boot_commands)
 
-    def test_mx5(self):
-        boot_commands = boards.Mx5Config._get_boot_env(
+    def test_mx51(self):
+        boot_commands = boards.Mx51Config._get_boot_env(
             is_live=False, is_lowmem=False, consoles=[],
             rootfs_uuid="deadbeef")
         expected = {