qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Claudio Fontana <cfontana@suse.de>
To: Peter Maydell <peter.maydell@linaro.org>,
	Paolo Bonzini <pbonzini@redhat.com>
Cc: QEMU Developers <qemu-devel@nongnu.org>
Subject: Re: [PULL 00/53] Misc patches for QEMU 5.1 soft freeze
Date: Wed, 8 Jul 2020 18:13:25 +0200	[thread overview]
Message-ID: <1a9ad36f-f4ae-2ea5-3d69-03aa5580b60e@suse.de> (raw)
In-Reply-To: <CAFEAcA-F1FGde+=c3iS3wcRWG+i0RgYj5-jwafn0sX6EEYEsWA@mail.gmail.com>

On 7/7/20 8:37 PM, Peter Maydell wrote:
> On Mon, 6 Jul 2020 at 17:48, Paolo Bonzini <pbonzini@redhat.com> wrote:
>>
>> The following changes since commit fc1bff958998910ec8d25db86cd2f53ff125f7ab:
>>
>>   hw/misc/pca9552: Add missing TypeInfo::class_size field (2020-06-29 21:16:10 +0100)
>>
>> are available in the Git repository at:
>>
>>   git://github.com/bonzini/qemu.git tags/for-upstream
>>
>> for you to fetch changes up to 80270507070ec73ea82741ce24cb7909a9258ea3:
>>
>>   scripts: improve message when TAP based tests fail (2020-07-06 12:14:25 -0400)
>>
>> ----------------------------------------------------------------
>> * Make checkpatch say 'qemu' instead of 'kernel' (Aleksandar)
>> * Fix PSE guests with emulated NPT (Alexander B. #1)
>> * Fix leak (Alexander B. #2)
>> * HVF fixes (Roman, Cameron)
>> * New Sapphire Rapids CPUID bits (Cathy)
>> * cpus.c and softmmu/ cleanups (Claudio)
>> * TAP driver tweaks (Daniel, Havard)
>> * object-add bugfix and testcases (Eric A.)
>> * Fix Coverity MIN_CONST and MAX_CONST (Eric B.)
>> * SSE fixes (Joseph)
>> * "-msg guest-name" option (Mario)
>> * support for AMD nested live migration (myself)
>> * Small i386 TCG fixes (myself)
>> * improved error reporting for Xen (myself)
>> * fix "-cpu host -overcommit cpu-pm=on" (myself)
>> * Add accel/Kconfig (Philippe)
>> * KVM API cleanup (Philippe)
>> * iscsi sense handling fixes (Yongji)
>> * Misc bugfixes
> 
> Hi; various build or test failures (5 total):
> 
> 1) OSX:
> 
> /Users/pm215/src/qemu-for-merges/ui/cocoa.m:1478:9: error: implicit
> declaration of function 'cpu_throttle_set' is invalid in C99 [-
> Werror,-Wimplicit-function-declaration]
>         cpu_throttle_set(throttle_pct);
>         ^
> 
> 2) aarch64 and aarch32 linux:
> 
> /home/pm/qemu/target/arm/kvm.c: In function ‘kvm_arch_init’:
> /home/pm/qemu/target/arm/kvm.c:248:29: error: passing argument 1 of
> ‘kvm_check_extension’ makes integer from pointer without a cast
>  [-Werror=int-conversion]
>   248 |     if (kvm_check_extension(s, KVM_CAP_ARM_NISV_TO_USER)) {
>       |                             ^
>       |                             |
>       |                             KVMState * {aka struct KVMState *}
> In file included from /home/pm/qemu/target/arm/kvm.c:23:
> /home/pm/qemu/include/sysemu/kvm.h:439:38: note: expected ‘unsigned
> int’ but argument is of type ‘KVMState *’ {aka ‘struct KVMState
>  *’}
>   439 | int kvm_check_extension(unsigned int extension);
>       |                         ~~~~~~~~~~~~~^~~~~~~~~
> /home/pm/qemu/target/arm/kvm.c:248:9: error: too many arguments to
> function ‘kvm_check_extension’
>   248 |     if (kvm_check_extension(s, KVM_CAP_ARM_NISV_TO_USER)) {
>       |         ^~~~~~~~~~~~~~~~~~~
> In file included from /home/pm/qemu/target/arm/kvm.c:23:
> /home/pm/qemu/include/sysemu/kvm.h:439:5: note: declared here
>   439 | int kvm_check_extension(unsigned int extension);
>       |     ^~~~~~~~~~~~~~~~~~~
> /home/pm/qemu/target/arm/kvm.c:253:59: error: passing argument 1 of
> ‘kvm_check_extension’ makes integer from pointer without a cast
>  [-Werror=int-conversion]
>   253 |             cap_has_inject_ext_dabt = kvm_check_extension(s,
>       |                                                           ^
>       |                                                           |
>       |
> KVMState * {aka struct KVMState *}
> In file included from /home/pm/qemu/target/arm/kvm.c:23:
> /home/pm/qemu/include/sysemu/kvm.h:439:38: note: expected ‘unsigned
> int’ but argument is of type ‘KVMState *’ {aka ‘struct KVMState
>  *’}
>   439 | int kvm_check_extension(unsigned int extension);
>       |                         ~~~~~~~~~~~~~^~~~~~~~~
> /home/pm/qemu/target/arm/kvm.c:253:39: error: too many arguments to
> function ‘kvm_check_extension’
>   253 |             cap_has_inject_ext_dabt = kvm_check_extension(s,
>       |                                       ^~~~~~~~~~~~~~~~~~~
> In file included from /home/pm/qemu/target/arm/kvm.c:23:
> /home/pm/qemu/include/sysemu/kvm.h:439:5: note: declared here
>   439 | int kvm_check_extension(unsigned int extension);
>       |     ^~~~~~~~~~~~~~~~~~~
> 
> 3) PPC64 had a failure on iotest 030 (though I think this may
> be an intermittent in master):
> 
>   TEST    iotest-qcow2: 030 [fail]
> QEMU          --
> "/home/pm215/qemu/build/all/tests/qemu-iotests/../../ppc64-softmmu/qemu-system-ppc64"
> -nodefaults -display none -accel qtest
> QEMU_IMG      -- "/home/pm215/qemu/build/all/tests/qemu-iotests/../../qemu-img"
> QEMU_IO       --
> "/home/pm215/qemu/build/all/tests/qemu-iotests/../../qemu-io"  --cache
> writeback --aio threads -f qcow2
> QEMU_NBD      -- "/home/pm215/qemu/build/all/tests/qemu-iotests/../../qemu-nbd"
> IMGFMT        -- qcow2 (compat=1.1)
> IMGPROTO      -- file
> PLATFORM      -- Linux/ppc64 gcc1-power7 3.10.0-862.14.4.el7.ppc64
> TEST_DIR      -- /home/pm215/qemu/build/all/tests/qemu-iotests/scratch
> SOCK_DIR      -- /tmp/tmp.icAW30swbG
> SOCKET_SCM_HELPER --
> /home/pm215/qemu/build/all/tests/qemu-iotests/socket_scm_helper
> 
> --- /home/pm215/qemu/tests/qemu-iotests/030.out 2019-07-15
> 15:12:04.941863802 +0000
> +++ /home/pm215/qemu/build/all/tests/qemu-iotests/030.out.bad
> 2020-07-07 18:01:06.975652394 +0000
> @@ -1,5 +1,17 @@
> -...........................
> +.............F.............
> +======================================================================
> +FAIL: test_stream_parallel (__main__.TestParallelOps)
> +----------------------------------------------------------------------
> +Traceback (most recent call last):
> +  File "030", line 246, in test_stream_parallel
> +    self.assert_qmp(result, 'return', {})
> +  File "/home/pm215/qemu/tests/qemu-iotests/iotests.py", line 848, in
> assert_qmp
> +    result = self.dictpath(d, path)
> +  File "/home/pm215/qemu/tests/qemu-iotests/iotests.py", line 822, in dictpath
> +    self.fail(f'failed path traversal for "{path}" in "{d}"')
> +AssertionError: failed path traversal for "return" in "{'error':
> {'class': 'DeviceNotActive', 'desc': "Block job 'stream-node8' not
> found"}}"
> +
>  ----------------------------------------------------------------------
>  Ran 27 tests
> 
> -OK
> +FAILED (failures=1)
> 
> 4) s390x failed on iotest 267:
> 
>   TEST    iotest-qcow2: 267 [fail]
> QEMU          --
> "/home/ubuntu/qemu/build/all/tests/qemu-iotests/../../s390x-softmmu/qemu-system-s390x"
> -nodefaults -display none -accel qtest
> QEMU_IMG      -- "/home/ubuntu/qemu/build/all/tests/qemu-iotests/../../qemu-img"
> QEMU_IO       --
> "/home/ubuntu/qemu/build/all/tests/qemu-iotests/../../qemu-io"
> --cache writeback --aio threads -f qcow2
> QEMU_NBD      -- "/home/ubuntu/qemu/build/all/tests/qemu-iotests/../../qemu-nbd"
> IMGFMT        -- qcow2 (compat=1.1)
> IMGPROTO      -- file
> PLATFORM      -- Linux/s390x qemu01 4.15.0-72-generic
> TEST_DIR      -- /home/ubuntu/qemu/build/all/tests/qemu-iotests/scratch
> SOCK_DIR      -- /tmp/tmp.REW8Sy64t9
> SOCKET_SCM_HELPER --
> /home/ubuntu/qemu/build/all/tests/qemu-iotests/socket_scm_helper
> 
> --- /home/ubuntu/qemu/tests/qemu-iotests/267.out        2019-12-19
> 08:32:33.382319918 -0500
> +++ /home/ubuntu/qemu/build/all/tests/qemu-iotests/267.out.bad
> 2020-07-07 14:15:44.173300793 -0400
> @@ -137,6 +137,9 @@
>  ID        TAG                 VM SIZE                DATE       VM CLOCK
>  --        snap0                  SIZE yyyy-mm-dd hh:mm:ss   00:00:00.000
>  (qemu) loadvm snap0
> +Unexpected storage key flag data: 0
> +error while loading state for instance 0x0 of device 's390-skeys'
> +Error: Error -22 while loading VM state
>  (qemu) quit
> 
>  Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
> backing_file=TEST_DIR/t.IMGFMT.base
> 
> 5) And a link error on x86-64 Linux:
> 
>   LINK    x86_64-softmmu/qemu-system-x86_64
> softmmu/cpus.o: In function `tcg_get_icount_limit':
> /home/petmay01/linaro/qemu-for-merges/softmmu/cpus.c:563: undefined
> reference to `icount_round'
> softmmu/cpus.o: In function `process_icount_data':
> /home/petmay01/linaro/qemu-for-merges/softmmu/cpus.c:618: undefined
> reference to `icount_update'
> target/i386/helper.o: In function `x86_cpu_dump_state':
> /home/petmay01/linaro/qemu-for-merges/target/i386/helper.c:547:
> undefined reference to `update_mxcsr_from_sse_status'
> target/i386/gdbstub.o: In function `x86_cpu_gdb_read_register':
> /home/petmay01/linaro/qemu-for-merges/target/i386/gdbstub.c:187:
> undefined reference to `update_mxcsr_from_sse_status'
> collect2: error: ld returned 1 exit status
> Makefile:205: recipe for target 'qemu-system-x86_64' failed
> 
> thanks
> -- PMM
> 

Hi Peter, Paolo,

I am trying to understand this failure (5), which is triggered by one of my patches,
containing clearly an issue that does not trigger here, although it is apparent to me (I did not provide all necessary stubs).

Could you provide the ./configure command line, config.status, compiler version?

Clearly it is something I have to fix, but would help to be able not to be "blind".

The patch introducing icount_round and icount_update is

"cpu-timers, icount: new modules",

and the issue stems I think from the fact that cpus.c references

icount_round() and icount_update() in code that is conditional on icount_enabled().

If the code is configured with --disable-tcg, in stubs/icount.c , icount_enabled is defined as always returning 0,
and my compiler takes that clue and elides all static functions conditional on that return value,

so I don't get any tcg_get_icount_limit() compiled in, and no errors.

I think that having comparable configure command line and compiler version/flags would help me pin down any related issue.

Thanks,

Claudio








  parent reply	other threads:[~2020-07-08 16:15 UTC|newest]

Thread overview: 76+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-06 16:41 [PULL 00/53] Misc patches for QEMU 5.1 soft freeze Paolo Bonzini
2020-07-06 16:41 ` [PULL 01/53] tcg/svm: use host cr4 during NPT page table walk Paolo Bonzini
2020-07-06 16:41 ` [PULL 02/53] tests: Inject test name also when the test fails Paolo Bonzini
2020-07-06 16:41 ` [PULL 03/53] util/qemu-error: prepend guest name to error message to identify affected VM owner Paolo Bonzini
2020-07-06 16:41 ` [PULL 04/53] qom: Introduce object_property_try_add_child() Paolo Bonzini
2020-07-06 16:41 ` [PULL 05/53] tests/qmp-cmd-test: Add qmp/object-add-duplicate-id Paolo Bonzini
2020-07-06 16:41 ` [PULL 06/53] tests/qmp-cmd-test: Add qmp/object-add-failure-modes Paolo Bonzini
2020-07-06 16:41 ` [PULL 07/53] hw/core/null-machine: Do not initialize unused chardev backends Paolo Bonzini
2020-07-06 16:41 ` [PULL 08/53] target/i386: set SSE FTZ in correct floating-point state Paolo Bonzini
2020-07-06 16:41 ` [PULL 09/53] target/i386: fix IEEE SSE floating-point exception raising Paolo Bonzini
2020-07-06 16:41 ` [PULL 10/53] KVM: add support for AMD nested live migration Paolo Bonzini
2020-07-06 16:41 ` [PULL 11/53] coverity: provide Coverity-friendly MIN_CONST and MAX_CONST Paolo Bonzini
2020-07-06 16:41 ` [PULL 12/53] i386: hvf: Set env->eip in macvm_set_rip() Paolo Bonzini
2020-07-06 16:41 ` [PULL 13/53] i386: hvf: Move synchronize functions to sysemu Paolo Bonzini
2020-07-06 16:41 ` [PULL 14/53] i386: hvf: Add hvf_cpu_synchronize_pre_loadvm() Paolo Bonzini
2020-07-06 16:41 ` [PULL 15/53] i386: hvf: Make long mode enter and exit clearer Paolo Bonzini
2020-07-06 16:41 ` [PULL 16/53] i386: hvf: Move Guest LMA reset to macvm_set_cr0() Paolo Bonzini
2020-07-06 16:41 ` [PULL 17/53] i386: hvf: Don't duplicate register reset Paolo Bonzini
2020-07-06 16:41 ` [PULL 18/53] i386: hvf: Clean up synchronize functions Paolo Bonzini
2020-07-06 16:41 ` [PULL 19/53] MAINTAINERS: Add Cameron as HVF co-maintainer Paolo Bonzini
2020-07-06 16:41 ` [PULL 20/53] MAINTAINERS: Fix KVM path expansion glob Paolo Bonzini
2020-07-06 16:41 ` [PULL 21/53] MAINTAINERS: Add an 'overall' entry for accelerators Paolo Bonzini
2020-07-06 16:41 ` [PULL 22/53] MAINTAINERS: Cover the HAX accelerator stub Paolo Bonzini
2020-07-06 16:41 ` [PULL 23/53] Makefile: Remove dangerous EOL trailing backslash Paolo Bonzini
2020-07-06 16:41 ` [PULL 24/53] Makefile: Write MINIKCONF variables as one entry per line Paolo Bonzini
2020-07-06 16:41 ` [PULL 25/53] accel/Kconfig: Extract accel selectors into their own config Paolo Bonzini
2020-07-06 16:41 ` [PULL 26/53] accel/Kconfig: Add the TCG selector Paolo Bonzini
2020-07-06 16:41 ` [PULL 27/53] accel/tcg: Add stub for probe_access() Paolo Bonzini
2020-07-06 16:41 ` [PULL 28/53] Makefile: simplify MINIKCONF rules Paolo Bonzini
2020-07-17 11:02   ` Peter Maydell
2020-07-17 11:20     ` Paolo Bonzini
2020-07-17 13:01       ` Peter Maydell
2020-07-17 13:33         ` Paolo Bonzini
2020-07-06 16:41 ` [PULL 29/53] target/i386: remove gen_io_end Paolo Bonzini
2020-07-06 16:41 ` [PULL 30/53] target/i386: implement undocumented "smsw r32" behavior Paolo Bonzini
2020-07-06 16:41 ` [PULL 31/53] KVM: x86: believe what KVM says about WAITPKG Paolo Bonzini
2020-07-07 11:42   ` Maxim Levitsky
2020-07-07 11:58     ` Paolo Bonzini
2021-12-22  9:35   ` Chenyi Qiang
2020-07-06 16:41 ` [PULL 32/53] target/i386: sev: provide proper error reporting for query-sev-capabilities Paolo Bonzini
2020-07-06 16:41 ` [PULL 33/53] target/i386: sev: fail query-sev-capabilities if QEMU cannot use SEV Paolo Bonzini
2020-07-06 16:41 ` [PULL 34/53] iscsi: handle check condition status in retry loop Paolo Bonzini
2020-07-06 16:41 ` [PULL 35/53] iscsi: return -EIO when sense fields are meaningless Paolo Bonzini
2020-07-06 16:41 ` [PULL 36/53] chardev/tcp: fix error message double free error Paolo Bonzini
2020-07-06 16:41 ` [PULL 37/53] checkpatch: Change occurences of 'kernel' to 'qemu' in user messages Paolo Bonzini
2020-07-06 16:41 ` [PULL 38/53] target/i386: Correct the warning message of Intel PT Paolo Bonzini
2020-07-06 16:41 ` [PULL 39/53] cpus: Move CPU code from exec.c to cpus-common.c Paolo Bonzini
2020-07-06 16:41 ` [PULL 40/53] pc: fix leak in pc_system_flash_cleanup_unused Paolo Bonzini
2020-07-06 16:41 ` [PULL 41/53] softmmu: move softmmu only files from root Paolo Bonzini
2020-07-06 16:41 ` [PULL 42/53] cpu-throttle: new module, extracted from cpus.c Paolo Bonzini
2020-07-06 16:41 ` [PULL 43/53] cpu-timers, icount: new modules Paolo Bonzini
2020-07-06 16:41 ` [PULL 44/53] softmmu/vl: Remove the check for colons in -accel parameters Paolo Bonzini
2020-07-06 16:41 ` [PULL 45/53] accel/kvm: Let kvm_check_extension use global KVM state Paolo Bonzini
2020-07-06 16:41 ` [PULL 46/53] accel/kvm: Simplify kvm_check_extension() Paolo Bonzini
2020-07-06 16:41 ` [PULL 47/53] accel/kvm: Simplify kvm_check_extension_list() Paolo Bonzini
2020-07-06 16:41 ` [PULL 48/53] target/i386/kvm: Simplify get_para_features() Paolo Bonzini
2020-07-06 16:41 ` [PULL 49/53] target/i386/kvm: Simplify kvm_get_mce_cap_supported() Paolo Bonzini
2020-07-06 16:41 ` [PULL 50/53] target/i386/kvm: Simplify kvm_get_supported_[feature]_msrs() Paolo Bonzini
2020-07-06 16:41 ` [PULL 51/53] target/i386: Add SERIALIZE cpu feature Paolo Bonzini
2020-07-06 16:41 ` [PULL 52/53] target/i386: Enable TSX Suspend Load Address Tracking feature Paolo Bonzini
2020-07-06 16:41 ` [PULL 53/53] scripts: improve message when TAP based tests fail Paolo Bonzini
2020-07-06 17:19 ` [PULL 00/53] Misc patches for QEMU 5.1 soft freeze no-reply
2020-07-07 18:37 ` Peter Maydell
2020-07-07 18:42   ` Peter Maydell
2020-07-07 18:48     ` Paolo Bonzini
2020-07-08  8:25   ` Philippe Mathieu-Daudé
2020-07-08 16:13   ` Claudio Fontana [this message]
2020-07-08 16:16     ` Paolo Bonzini
2020-07-08 16:45       ` Claudio Fontana
2020-07-08 16:55         ` Paolo Bonzini
2020-07-08 17:03           ` Claudio Fontana
2020-07-08 18:25             ` Claudio Fontana
2020-07-08 18:34               ` Claudio Fontana
2020-07-08 18:41               ` Paolo Bonzini
2020-07-09  6:59                 ` Claudio Fontana
2020-07-09  9:57                   ` Paolo Bonzini

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=1a9ad36f-f4ae-2ea5-3d69-03aa5580b60e@suse.de \
    --to=cfontana@suse.de \
    --cc=pbonzini@redhat.com \
    --cc=peter.maydell@linaro.org \
    --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 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).