qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PULL v2 00/20] SCSI, build, TCG, RCU, misc patches for 2015-08-12
@ 2015-08-14 13:03 Paolo Bonzini
  2015-08-14 13:03 ` [Qemu-devel] [PULL v2 09/20] configure: Default to enable module build Paolo Bonzini
  2015-08-14 13:53 ` [Qemu-devel] [PULL v2 00/20] SCSI, build, TCG, RCU, misc patches for 2015-08-12 Peter Maydell
  0 siblings, 2 replies; 6+ messages in thread
From: Paolo Bonzini @ 2015-08-14 13:03 UTC (permalink / raw)
  To: qemu-devel

The following changes since commit cb48f67ad8c7b33c617d4f8144a27706e69fd688:

  bsd-user: Fix operand to cpu_x86_exec (2015-07-30 12:38:49 +0100)

are available in the git repository at:

  git://github.com/bonzini/qemu.git tags/for-upstream

for you to fetch changes up to 2dfebe37e6210278cddd070761ee543f49a8a82d:

  disas: Defeature print_target_address (2015-08-13 11:33:35 +0200)

----------------------------------------------------------------
* SCSI fixes from Stefan and Fam
* vhost-scsi fix from Igor and Lu Lina
* a build system fix from Daniel
* two more multi-arch-related patches from Peter C.
* TCG patches from myself and Sergey Fedorov
* RCU improvement from Wen Congyang
* enabling module builds by default
* a few more simple cleanups

----------------------------------------------------------------
Chen Hanxiao (1):
      exec: use macro ROUND_UP for alignment

Daniel P. Berrange (1):
      configure: only add CONFIG_RDMA to config-host.h once

Fam Zheng (3):
      scsi-disk: Fix assertion failure on WRITE SAME
      virtio-scsi-test: Add test case for tail unaligned WRITE SAME
      configure: Default to enable module build

Igor Mammedov (1):
      vhost/scsi: call vhost_dev_cleanup() at unrealize() time

Lu Lina (1):
      vhost-scsi: Clarify vhost_virtqueue_mask argument

Paolo Bonzini (6):
      exec: drop cpu_can_do_io, just read cpu->can_do_io
      qemu-nbd: remove unnecessary qemu_notify_event()
      scsi: create restart bottom half in the right AioContext
      scsi-disk: identify AIO callbacks more clearly
      scsi-generic: identify AIO callbacks more clearly
      hw: fix mask for ColdFire UART command register

Peter Crosthwaite (2):
      cpu_defs: Simplify CPUTLB padding logic
      disas: Defeature print_target_address

Sergey Fedorov (1):
      cpu-exec: Do not invalidate original TB in cpu_exec_nocache()

Stefan Hajnoczi (3):
      virtio-scsi: use virtqueue_map_sg() when loading requests
      scsi-disk: fix cmd.mode field typo
      tests: virtio-scsi: clear unit attention after reset

Wen Congyang (1):
      rcu: Allow calling rcu_(un)register_thread() during synchronize_rcu()

 .travis.yml              |   2 +-
 configure                | 127 +++++++++++++++++++++++++++++++----------------
 cpu-exec.c               |  10 ++--
 cpus.c                   |   2 +-
 disas.c                  |  12 +----
 exec.c                   |   2 +-
 hw/char/mcf_uart.c       |   2 +-
 hw/scsi/scsi-bus.c       |   3 +-
 hw/scsi/scsi-disk.c      |  97 ++++++++++++++++++++++++------------
 hw/scsi/scsi-generic.c   |  66 ++++++++++++++----------
 hw/scsi/vhost-scsi.c     |   3 +-
 hw/scsi/virtio-scsi.c    |   5 ++
 include/exec/cpu-defs.h  |  23 +++++----
 include/exec/exec-all.h  |  23 +--------
 include/qom/cpu.h        |   4 +-
 qemu-nbd.c               |   1 -
 qom/cpu.c                |   2 +-
 softmmu_template.h       |   4 +-
 tests/virtio-scsi-test.c | 100 +++++++++++++++++++++++--------------
 translate-all.c          |  11 +++-
 util/rcu.c               |  48 +++++++++++++-----
 21 files changed, 337 insertions(+), 210 deletions(-)
-- 
2.4.3

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Qemu-devel] [PULL v2 09/20] configure: Default to enable module build
  2015-08-14 13:03 [Qemu-devel] [PULL v2 00/20] SCSI, build, TCG, RCU, misc patches for 2015-08-12 Paolo Bonzini
