]> git.proxmox.com Git - mirror_qemu.git/commitdiff
hw/xtensa/xtfpga: use symbolic constants for bootparam tags
authorMax Filippov <jcmvbkbc@gmail.com>
Sat, 21 Jun 2014 06:29:29 +0000 (10:29 +0400)
committerMax Filippov <jcmvbkbc@gmail.com>
Sat, 28 Jun 2014 22:32:42 +0000 (02:32 +0400)
Import bootparam tag names from linux/arch/xtensa/include/asm/bootparam.h
No functional changes.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
hw/xtensa/bootparam.h
hw/xtensa/xtfpga.c

index 38ef32bdb6e006a577893f7b0117afac337f804c..e6cf3b1492bec2c194a8fde2ab5ed5333924b87f 100644 (file)
@@ -1,6 +1,16 @@
 #ifndef HW_XTENSA_BOOTPARAM
 #define HW_XTENSA_BOOTPARAM
 
+#define BP_TAG_COMMAND_LINE     0x1001  /* command line (0-terminated string)*/
+#define BP_TAG_INITRD           0x1002  /* ramdisk addr and size (bp_meminfo) */
+#define BP_TAG_MEMORY           0x1003  /* memory addr and size (bp_meminfo) */
+#define BP_TAG_SERIAL_BAUDRATE  0x1004  /* baud rate of current console. */
+#define BP_TAG_SERIAL_PORT      0x1005  /* serial device of current console */
+#define BP_TAG_FDT              0x1006  /* flat device tree addr */
+
+#define BP_TAG_FIRST            0x7B0B  /* first tag with a version number */
+#define BP_TAG_LAST             0x7E0B  /* last tag */
+
 typedef struct BpTag {
     uint16_t tag;
     uint16_t size;
index 0aa3eeb046bd07de881f3db94ef82610599ca579..6d070b0d64299b95419265c26a2d67d20fd8ccca 100644 (file)
@@ -250,12 +250,12 @@ static void lx_init(const LxBoardDesc *board, MachineState *machine)
 
             env->regs[2] = tagptr;
 
-            tagptr = put_tag(tagptr, 0x7b0b, 0, NULL);
+            tagptr = put_tag(tagptr, BP_TAG_FIRST, 0, NULL);
             if (cmdline_size > 1) {
-                tagptr = put_tag(tagptr, 0x1001,
+                tagptr = put_tag(tagptr, BP_TAG_COMMAND_LINE,
                         cmdline_size, kernel_cmdline);
             }
-            tagptr = put_tag(tagptr, 0x7e0b, 0, NULL);
+            tagptr = put_tag(tagptr, BP_TAG_LAST, 0, NULL);
         }
         uint64_t elf_entry;
         uint64_t elf_lowaddr;