Skip to contentSkip to conversation

Trivial patches for September 10 to 21 2011

GIT PULL New Stefan Hajnoczi 2 participants 10 messages Sep 21, 2011 – Sep 22, 2011

lore
Share & tools
lore
#0 lore raw

The following changes since commit 27cdad67a1bc23b38c765b677ed8064bfb8d3e44:

Revert "alpha-softmmu: Disable for the 0.15 release branch." (2011-09-21 00:50:32 +0200)

are available in the git repository at:
ssh://repo.or.cz/srv/git/qemu/stefanha.git trivial-patches

Christoph Egger (1):
use qemu_* ctype functions

Jan Kiszka (3):
Drop unneeded pthread.h inclusions Silence make if nothing is to do for libcacard Abort on thread layer errors

Paolo Bonzini (1):
fix compilation with stderr trace backend

Peter Maydell (1):
configure: Make missing pkg-config an error rather than a warning

Stefan Weil (2):
target-i386: Remove data type CCTable
Remove qemu_host_page_bits

 cmd.c                   |    2 +-
 configure               |    4 ++--
 cpu-all.h               |    1 -
 exec.c                  |    4 ----
 hw/xen_nic.c            |    1 -
 hw/xics.c               |    2 --
 libcacard/Makefile      |    2 ++
 qemu-thread-posix.c     |    2 +-
 qemu-thread-win32.c     |    2 +-
 target-i386/cpu.h       |    5 -----
 target-i386/translate.c |    5 -----
 trace-events            |    2 +-
 ui/keymaps.c            |    2 +-
 ui/spice-display.c      |    2 --
 14 files changed, 9 insertions(+), 27 deletions(-)
Signature · 1 line
1.7.5.4
#1 lore raw

PATCH 1/8 target-i386: Remove data type CCTable

From: Stefan Weil <[email protected]>

Remove also two assert statements which were the last remaining users.

---
 target-i386/cpu.h       |    5 -----
 target-i386/translate.c |    5 -----
 2 files changed, 0 insertions(+), 10 deletions(-)
target-i386/cpu.h +0 -5
index 4a6f675..ae36489 100644
@@ -991,11 +991,6 @@ static inline int cpu_mmu_index (CPUState *env)
 /* translate.c */
 void optimize_flags_init(void);
 