@ 2015-08-14 13:03 ` Paolo Bonzini
  2015-08-14 13:53 ` [Qemu-devel] [PULL v2 00/20] SCSI, build, TCG, RCU, misc patches for 2015-08-12 Peter Maydell
  1 sibling, 0 replies; 6+ messages in thread
From: Paolo Bonzini @ 2015-08-14 13:03 UTC (permalink / raw)
  To: qemu-devel; +Cc: Fam Zheng

From: Fam Zheng <famz@redhat.com>

We have module build support around for a while, but also had it bitrot
several times. It probably makes sense to enable it by default so that
people can notice and use it.

Add --disable-modules as a counterpart to --enable-modules, which is
now turned on by default.  If both are omitted, support is guessed as
usual.

pie is now checked for all platforms, because it's depended on by module
build.

Signed-off-by: Fam Zheng <famz@redhat.com>
Message-Id: <1423481144-20314-2-git-send-email-famz@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
 .travis.yml |   2 +-
 configure   | 123 +++++++++++++++++++++++++++++++++++++++++-------------------
 2 files changed, 86 insertions(+), 39 deletions(-)

diff --git a/.travis.yml b/.travis.yml
index 0ac170b..12bf1db 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -99,5 +99,5 @@ matrix:
           EXTRA_CONFIG="--enable-trace-backends=ust"
       compiler: gcc
     - env: TARGETS=i386-softmmu,x86_64-softmmu
-           EXTRA_CONFIG="--enable-modules"
+           EXTRA_CONFIG="--disable-modules"
       compiler: gcc
diff --git a/configure b/configure
index 704b34c..6faeb00 100755
--- a/configure
+++ b/configure
@@ -271,7 +271,7 @@ gcov_tool="gcov"
 EXESUF=""
 DSOSUF=".so"
 LDFLAGS_SHARED="-shared"
-modules="no"
+modules=""
 prefix="/usr/local"
 mandir="\${prefix}/share/man"
 datadir="\${prefix}/share"
@@ -784,6 +784,9 @@ for opt do
   --enable-modules)
       modules="yes"
   ;;
+  --disable-modules)
+      modules="no"
+  ;;
   --cpu=*)
   ;;
   --target-list=*) target_list="$optarg"
@@ -1508,9 +1511,6 @@ if compile_prog "-Werror -fno-gcse" "" ; then
 fi
 
 if test "$static" = "yes" ; then
-  if test "$modules" = "yes" ; then
-    error_exit "static and modules are mutually incompatible"
-  fi
   if test "$pie" = "yes" ; then
     error_exit "static and pie are mutually incompatible"
   else
@@ -1518,17 +1518,6 @@ if test "$static" = "yes" ; then
   fi
 fi
 
-# Unconditional check for compiler __thread support
-  cat > $TMPC << EOF
-static __thread int tls_var;
-int main(void) { return tls_var; }
-EOF
-
-if ! compile_prog "-Werror" "" ; then
-    error_exit "Your compiler does not support the __thread specifier for " \
-	"Thread-Local Storage (TLS). Please upgrade to a version that does."
-fi
-
 if test "$pie" = ""; then
   case "$cpu-$targetos" in
     i386-Linux|x86_64-Linux|x32-Linux|i386-OpenBSD|x86_64-OpenBSD)
@@ -1601,6 +1590,17 @@ EOF
   fi
 fi
 
+# Unconditional check for compiler __thread support
+  cat > $TMPC << EOF
+static __thread int tls_var;
+int main(void) { return tls_var; }
+EOF
+
+if ! compile_prog "-Werror" "" ; then
+    error_exit "Your compiler does not support the __thread specifier for " \
+	"Thread-Local Storage (TLS). Please upgrade to a version that does."
+fi
+
 ##########################################
 # __sync_fetch_and_and requires at least -march=i486. Many toolchains
 # use i686 as default anyway, but for those that don't, an explicit
@@ -2784,17 +2784,26 @@ if test "$modules" = yes; then
     glib_modules="$glib_modules gmodule-2.0"
 fi
 
