summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames Buren <braewoods+rb@braewoods.net>2020-10-26 00:56:50 +0000
committerSolomon Peachy <pizza@shaftnet.org>2020-10-26 01:07:14 +0000
commitbde72efa30218d6467f07cd0b0a223899484d640 (patch)
tree447494f132241370c146dadd8c4c1f937acb57a5
parent129001909d36161b4850142f29eeafc295b92a3e (diff)
downloadrockbox-bde72efa30.tar.gz
rockbox-bde72efa30.tar.bz2
rockbox-bde72efa30.zip
coldfire: make the RAM and ROM image locations configurable by macros
Change-Id: Ie27e39c34947b0391be621dafb8711c44e863a1c
-rw-r--r--firmware/export/config/iaudiom3.h3
-rw-r--r--firmware/export/config/iaudiom5.h3
-rw-r--r--firmware/export/config/iaudiox5.h3
-rw-r--r--firmware/export/config/mpiohd200.h3
-rw-r--r--firmware/export/config/mpiohd300.h3
-rw-r--r--firmware/target/coldfire/crt0.S10
6 files changed, 15 insertions, 10 deletions
diff --git a/firmware/export/config/iaudiom3.h b/firmware/export/config/iaudiom3.h
index 1ed31b4d46..cfac0d7253 100644
--- a/firmware/export/config/iaudiom3.h
+++ b/firmware/export/config/iaudiom3.h
@@ -158,7 +158,8 @@
#define BOOTDIR "/.rockbox"
#define BOOTLOADER_ENTRYPOINT 0x001F0000
-#define FLASH_ENTRYPOINT 0x00001000
+#define FLASH_RAMIMAGE_ENTRY 0x00001000
+#define FLASH_ROMIMAGE_ENTRY 0x00100000
#define FLASH_MAGIC 0xfbfbfbf1
/* Define this for FM radio input available */
diff --git a/firmware/export/config/iaudiom5.h b/firmware/export/config/iaudiom5.h
index a90b0f061b..e7b46868b7 100644
--- a/firmware/export/config/iaudiom5.h
+++ b/firmware/export/config/iaudiom5.h
@@ -179,7 +179,8 @@
#define BOOTDIR "/.rockbox"
#define BOOTLOADER_ENTRYPOINT 0x001F0000
-#define FLASH_ENTRYPOINT 0x00001000
+#define FLASH_RAMIMAGE_ENTRY 0x00001000
+#define FLASH_ROMIMAGE_ENTRY 0x00100000
#define FLASH_MAGIC 0xfbfbfbf1
/** Port-specific settings **/
diff --git a/firmware/export/config/iaudiox5.h b/firmware/export/config/iaudiox5.h
index fc97f71813..0164cd20fa 100644
--- a/firmware/export/config/iaudiox5.h
+++ b/firmware/export/config/iaudiox5.h
@@ -190,7 +190,8 @@
#define BOOTDIR "/.rockbox"
#define BOOTLOADER_ENTRYPOINT 0x001F0000
-#define FLASH_ENTRYPOINT 0x00001000
+#define FLASH_RAMIMAGE_ENTRY 0x00001000
+#define FLASH_ROMIMAGE_ENTRY 0x00100000
#define FLASH_MAGIC 0xfbfbfbf1
/* Define this for FM radio input available */
diff --git a/firmware/export/config/mpiohd200.h b/firmware/export/config/mpiohd200.h
index 1d367e4b20..a770183946 100644
--- a/firmware/export/config/mpiohd200.h
+++ b/firmware/export/config/mpiohd200.h
@@ -169,7 +169,8 @@
#define BOOTDIR "/.rockbox"
#define BOOTLOADER_ENTRYPOINT 0x001F0000
-#define FLASH_ENTRYPOINT 0x00001000
+#define FLASH_RAMIMAGE_ENTRY 0x00001000
+#define FLASH_ROMIMAGE_ENTRY 0x00100000
#define FLASH_MAGIC 0xfbfbfbf1
#endif /* SIMULATOR */
diff --git a/firmware/export/config/mpiohd300.h b/firmware/export/config/mpiohd300.h
index fe17ec16b5..d5b2948cec 100644
--- a/firmware/export/config/mpiohd300.h
+++ b/firmware/export/config/mpiohd300.h
@@ -172,7 +172,8 @@
#define BOOTDIR "/.rockbox"
#define BOOTLOADER_ENTRYPOINT 0x001F0000
-#define FLASH_ENTRYPOINT 0x00001000
+#define FLASH_RAMIMAGE_ENTRY 0x00001000
+#define FLASH_ROMIMAGE_ENTRY 0x00100000
#define FLASH_MAGIC 0xfbfbfbf1
#endif /* SIMULATOR */
diff --git a/firmware/target/coldfire/crt0.S b/firmware/target/coldfire/crt0.S
index 34492ec853..7ea4c49dca 100644
--- a/firmware/target/coldfire/crt0.S
+++ b/firmware/target/coldfire/crt0.S
@@ -151,14 +151,14 @@ start:
#ifdef BOOTLOADER
/* Check if we have a Rockbox ROM image */
- lea 0x00100000,%a2
+ lea FLASH_ROMIMAGE_ENTRY,%a2
move.l (%a2),%d0
move.l #FLASH_MAGIC,%d1
cmp.l %d0,%d1
beq.b .imagefound
/* Check for RAM image */
- lea 0x00001000,%a2
+ lea FLASH_RAMIMAGE_ENTRY,%a2
move.l (%a2),%d0
move.l #FLASH_MAGIC,%d1
cmp.l %d0,%d1
@@ -244,7 +244,7 @@ start:
/* Check if we have a Rockbox ROM image. For RAM image only cookie is
not set at all. But we could support also RAM images loading. */
- lea 0x00100000,%a2
+ lea FLASH_ROMIMAGE_ENTRY,%a2
move.l (%a2),%d0
move.l #FLASH_MAGIC,%d1
cmp.l %d0,%d1
@@ -261,9 +261,9 @@ start:
Clear the cookie and load the ROM image */
lea 0x10017ffc,%a2
clr.l (%a2)
- lea 0x00100028+4,%a2
+ lea FLASH_ROMIMAGE_ENTRY+44,%a2
move.l (%a2),%sp
- lea 0x00100028+8,%a2
+ lea FLASH_ROMIMAGE_ENTRY+48,%a2
move.l (%a2),%d0
move.l %d0,%a2
jmp (%a2)