Skip to contentSkip to conversation

Trivial patches for 2014-02-02

GIT PULL Applied Michael Tokarev 2 participants 9 messages Feb 2, 2014 – Feb 5, 2014

lore
Share & tools
lore
#0 lore raw

There's nothing exciting in there, some really small things here and there.

Please pull.

Thanks,

/mjt

The following changes since commit 89e4a51ca9546a7bbe1998c4e3d4a3ac3a0c19be:

Merge remote-tracking branch 'stefanha/tags/tracing-pull-request' into staging (2014-01-31 11:13:08 +0000)

are available in the git repository at:

git://git.corpit.ru/qemu.git tags/trivial-patches-2014-02-02

for you to fetch changes up to b76afd1072e02fe77e09790fbe1e831700976c5f:

tests/.gitignore: Ignore tests/check-qom-interface (2014-02-01 13:56:31 +0400)

----------------------------------------------------------------
trivial patches for 2014-02-02

----------------------------------------------------------------
Fam Zheng (1):
tests/.gitignore: Ignore tests/check-qom-interface

Martin Husemann (1):
qemu 1.7.0 does not build on NetBSD

Richard Henderson (1):
tcg/s390: Remove sigill_handler

Stefan Hajnoczi (1):
osdep: drop unused #include "trace.h"

Stefan Weil (3):
i386: Add missing include file for QEMU_PACKED
readline: Add missing GCC_FMT_ATTR hw/ppc: Remove unused defines

 hw/i386/bios-linker-loader.c    |    3 +--
 hw/ppc/ppc4xx_devs.c            |    2 --
 include/exec/softmmu_template.h |    5 ++++-
 include/qemu/readline.h         |    3 ++-
 monitor.c                       |    3 ++-
 qemu-io.c                       |    3 ++-
 tcg/s390/tcg-target.c           |   19 -------------------
 tests/.gitignore                |    1 +
 util/osdep.c                    |    1 -
 9 files changed, 12 insertions(+), 28 deletions(-)
#1 lore raw

[Qemu-devel] [PULL 5/7] readline: Add missing GCC_FMT_ATTR

From: Stefan Weil <[email protected]>

This fixes a compiler warning with -Werror=missing-format-attribute and allows improved compiler checks for variable argument lists.

---
 include/qemu/readline.h |    3 ++-
 monitor.c               |    3 ++-
 qemu-io.c               |    3 ++-
 3 files changed, 6 insertions(+), 3 deletions(-)
include/qemu/readline.h +2 -1
index a89fe4a..49efe4e 100644
@@ -5,7 +5,8 @@
 #define READLINE_MAX_CMDS 64
 #define READLINE_MAX_COMPLETIONS 256
 
-typedef void ReadLinePrintfFunc(void *opaque, const char *fmt, ...);
+typedef void GCC_FMT_ATTR(2, 3) ReadLinePrintfFunc(void *opaque,
+                                                   const char *fmt, ...);
 typedef void ReadLineFlushFunc(void *opaque);
 typedef void ReadLineFunc(void *opaque, const char *str,
                           void *readline_opaque);
monitor.c +2 -1
index 80456fb..5ba541d 100644
@@ -4888,7 +4888,8 @@ static void sortcmdlist(void)
 /* These functions just adapt the readline interface in a typesafe way.  We
  * could cast function pointers but that discards compiler checks.
  */
-static void monitor_readline_printf(void *opaque, const char *fmt, ...)
+static void GCC_FMT_ATTR(2, 3) monitor_readline_printf(void *opaque,
+                                                       const char *fmt, ...)
 {
     va_list ap;
     va_start(ap, fmt);
qemu-io.c +2 -1
index d669028..7f459d8 100644
@@ -219,7 +219,8 @@ static char *get_prompt(void)
     return prompt;
 }
 