-for i in $glib_modules; do
-    if $pkg_config --atleast-version=$glib_req_ver $i; then
-        glib_cflags=`$pkg_config --cflags $i`
-        glib_libs=`$pkg_config --libs $i`
-        CFLAGS="$glib_cflags $CFLAGS"
-        LIBS="$glib_libs $LIBS"
-        libs_qga="$glib_libs $libs_qga"
-    else
-        error_exit "glib-$glib_req_ver $i is required to compile QEMU"
-    fi
-done
+glib_pkg_config()
+{
+  if $pkg_config --atleast-version=$glib_req_ver $1; then
+    local probe_cflags
+    local probe_libs
+    probe_cflags=$($pkg_config --cflags $1)
+    probe_libs=$($pkg_config --libs $1)
+    CFLAGS="$probe_cflags $CFLAGS"
+    LIBS="$probe_libs $LIBS"
+    libs_qga="$probe_libs $libs_qga"
+    glib_cflags="$probe_cflags $glib_cflags"
+    glib_libs="$probe_libs $glib_libs"
+    return 0
+  else
+    return 1
+  fi
+}
+
+glib_pkg_config gthread-2.0 || \
+  error_exit "glib-$glib_req_ver gthread-2.0 is required to compile QEMU"
 
 # g_test_trap_subprocess added in 2.38. Used by some tests.
 glib_subprocess=yes
@@ -2815,19 +2824,57 @@ if ! compile_prog "$glib_cflags -Werror" "$glib_libs" ; then
 fi
 
 ##########################################
-# SHA command probe for modules
-if test "$modules" = yes; then
-    shacmd_probe="sha1sum sha1 shasum"
-    for c in $shacmd_probe; do
-        if has $c; then
-            shacmd="$c"
-            break
-        fi
-    done
-    if test "$shacmd" = ""; then
-        error_exit "one of the checksum commands is required to enable modules: $shacmd_probe"
+# SHA command and gmodule-2.0 probe for modules
+# return 0 if probe succeeds
+# $1: true - force mode, exit if probe fail
+#     false - optoinal mode, return 1 if probe fail
+module_try_enable()
+{
+  force=$1
+  if test "$static" = "yes"; then
+    if $force; then
+      error_exit "static and modules are mutually incompatible"
+    else
+      modules="no"
+      return
     fi
-fi
+  fi
+  shacmd_probe="sha1sum sha1 shasum"
+  for c in $shacmd_probe; do
+    if has $c; then
+      shacmd="$c"
+      break
+    fi
+  done
+  if test "$shacmd" = ""; then
+    if $force; then
+      error_exit "one of the checksum commands is required to enable modules: $shacmd_probe"
+    else
+      modules="no"
+      return
+    fi
+  fi
+  if ! glib_pkg_config gmodule-2.0; then
+    if $force; then
+      error_exit "glib-$glib_req_ver gmodule-2.0 is required to compile QEMU"
+    else
+      modules="no"
+      return
+    fi
+  fi
+  modules="yes"
+}
+
+case "$modules" in
+  yes)
+    module_try_enable true
+    ;;
+  "")
+    module_try_enable false
+    ;;
+  no)
+    ;;
+esac
 
 ##########################################
 # pixman support probe
-- 
2.4.3

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [Qemu-devel] [PULL v2 00/20] SCSI, build, TCG, RCU, misc patches for 2015-08-12
  2015-08-14 13:03 [Qemu-devel] [PULL v2 00/20] SCSI, build, TCG, RCU, misc patches for 2015-08-12 Paolo Bonzini
  2015-08-14 13:03 ` [Qemu-devel] [PULL v2 09/20] configure: Default to enable module build Paolo Bonzini
@ 2015-08-14 13:53 ` Peter Maydell
  2015-08-14 14:21   ` Paolo Bonzini
  1 sibling, 1 reply; 6+ messages in thread
From: Peter Maydell @ 2015-08-14 13:53 UTC (permalink / raw)
  To: Paolo Bonzini; +Cc: QEMU Developers

On 14 August 2015 at 14:03, Paolo Bonzini <pbonzini@redhat.com> wrote:
> The following changes since commit cb48f67ad8c7b33c617d4f8144a27706e69fd688:
>
>   bsd-user: Fix operand to cpu_x86_exec (2015-07-30 12:38:49 +0100)
>
> are available in the git repository at:
>
>   git://github.com/bonzini/qemu.git tags/for-upstream
>
> for you to fetch changes up to 2dfebe37e6210278cddd070761ee543f49a8a82d:
>
>   disas: Defeature print_target_address (2015-08-13 11:33:35 +0200)
>
> ----------------------------------------------------------------
> * SCSI fixes from Stefan and Fam
> * vhost-scsi fix from Igor and Lu Lina
> * a build system fix from Daniel
> * two more multi-arch-related patches from Peter C.
> * TCG patches from myself and Sergey Fedorov
> * RCU improvement from Wen Congyang
> * enabling module builds by default
> * a few more simple cleanups

Hi; I'm afraid this failed to build on my w32 config:

/home/petmay01/linaro/qemu-for-merges/block/dmg.c:1: warning: -fPIC
ignored for target (all code is position independent)

(I have warnings-are-errors enabled.)

thanks
-- PMM

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Qemu-devel] [PULL v2 00/20] SCSI, build, TCG, RCU, misc patches for 2015-08-12
  2015-08-14 13:53 ` [Qemu-devel] [PULL v2 00/20] SCSI, build, TCG, RCU, misc patches for 2015-08-12 Peter Maydell
