All of lore.kernel.org
 help / color / mirror / Atom feed
From: Laurent Vivier <laurent@vivier.eu>
To: qemu-devel@nongnu.org
Cc: Laurent Vivier <laurent@vivier.eu>
Subject: [PATCH 1/3] m68k: bootinfo entry size must be aligned on 4 bytes
Date: Wed,  2 Feb 2022 23:35:26 +0100	[thread overview]
Message-ID: <20220202223528.1260154-2-laurent@vivier.eu> (raw)
In-Reply-To: <20220202223528.1260154-1-laurent@vivier.eu>

This is checked by petitboot.

Signed-off-by: Laurent Vivier <laurent@vivier.eu>
---
 hw/m68k/bootinfo.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/hw/m68k/bootinfo.h b/hw/m68k/bootinfo.h
index adbf0c5521e5..94c97a71fa07 100644
--- a/hw/m68k/bootinfo.h
+++ b/hw/m68k/bootinfo.h
@@ -48,12 +48,12 @@
         stw_phys(as, base, id); \
         base += 2; \
         stw_phys(as, base, \
-                 (sizeof(struct bi_record) + strlen(string) + 2) & ~1); \
+                 (sizeof(struct bi_record) + strlen(string) + 4) & ~3); \
         base += 2; \
         for (i = 0; string[i]; i++) { \
             stb_phys(as, base++, string[i]); \
         } \
         stb_phys(as, base++, 0); \
-        base = (parameters_base + 1) & ~1; \
+        base = (parameters_base + 4) & ~3; \
     } while (0)
 #endif
-- 
2.34.1



  reply	other threads:[~2022-02-02 22:43 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-02 22:35 [PATCH 0/3] m68k: virt: add a firmware to the virt machine (petit boot) Laurent Vivier
2022-02-02 22:35 ` Laurent Vivier [this message]
2022-02-02 22:35 ` [PATCH 2/3] m68k: virt: add a bootstrap ROM Laurent Vivier
2022-02-02 23:27   ` Philippe Mathieu-Daudé via
2022-02-02 22:35 ` [PATCH 3/3] m68k: virt: add a firmware (petitboot) Laurent Vivier

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220202223528.1260154-2-laurent@vivier.eu \
    --to=laurent@vivier.eu \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.