]> git.proxmox.com Git - grub2.git/commitdiff
Fix MIPS compilation.
authorVladimir 'phcoder' Serbinenko <phcoder@gmail.com>
Sat, 12 Nov 2011 20:38:04 +0000 (21:38 +0100)
committerVladimir 'phcoder' Serbinenko <phcoder@gmail.com>
Sat, 12 Nov 2011 20:38:04 +0000 (21:38 +0100)
* grub-core/boot/mips/startup_raw.S: Use GRUB_DECOMPRESSOR_*
* include/grub/offsets.h: Rename decompressor fields from
GRUB_KERNEL_* to GRUB_DECOMPRESSOR_*.
* util/grub-mkimage.c (image_targets): Use new names.

ChangeLog
grub-core/boot/mips/startup_raw.S
include/grub/offsets.h
util/grub-mkimage.c

index b5124c18adafdca2c5990704cf5302f639321a82..15389a335e398a8fe46be182bb795dc54335be7a 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2011-11-12  Vladimir Serbinenko  <phcoder@gmail.com>
+
+       Fix MIPS compilation.
+
+       * grub-core/boot/mips/startup_raw.S: Use GRUB_DECOMPRESSOR_*
+       * include/grub/offsets.h: Rename decompressor fields from
+       GRUB_KERNEL_* to GRUB_DECOMPRESSOR_*.
+       * util/grub-mkimage.c (image_targets): Use new names.
+
 2011-11-12  Vladimir Serbinenko  <phcoder@gmail.com>
 
        Defer multiboot device parsing until we're in compressed part.
index e769266777acc84975ccb240776c68e0bad2dc4d..bbbc1dbece5001aee386f8d89f5fd3265979b5d0 100644 (file)
@@ -240,9 +240,9 @@ cmdlinedone:
        subu $a0, $a0, $t0
        addu $a0, $a0, $s0
 