-static void readline_printf_func(void *opaque, const char *fmt, ...)
+static void GCC_FMT_ATTR(2, 3) readline_printf_func(void *opaque,
+                                                    const char *fmt, ...)
 {
     va_list ap;
     va_start(ap, fmt);
Signature · 1 line
1.7.10.4
#2 lore raw

[Qemu-devel] [PULL 2/7] osdep: drop unused #include "trace.h"

In reply to Michael Tokarev

From: Stefan Hajnoczi <[email protected]>

osdep.c does not use trace_*() so we can just drop the include.

---
 util/osdep.c |    1 -
 1 file changed, 1 deletion(-)
util/osdep.c +0 -1
index 62072b4..bd4f530 100644
@@ -46,7 +46,6 @@ extern int madvise(caddr_t, size_t, int);
 #endif
 
 #include "qemu-common.h"
-#include "trace.h"
 #include "qemu/sockets.h"
 #include "monitor/monitor.h"
 
Signature · 1 line
1.7.10.4
#3 lore raw

[Qemu-devel] [PULL 3/7] i386: Add missing include file for QEMU_PACKED

In reply to Michael Tokarev

From: Stefan Weil <[email protected]>

Instead of packing BiosLinkerLoaderEntry, an unused global variable called QEMU_PACKED was created (detected by smatch static code analysis).

Including qemu-common.h gets the right definition and also includes some standard include files which now can be removed here.

---
 hw/i386/bios-linker-loader.c |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
hw/i386/bios-linker-loader.c +1 -2
index fd23611..aa56184 100644
@@ -18,11 +18,10 @@
  * with this program; if not, see <http://www.gnu.org/licenses/>.
  */
 
+#include "qemu-common.h"
 #include "bios-linker-loader.h"
 #include "hw/nvram/fw_cfg.h"
 
-#include <string.h>
-#include <assert.h>
 #include "qemu/bswap.h"
 
 #define BIOS_LINKER_LOADER_FILESZ FW_CFG_MAX_FILE_PATH
Signature · 1 line
1.7.10.4
#4 lore raw

[Qemu-devel] [PULL 7/7] tests/.gitignore: Ignore tests/check-qom-interface

In reply to Michael Tokarev

From: Fam Zheng <[email protected]>

---
 tests/.gitignore |    1 +
 1 file changed, 1 insertion(+)
tests/.gitignore +1 -0
index 1aed224..9ba9d96 100644
@@ -4,6 +4,7 @@ check-qint
 check-qjson
 check-qlist
 check-qstring
+check-qom-interface
 test-aio
 test-bitops
 test-throttle
Signature · 1 line
1.7.10.4
#5 lore raw

[Qemu-devel] [PULL 4/7] tcg/s390: Remove sigill_handler

In reply to Michael Tokarev

From: Richard Henderson <[email protected]>

Commit c9baa30f42a87f61627391698f63fa4d1566d9d8 failed to delete all of the relevant code, leading to Werrors about unused symbols.

---
 tcg/s390/tcg-target.c |   19 -------------------
 1 file changed, 19 deletions(-)
tcg/s390/tcg-target.c +0 -19
index 248726e..907d9d1 100644
@@ -2214,25 +2214,6 @@ static const TCGTargetOpDef s390_op_defs[] = {
     { -1 },
 };
 
-/* ??? Linux kernels provide an AUXV entry AT_HWCAP that provides most of
-   this information.  However, getting at that entry is not easy this far
-   away from main.  Our options are: start searching from environ, but
-   that fails as soon as someone does a setenv in between.  Read the data
-   from /proc/self/auxv.  Or do the probing ourselves.  The only thing
-   extra that AT_HWCAP gives us is HWCAP_S390_HIGH_GPRS, which indicates
-   that the kernel saves all 64-bits of the registers around traps while
-   in 31-bit mode.  But this is true of all "recent" kernels (ought to dig
-   back and see from when this might not be true).  */
-
-#include <signal.h>
-
-static volatile sig_atomic_t got_sigill;
-
-static void sigill_handler(int sig)
-{
-    got_sigill = 1;
-}
-
 static void query_facilities(void)
 {
     unsigned long hwcap = qemu_getauxval(AT_HWCAP);
Signature · 1 line
1.7.10.4
#6 lore raw

[Qemu-devel] [PULL 1/7] qemu 1.7.0 does not build on NetBSD

In reply to Michael Tokarev

From: Martin Husemann <[email protected]>

Do not rely on int8_t (and friends) not being preprocessor symbols (or symbols expanding to themselves). On NetBSD (for example) the glue(u, SDATA_TYPE) results in u__int8_t, which is undefined. There is no way to stop cpp expanding inner macros, so just add the few lines explicitly and get rid of the magic.

---
 include/exec/softmmu_template.h |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
include/exec/softmmu_template.h +4 -1
index c6a5440..8712dcd 100644
@@ -30,23 +30,26 @@
 #define SUFFIX q
 #define LSUFFIX q
 #define SDATA_TYPE  int64_t
+#define DATA_TYPE  uint64_t
 #elif DATA_SIZE == 4
 #define SUFFIX l
 #define LSUFFIX l
 #define SDATA_TYPE  int32_t
+#define DATA_TYPE  uint32_t
 #elif DATA_SIZE == 2
 #define SUFFIX w
 #define LSUFFIX uw
 #define SDATA_TYPE  int16_t
+#define DATA_TYPE  uint16_t
 #elif DATA_SIZE == 1
 #define SUFFIX b
 #define LSUFFIX ub
 #define SDATA_TYPE  int8_t
+#define DATA_TYPE  uint8_t
 #else
 #error unsupported data size
 #endif
 
-#define DATA_TYPE   glue(u, SDATA_TYPE)
 
 /* For the benefit of TCG generated code, we want to avoid the complication
    of ABI-specific return type promotion and always return a value extended
Signature · 1 line
1.7.10.4
#7 lore raw

[Qemu-devel] [PULL 6/7] hw/ppc: Remove unused defines

In reply to Michael Tokarev

From: Stefan Weil <[email protected]>

---
 hw/ppc/ppc4xx_devs.c |    2 --
 1 file changed, 2 deletions(-)
hw/ppc/ppc4xx_devs.c +0 -2
index 239aada..9160ee7 100644
@@ -27,8 +27,6 @@
 #include "qemu/log.h"
 #include "exec/address-spaces.h"
 
-//#define DEBUG_MMIO
-//#define DEBUG_UNASSIGNED
 #define DEBUG_UIC
 
 
Signature · 1 line
1.7.10.4
#8 lore raw
In reply to Michael Tokarev
Quoted 12 lines · Michael Tokarev

There's nothing exciting in there, some really small things here and there.

Please pull.

Thanks,

/mjt

The following changes since commit 89e4a51ca9546a7bbe1998c4e3d4a3ac3a0c19be:

Merge remote-tracking branch 'stefanha/tags/tracing-pull-request' into staging (2014-01-31 11:13:08 +0000)

Quoted 8 lines

are available in the git repository at:

git://git.corpit.ru/qemu.git tags/trivial-patches-2014-02-02

for you to fetch changes up to b76afd1072e02fe77e09790fbe1e831700976c5f:

tests/.gitignore: Ignore tests/check-qom-interface (2014-02-01 13:56:31 +0400)

Applied, thanks.

-- PMM