@ 2015-08-14 14:21   ` Paolo Bonzini
  2015-08-14 14:25     ` Paolo Bonzini
  2015-08-14 14:26     ` Peter Maydell
  0 siblings, 2 replies; 6+ messages in thread
From: Paolo Bonzini @ 2015-08-14 14:21 UTC (permalink / raw)
  To: Peter Maydell; +Cc: QEMU Developers



On 14/08/2015 15:53, Peter Maydell wrote:
> Hi; I'm afraid this failed to build on my w32 config:
> 
> /home/petmay01/linaro/qemu-for-merges/block/dmg.c:1: warning: -fPIC
> ignored for target (all code is position independent)
> 
> (I have warnings-are-errors enabled.)

This is a very weird warning, also warnings-are-errors does not build
for me with Win32.

Paolo

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Qemu-devel] [PULL v2 00/20] SCSI, build, TCG, RCU, misc patches for 2015-08-12
  2015-08-14 14:21   ` Paolo Bonzini
@ 2015-08-14 14:25     ` Paolo Bonzini
  2015-08-14 14:26     ` Peter Maydell
  1 sibling, 0 replies; 6+ messages in thread
From: Paolo Bonzini @ 2015-08-14 14:25 UTC (permalink / raw)
  To: Peter Maydell; +Cc: QEMU Developers



On 14/08/2015 16:21, Paolo Bonzini wrote:
> 
> 
> On 14/08/2015 15:53, Peter Maydell wrote:
>> Hi; I'm afraid this failed to build on my w32 config:
>>
>> /home/petmay01/linaro/qemu-for-merges/block/dmg.c:1: warning: -fPIC
>> ignored for target (all code is position independent)
>>
>> (I have warnings-are-errors enabled.)
> 
> This is a very weird warning, also warnings-are-errors does not build
> for me with Win32.

Having googled about it, I will have to submit v3.  The warning is
totally idiotic, to the point that I might make an exception to the
usual "attack code, not people" rule.

Paolo

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Qemu-devel] [PULL v2 00/20] SCSI, build, TCG, RCU, misc patches for 2015-08-12
  2015-08-14 14:21   ` Paolo Bonzini
  2015-08-14 14:25     ` Paolo Bonzini
@ 2015-08-14 14:26     ` Peter Maydell
  1 sibling, 0 replies; 6+ messages in thread
From: Peter Maydell @ 2015-08-14 14:26 UTC (permalink / raw)
  To: Paolo Bonzini; +Cc: QEMU Developers

On 14 August 2015 at 15:21, Paolo Bonzini <pbonzini@redhat.com> wrote:
>
>
> On 14/08/2015 15:53, Peter Maydell wrote:
>> Hi; I'm afraid this failed to build on my w32 config:
>>
>> /home/petmay01/linaro/qemu-for-merges/block/dmg.c:1: warning: -fPIC
>> ignored for target (all code is position independent)
>>
>> (I have warnings-are-errors enabled.)
>
> This is a very weird warning, also warnings-are-errors does not build
> for me with Win32.

I agree it's a bit weird, but there it is. Even if we don't
have warnings-as-errors we don't want a warning line for
every .c-to-.o compilation...

I think some mingw setups still emit warnings, but I've
been able to get to the point with the setup I use for
build tests where I can build with -Werror in the --extra-cflags
string.

-- PMM

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2015-08-14 14:27 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-08-14 13:03 [Qemu-devel] [PULL v2 00/20] SCSI, build, TCG, RCU, misc patches for 2015-08-12 Paolo Bonzini
2015-08-14 13:03 ` [Qemu-devel] [PULL v2 09/20] configure: Default to enable module build Paolo Bonzini
2015-08-14 13:53 ` [Qemu-devel] [PULL v2 00/20] SCSI, build, TCG, RCU, misc patches for 2015-08-12 Peter Maydell
2015-08-14 14:21   ` Paolo Bonzini
2015-08-14 14:25     ` Paolo Bonzini
2015-08-14 14:26     ` Peter Maydell

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 NNTP newsgroup(s).