public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Mike Frysinger <vapier@gentoo.org>
To: gdb-patches@sourceware.org
Subject: [PATCH/committed 2/2] sim: m68hc11: fix up last warnings
Date: Thu,  6 May 2021 23:55:14 -0400	[thread overview]
Message-ID: <20210507035514.12299-2-vapier@gentoo.org> (raw)
In-Reply-To: <20210507035514.12299-1-vapier@gentoo.org>

Change the printf formats a little to fix the last build warnings in
here, and then turn on -Werror by default for the arch port.
---
 sim/m68hc11/ChangeLog    |   6 ++
 sim/m68hc11/configure    | 203 ++++++++++++++++++++-------------------
 sim/m68hc11/configure.ac |   1 -
 sim/m68hc11/interp.c     |   8 +-
 4 files changed, 113 insertions(+), 105 deletions(-)

diff --git a/sim/m68hc11/ChangeLog b/sim/m68hc11/ChangeLog
index 48b54b45dea2..1aaa51b29bb7 100644
--- a/sim/m68hc11/ChangeLog
+++ b/sim/m68hc11/ChangeLog
@@ -1,3 +1,9 @@
+2021-05-06  Mike Frysinger  <vapier@gentoo.org>
+
+	* interp.c (sim_hw_configure): Change %lx to %x in format strings.
+	* configure.ac: Delete SIM_AC_OPTION_WARNINGS call.
+	* configure: Regenerate.
+
 2021-05-06  Mike Frysinger  <vapier@gentoo.org>
 
 	* emulos.c: Include errno.h & stdio.h.
diff --git a/sim/m68hc11/configure.ac b/sim/m68hc11/configure.ac
index be52b63c2092..57e13e207bdd 100644
--- a/sim/m68hc11/configure.ac
+++ b/sim/m68hc11/configure.ac
@@ -7,7 +7,6 @@ SIM_AC_COMMON
 dnl Options available in this module
 SIM_AC_OPTION_ENDIAN(BIG)
 SIM_AC_OPTION_ALIGNMENT(NONSTRICT_ALIGNMENT)
-SIM_AC_OPTION_WARNINGS(no)
 SIM_AC_OPTION_HARDWARE(\
   m68hc11 m68hc11sio m68hc11eepr m68hc11tim m68hc11spi nvram)
 
diff --git a/sim/m68hc11/interp.c b/sim/m68hc11/interp.c
index 91d4d25b322a..07e4a8858a74 100644
--- a/sim/m68hc11/interp.c
+++ b/sim/m68hc11/interp.c
@@ -172,7 +172,7 @@ sim_hw_configure (SIM_DESC sd)
 	  /* Allocate core managed memory */
 
 	  /* the monitor  */
-	  sim_do_commandf (sd, "memory region 0x%lx@%d,0x%lx",
+	  sim_do_commandf (sd, "memory region 0x%x@%d,0x%x",
 			   /* MONITOR_BASE, MONITOR_SIZE */
 			   0x8000, M6811_RAM_LEVEL, 0x8000);
 	  sim_do_commandf (sd, "memory region 0x000@%d,0x8000",
@@ -180,7 +180,7 @@ sim_hw_configure (SIM_DESC sd)
 	  sim_hw_parse (sd, "/m68hc11/reg 0x1000 0x03F");
           if (cpu->bank_start < cpu->bank_end)
             {
-              sim_do_commandf (sd, "memory region 0x%lx@%d,0x100000",
+              sim_do_commandf (sd, "memory region 0x%x@%d,0x100000",
                                cpu->bank_virtual, M6811_RAM_LEVEL);
               sim_hw_parse (sd, "/m68hc11/use_bank 1");
             }
@@ -234,13 +234,13 @@ sim_hw_configure (SIM_DESC sd)
       if (hw_tree_find_property (device_tree, "/m68hc12/reg") == 0)
 	{
 	  /* Allocate core external memory.  */
-	  sim_do_commandf (sd, "memory region 0x%lx@%d,0x%lx",
+	  sim_do_commandf (sd, "memory region 0x%x@%d,0x%x",
 			   0x8000, M6811_RAM_LEVEL, 0x8000);
 	  sim_do_commandf (sd, "memory region 0x000@%d,0x8000",
 			   M6811_RAM_LEVEL);
           if (cpu->bank_start < cpu->bank_end)
             {
-              sim_do_commandf (sd, "memory region 0x%lx@%d,0x100000",
+              sim_do_commandf (sd, "memory region 0x%x@%d,0x100000",
                                cpu->bank_virtual, M6811_RAM_LEVEL);
               sim_hw_parse (sd, "/m68hc12/use_bank 1");
             }
-- 
2.31.1


      reply	other threads:[~2021-05-07  3:55 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-07  3:55 [PATCH/committed 1/2] sim: m68hc11: warn when emul_write fails Mike Frysinger
2021-05-07  3:55 ` Mike Frysinger [this message]

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=20210507035514.12299-2-vapier@gentoo.org \
    --to=vapier@gentoo.org \
    --cc=gdb-patches@sourceware.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).