-       lw $a1, (GRUB_KERNEL_MACHINE_UNCOMPRESSED_ADDR - BASE_ADDR)($s0)
-       lw $a2, (GRUB_KERNEL_MACHINE_COMPRESSED_SIZE - BASE_ADDR)($s0)
-       lw $a3, (GRUB_KERNEL_MACHINE_UNCOMPRESSED_SIZE - BASE_ADDR)($s0)
+       lw $a1, (GRUB_DECOMPRESSOR_MACHINE_UNCOMPRESSED_ADDR - BASE_ADDR)($s0)
+       lw $a2, (GRUB_DECOMPRESSOR_MACHINE_COMPRESSED_SIZE - BASE_ADDR)($s0)
+       lw $a3, (GRUB_DECOMPRESSOR_MACHINE_UNCOMPRESSED_SIZE - BASE_ADDR)($s0)
        move $s1, $a1
 
        /* $a0 contains source compressed address, $a1 is destination,
index 1269c865d115982c7d13e96b9261e1d3eff2df02..68ed084cbfe6c77a2f34e93a3a2aa01625d223c0 100644 (file)
 
 #define GRUB_KERNEL_MIPS_LOONGSON_LINK_ALIGN  32
 
-#define GRUB_KERNEL_MIPS_LOONGSON_COMPRESSED_SIZE          0x8
-#define GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_SIZE        0xc
-#define GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_ADDR        0x10
+#define GRUB_DECOMPRESSOR_MIPS_LOONGSON_COMPRESSED_SIZE          0x8
+#define GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_SIZE        0xc
+#define GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_ADDR        0x10
 
 #define GRUB_KERNEL_MIPS_LOONGSON_TOTAL_MODULE_SIZE    0x08
 
 #define GRUB_KERNEL_MIPS_QEMU_MIPS_LINK_ADDR         0x80200000
 #define GRUB_KERNEL_MIPS_QEMU_MIPS_LINK_ALIGN  32
-#define GRUB_KERNEL_MIPS_QEMU_MIPS_COMPRESSED_SIZE          0x8
-#define GRUB_KERNEL_MIPS_QEMU_MIPS_UNCOMPRESSED_SIZE        0xc
-#define GRUB_KERNEL_MIPS_QEMU_MIPS_UNCOMPRESSED_ADDR        0x10
+#define GRUB_DECOMPRESSOR_MIPS_QEMU_MIPS_COMPRESSED_SIZE          0x8
+#define GRUB_DECOMPRESSOR_MIPS_QEMU_MIPS_UNCOMPRESSED_SIZE        0xc
+#define GRUB_DECOMPRESSOR_MIPS_QEMU_MIPS_UNCOMPRESSED_ADDR        0x10
 #define GRUB_KERNEL_MIPS_QEMU_MIPS_TOTAL_MODULE_SIZE   0x08
 
 #define GRUB_KERNEL_MIPS_ARC_LINK_ADDR         0x8bd00000
 
 #define GRUB_KERNEL_MIPS_ARC_LINK_ALIGN  32
 
-#define GRUB_KERNEL_MIPS_ARC_COMPRESSED_SIZE          0x8
-#define GRUB_KERNEL_MIPS_ARC_UNCOMPRESSED_SIZE        0xc
-#define GRUB_KERNEL_MIPS_ARC_UNCOMPRESSED_ADDR        0x10
+#define GRUB_DECOMPRESSOR_MIPS_ARC_COMPRESSED_SIZE          0x8
+#define GRUB_DECOMPRESSOR_MIPS_ARC_UNCOMPRESSED_SIZE        0xc
+#define GRUB_DECOMPRESSOR_MIPS_ARC_UNCOMPRESSED_ADDR        0x10
 
 #define GRUB_KERNEL_MIPS_ARC_TOTAL_MODULE_SIZE 0x08
 
 #define GRUB_KERNEL_MACHINE_MOD_ALIGN GRUB_OFFSETS_CONCAT (GRUB_KERNEL_, GRUB_MACHINE, _MOD_ALIGN)
 #define GRUB_KERNEL_MACHINE_MOD_GAP GRUB_OFFSETS_CONCAT (GRUB_KERNEL_, GRUB_MACHINE, _MOD_GAP)
 #define GRUB_KERNEL_MACHINE_TOTAL_MODULE_SIZE GRUB_OFFSETS_CONCAT (GRUB_KERNEL_, GRUB_MACHINE, _TOTAL_MODULE_SIZE)
-#define GRUB_KERNEL_MACHINE_KERNEL_IMAGE_SIZE GRUB_OFFSETS_CONCAT (GRUB_KERNEL_, GRUB_MACHINE, _KERNEL_IMAGE_SIZE)
-#define GRUB_KERNEL_MACHINE_COMPRESSED_SIZE GRUB_OFFSETS_CONCAT (GRUB_KERNEL_, GRUB_MACHINE, _COMPRESSED_SIZE)
-#define GRUB_KERNEL_MACHINE_UNCOMPRESSED_SIZE GRUB_OFFSETS_CONCAT (GRUB_KERNEL_, GRUB_MACHINE, _UNCOMPRESSED_SIZE)
-#define GRUB_KERNEL_MACHINE_UNCOMPRESSED_ADDR GRUB_OFFSETS_CONCAT (GRUB_KERNEL_, GRUB_MACHINE, _UNCOMPRESSED_ADDR)
 
 #define GRUB_BOOT_MACHINE_KERNEL_SEG GRUB_OFFSETS_CONCAT (GRUB_BOOT_, GRUB_MACHINE, _KERNEL_SEG)
 #define GRUB_MEMORY_MACHINE_UPPER GRUB_OFFSETS_CONCAT (GRUB_MEMORY_, GRUB_MACHINE, _UPPER)
 
 #define GRUB_DECOMPRESSOR_MACHINE_COMPRESSED_SIZE GRUB_OFFSETS_CONCAT (GRUB_DECOMPRESSOR_, GRUB_MACHINE, _COMPRESSED_SIZE)
 #define GRUB_DECOMPRESSOR_MACHINE_UNCOMPRESSED_SIZE GRUB_OFFSETS_CONCAT (GRUB_DECOMPRESSOR_, GRUB_MACHINE, _UNCOMPRESSED_SIZE)
+#define GRUB_DECOMPRESSOR_MACHINE_UNCOMPRESSED_ADDR GRUB_OFFSETS_CONCAT (GRUB_DECOMPRESSOR_, GRUB_MACHINE, _UNCOMPRESSED_ADDR)
 #endif
 
 #ifndef ASM_FILE
index 3912ad7b2b13992b66d7d7ab5dae79a6d41e31bd..0ffeb909e70676c6feb07fb19373af810df538fa 100644 (file)
@@ -246,9 +246,9 @@ struct image_target_desc image_targets[] =
       .id = IMAGE_YEELOONG_FLASH, 
       .flags = PLATFORM_FLAGS_DECOMPRESSORS,
       .total_module_size = GRUB_KERNEL_MIPS_LOONGSON_TOTAL_MODULE_SIZE,
-      .decompressor_compressed_size = GRUB_KERNEL_MIPS_LOONGSON_COMPRESSED_SIZE,
-      .decompressor_uncompressed_size = GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_SIZE,
-      .decompressor_uncompressed_addr = GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_ADDR,
+      .decompressor_compressed_size = GRUB_DECOMPRESSOR_MIPS_LOONGSON_COMPRESSED_SIZE,
+      .decompressor_uncompressed_size = GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_SIZE,
+      .decompressor_uncompressed_addr = GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_ADDR,
       .section_align = 1,
       .vaddr_offset = 0,
       .link_addr = GRUB_KERNEL_MIPS_LOONGSON_LINK_ADDR,
@@ -264,9 +264,9 @@ struct image_target_desc image_targets[] =
       .id = IMAGE_FULOONG2F_FLASH, 
       .flags = PLATFORM_FLAGS_DECOMPRESSORS,
       .total_module_size = GRUB_KERNEL_MIPS_LOONGSON_TOTAL_MODULE_SIZE,
-      .decompressor_compressed_size = GRUB_KERNEL_MIPS_LOONGSON_COMPRESSED_SIZE,
-      .decompressor_uncompressed_size = GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_SIZE,
-      .decompressor_uncompressed_addr = GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_ADDR,
+      .decompressor_compressed_size = GRUB_DECOMPRESSOR_MIPS_LOONGSON_COMPRESSED_SIZE,
+      .decompressor_uncompressed_size = GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_SIZE,
+      .decompressor_uncompressed_addr = GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_ADDR,
       .section_align = 1,
       .vaddr_offset = 0,
       .link_addr = GRUB_KERNEL_MIPS_LOONGSON_LINK_ADDR,
@@ -284,9 +284,9 @@ struct image_target_desc image_targets[] =
       .id = IMAGE_LOONGSON_ELF, 
       .flags = PLATFORM_FLAGS_DECOMPRESSORS,
       .total_module_size = GRUB_KERNEL_MIPS_LOONGSON_TOTAL_MODULE_SIZE,
-      .decompressor_compressed_size = GRUB_KERNEL_MIPS_LOONGSON_COMPRESSED_SIZE,
-      .decompressor_uncompressed_size = GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_SIZE,
-      .decompressor_uncompressed_addr = GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_ADDR,
+      .decompressor_compressed_size = GRUB_DECOMPRESSOR_MIPS_LOONGSON_COMPRESSED_SIZE,
+      .decompressor_uncompressed_size = GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_SIZE,
+      .decompressor_uncompressed_addr = GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_ADDR,
       .section_align = 1,
       .vaddr_offset = 0,
       .link_addr = GRUB_KERNEL_MIPS_LOONGSON_LINK_ADDR,
@@ -368,9 +368,9 @@ struct image_target_desc image_targets[] =
       .flags = (PLATFORM_FLAGS_DECOMPRESSORS
                | PLATFORM_FLAGS_MODULES_BEFORE_KERNEL),
       .total_module_size = GRUB_KERNEL_MIPS_ARC_TOTAL_MODULE_SIZE,
-      .decompressor_compressed_size = GRUB_KERNEL_MIPS_LOONGSON_COMPRESSED_SIZE,
-      .decompressor_uncompressed_size = GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_SIZE,
-      .decompressor_uncompressed_addr = GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_ADDR,
+      .decompressor_compressed_size = GRUB_DECOMPRESSOR_MIPS_LOONGSON_COMPRESSED_SIZE,
+      .decompressor_uncompressed_size = GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_SIZE,
+      .decompressor_uncompressed_addr = GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_ADDR,
       .section_align = 1,
       .vaddr_offset = 0,
       .link_addr = GRUB_KERNEL_MIPS_ARC_LINK_ADDR,
@@ -386,9 +386,9 @@ struct image_target_desc image_targets[] =
       .id = IMAGE_LOONGSON_ELF, 
       .flags = PLATFORM_FLAGS_DECOMPRESSORS,
       .total_module_size = GRUB_KERNEL_MIPS_QEMU_MIPS_TOTAL_MODULE_SIZE,
-      .decompressor_compressed_size = GRUB_KERNEL_MIPS_LOONGSON_COMPRESSED_SIZE,
-      .decompressor_uncompressed_size = GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_SIZE,
-      .decompressor_uncompressed_addr = GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_ADDR,
+      .decompressor_compressed_size = GRUB_DECOMPRESSOR_MIPS_LOONGSON_COMPRESSED_SIZE,
+      .decompressor_uncompressed_size = GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_SIZE,
+      .decompressor_uncompressed_addr = GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_ADDR,
       .section_align = 1,
       .vaddr_offset = 0,
       .link_addr = GRUB_KERNEL_MIPS_QEMU_MIPS_LINK_ADDR,
@@ -404,9 +404,9 @@ struct image_target_desc image_targets[] =
       .id = IMAGE_QEMU_MIPS_FLASH, 
       .flags = PLATFORM_FLAGS_DECOMPRESSORS,
       .total_module_size = GRUB_KERNEL_MIPS_QEMU_MIPS_TOTAL_MODULE_SIZE,
-      .decompressor_compressed_size = GRUB_KERNEL_MIPS_LOONGSON_COMPRESSED_SIZE,
-      .decompressor_uncompressed_size = GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_SIZE,
-      .decompressor_uncompressed_addr = GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_ADDR,
+      .decompressor_compressed_size = GRUB_DECOMPRESSOR_MIPS_LOONGSON_COMPRESSED_SIZE,
+      .decompressor_uncompressed_size = GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_SIZE,
+      .decompressor_uncompressed_addr = GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_ADDR,
       .section_align = 1,
       .vaddr_offset = 0,
       .link_addr = GRUB_KERNEL_MIPS_QEMU_MIPS_LINK_ADDR,
@@ -422,9 +422,9 @@ struct image_target_desc image_targets[] =
       .id = IMAGE_QEMU_MIPS_FLASH, 
       .flags = PLATFORM_FLAGS_DECOMPRESSORS,
       .total_module_size = GRUB_KERNEL_MIPS_QEMU_MIPS_TOTAL_MODULE_SIZE,
-      .decompressor_compressed_size = GRUB_KERNEL_MIPS_LOONGSON_COMPRESSED_SIZE,
-      .decompressor_uncompressed_size = GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_SIZE,
-      .decompressor_uncompressed_addr = GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_ADDR,
+      .decompressor_compressed_size = GRUB_DECOMPRESSOR_MIPS_LOONGSON_COMPRESSED_SIZE,
+      .decompressor_uncompressed_size = GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_SIZE,
+      .decompressor_uncompressed_addr = GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_ADDR,
       .section_align = 1,
       .vaddr_offset = 0,
       .link_addr = GRUB_KERNEL_MIPS_QEMU_MIPS_LINK_ADDR,
@@ -440,9 +440,9 @@ struct image_target_desc image_targets[] =
       .id = IMAGE_LOONGSON_ELF, 
       .flags = PLATFORM_FLAGS_DECOMPRESSORS,
       .total_module_size = GRUB_KERNEL_MIPS_QEMU_MIPS_TOTAL_MODULE_SIZE,
-      .decompressor_compressed_size = GRUB_KERNEL_MIPS_LOONGSON_COMPRESSED_SIZE,
-      .decompressor_uncompressed_size = GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_SIZE,
-      .decompressor_uncompressed_addr = GRUB_KERNEL_MIPS_LOONGSON_UNCOMPRESSED_ADDR,
+      .decompressor_compressed_size = GRUB_DECOMPRESSOR_MIPS_LOONGSON_COMPRESSED_SIZE,
+      .decompressor_uncompressed_size = GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_SIZE,
+      .decompressor_uncompressed_addr = GRUB_DECOMPRESSOR_MIPS_LOONGSON_UNCOMPRESSED_ADDR,
       .section_align = 1,
       .vaddr_offset = 0,
       .link_addr = GRUB_KERNEL_MIPS_QEMU_MIPS_LINK_ADDR,