-typedef struct CCTable {
-    int (*compute_all)(void); /* return all the flags */
-    int (*compute_c)(void);  /* return the C flag */
-} CCTable;
-
 #if defined(CONFIG_USER_ONLY)
 static inline void cpu_clone_regs(CPUState *env, target_ulong newsp)
 {
target-i386/translate.c +0 -5
index b966762..b894e97 100644
@@ -7641,11 +7641,6 @@ static target_ulong disas_insn(DisasContext *s, target_ulong pc_start)
 
 void optimize_flags_init(void)
 {
-#if TCG_TARGET_REG_BITS == 32
-    assert(sizeof(CCTable) == (1 << 3));
-#else
-    assert(sizeof(CCTable) == (1 << 4));
-#endif
     cpu_env = tcg_global_reg_new_ptr(TCG_AREG0, "env");
     cpu_cc_op = tcg_global_mem_new_i32(TCG_AREG0,
                                        offsetof(CPUState, cc_op), "cc_op");
Signature · 1 line
1.7.5.4
#2 lore raw

PATCH 2/8 configure: Make missing pkg-config an error rather than a warning

In reply to Stefan Hajnoczi

From: Peter Maydell <[email protected]>

If pkg-config doesn't exist then make configure fail immediately with a useful error message. Now that glib is a required dependency, proceeding despite the missing pkg-config will just cause us to fail later with a misleading message about glib not being present.

---
 configure |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
configure +2 -2
index 414317a..9ab3ab4 100755
@@ -1340,8 +1340,8 @@ fi
 # pkg-config probe
 
 if ! has $pkg_config; then
-  echo warning: proceeding without "$pkg_config" >&2
-  pkg_config=/bin/false
+  echo "Error: pkg-config binary '$pkg_config' not found"
+  exit 1
 fi
 
 ##########################################
Signature · 1 line
1.7.5.4
#3 lore raw

PATCH 3/8 fix compilation with stderr trace backend

In reply to Stefan Hajnoczi

From: Paolo Bonzini <[email protected]>

---
 trace-events |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
trace-events +1 -1
index 829dc92..a31d9aa 100644
@@ -455,7 +455,7 @@ milkymist_vgafb_memory_write(uint32_t addr, uint32_t value) "addr %08x value %08
 mipsnet_send(uint32_t size) "sending len=%u"
 mipsnet_receive(uint32_t size) "receiving len=%u"
 mipsnet_read(uint64_t addr, uint32_t val) "read addr=0x%" PRIx64 " val=0x%x"
-mipsnet_write(uint64_t addr, uint64_t val) "write addr=0x%" PRIx64 " val=0x%" PRIx64
+mipsnet_write(uint64_t addr, uint64_t val) "write addr=0x%" PRIx64 " val=0x%" PRIx64 ""
 mipsnet_irq(uint32_t isr, uint32_t intctl) "set irq to %d (%02x)"
 
 # xen-all.c
Signature · 1 line
1.7.5.4
#4 lore raw

PATCH 4/8 Drop unneeded pthread.h inclusions

In reply to Stefan Hajnoczi

From: Jan Kiszka <[email protected]>

---
 hw/xen_nic.c       |    1 -
 hw/xics.c          |    2 --
 ui/spice-display.c |    2 --
 3 files changed, 0 insertions(+), 5 deletions(-)
hw/xen_nic.c +0 -1
index aeca8da..ef2a2d6 100644
@@ -25,7 +25,6 @@
 #include <inttypes.h>
 #include <fcntl.h>
 #include <errno.h>
-#include <pthread.h>
 #include <sys/socket.h>
 #include <sys/ioctl.h>
 #include <sys/types.h>
hw/xics.c +0 -2
index 9bf82aa..80e064e 100644
@@ -29,8 +29,6 @@
 #include "hw/spapr.h"
 #include "hw/xics.h"
 
-#include <pthread.h>
-
 /*
  * ICP: Presentation layer
  */
ui/spice-display.c +0 -2
index 3a92a12..6c302a3 100644
@@ -15,8 +15,6 @@
  * along with this program; if not, see <http://www.gnu.org/licenses/>.
  */
 
-#include <pthread.h>
-
 #include "qemu-common.h"
 #include "qemu-spice.h"
 #include "qemu-timer.h"
Signature · 1 line
1.7.5.4
#5 lore raw

PATCH 5/8 Silence make if nothing is to do for libcacard

In reply to Stefan Hajnoczi

From: Jan Kiszka <[email protected]>

---
 libcacard/Makefile |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
libcacard/Makefile +2 -0
index 81d9eb5..a145569 100644
@@ -27,6 +27,8 @@ clean:
 	rm -Rf .libs
 
 all: vscclient
+# Dummy command so that make thinks it has done something
+	@true
 
 #########################################################################
 # Rules for building libcacard standalone library
Signature · 1 line
1.7.5.4
#6 lore raw

PATCH 6/8 Abort on thread layer errors

In reply to Stefan Hajnoczi

From: Jan Kiszka <[email protected]>

Makes it easier to catch the bug in gdb as there is no need to set an explicit breakpoint.

---
 qemu-thread-posix.c |    2 +-
 qemu-thread-win32.c |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
qemu-thread-posix.c +1 -1
index 2bd02ef..ac3c0c9 100644
@@ -22,7 +22,7 @@
 static void error_exit(int err, const char *msg)
 {
     fprintf(stderr, "qemu: %s: %s\n", msg, strerror(err));
-    exit(1);
+    abort();
 }
 
 void qemu_mutex_init(QemuMutex *mutex)
qemu-thread-win32.c +1 -1
index a27332e..db8e744 100644
@@ -24,7 +24,7 @@ static void error_exit(int err, const char *msg)
                   NULL, err, 0, (LPTSTR)&pstr, 2, NULL);
     fprintf(stderr, "qemu: %s: %s\n", msg, pstr);
     LocalFree(pstr);
-    exit(1);
+    abort();
 }
 
 void qemu_mutex_init(QemuMutex *mutex)
Signature · 1 line
1.7.5.4
#7 lore raw

PATCH 7/8 Remove qemu_host_page_bits

In reply to Stefan Hajnoczi

From: Stefan Weil <[email protected]>

It was introduced with commit 54936004fddc52c321cb3f9a9a51140e782bed5d as host_page_bits but never used.

---
 cpu-all.h |    1 -
 exec.c    |    4 ----
 2 files changed, 0 insertions(+), 5 deletions(-)
cpu-all.h +0 -1
index f5c82cd..42a5fa0 100644
@@ -290,7 +290,6 @@ extern unsigned long reserved_va;
 
 /* ??? These should be the larger of unsigned long and target_ulong.  */
 extern unsigned long qemu_real_host_page_size;
-extern unsigned long qemu_host_page_bits;
 extern unsigned long qemu_host_page_size;
 extern unsigned long qemu_host_page_mask;
 
exec.c +0 -4
index c1e045d..1e6f732 100644
@@ -183,7 +183,6 @@ typedef struct PageDesc {
 #define V_L1_SHIFT (L1_MAP_ADDR_SPACE_BITS - TARGET_PAGE_BITS - V_L1_BITS)
 
 unsigned long qemu_real_host_page_size;
-unsigned long qemu_host_page_bits;
 unsigned long qemu_host_page_size;
 unsigned long qemu_host_page_mask;
 
@@ -274,9 +273,6 @@ static void page_init(void)
         qemu_host_page_size = qemu_real_host_page_size;
     if (qemu_host_page_size < TARGET_PAGE_SIZE)
         qemu_host_page_size = TARGET_PAGE_SIZE;
-    qemu_host_page_bits = 0;
-    while ((1 << qemu_host_page_bits) < qemu_host_page_size)
-        qemu_host_page_bits++;
     qemu_host_page_mask = ~(qemu_host_page_size - 1);
 
 #if defined(CONFIG_BSD) && defined(CONFIG_USER_ONLY)
Signature · 1 line
1.7.5.4
#8 lore raw

PATCH 8/8 use qemu_* ctype functions

In reply to Stefan Hajnoczi

From: Christoph Egger <[email protected]>

Fix "warning: array subscript has type 'char'" on NetBSD.

---
 cmd.c        |    2 +-
 ui/keymaps.c |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
cmd.c +1 -1
index ecca167..f77897e 100644
@@ -389,7 +389,7 @@ cvtnum(
 	if (sp[1] != '\0')
 		return -1LL;
 
-	c = tolower(*sp);
+	c = qemu_tolower(*sp);
 	switch (c) {
 	default:
 		return i;
ui/keymaps.c +1 -1
index 81003bb..f54a114 100644
@@ -146,7 +146,7 @@ static kbd_layout_t *parse_keyboard_layout(const name2keysym_t *table,
 		    if (rest && strstr(rest, "addupper")) {
 			char *c;
 			for (c = line; *c; c++)
-			    *c = toupper(*c);
+			    *c = qemu_toupper(*c);
 			keysym = get_keysym(table, line);
 			if (keysym)
 			    add_keysym(line, keysym, keycode | SCANCODE_SHIFT, k);
Signature · 1 line
1.7.5.4
#9 lore raw
In reply to Stefan Hajnoczi
Quoted 6 lines · Stefan Hajnoczi

The following changes since commit 27cdad67a1bc23b38c765b677ed8064bfb8d3e44:

   Revert "alpha-softmmu: Disable for the 0.15 release branch." (2011-09-21 00:50:32 +0200)

are available in the git repository at:
ssh://repo.or.cz/srv/git/qemu/stefanha.git trivial-patches

Pulled. Thanks.

Regards,

Anthony Liguori

Quoted 35 lines

Christoph Egger (1):
use qemu_* ctype functions

Jan Kiszka (3):
Drop unneeded pthread.h inclusions Silence make if nothing is to do for libcacard Abort on thread layer errors

Paolo Bonzini (1):
fix compilation with stderr trace backend

Peter Maydell (1):
configure: Make missing pkg-config an error rather than a warning

Stefan Weil (2):
target-i386: Remove data type CCTable
Remove qemu_host_page_bits

  cmd.c                   |    2 +-
  configure               |    4 ++--
  cpu-all.h               |    1 -
  exec.c                  |    4 ----
  hw/xen_nic.c            |    1 -
  hw/xics.c               |    2 --
  libcacard/Makefile      |    2 ++
  qemu-thread-posix.c     |    2 +-
  qemu-thread-win32.c     |    2 +-
  target-i386/cpu.h       |    5 -----
  target-i386/translate.c |    5 -----
  trace-events            |    2 +-
  ui/keymaps.c            |    2 +-
  ui/spice-display.c      |    2 --
  14 files changed, 9 insertions(+), 27 deletions(-)