- 23 5月, 2015 15 次提交
-
-
由 John Snow 提交于
Where it makes sense, use the new faster primitives. For generally small reads/writes such as for the PRDT and FIS packets, stick with the more wasteful but easier to debug memread/memwrite. For ahci-test (before migration tests): With this patch: real 0m3.675s user 0m2.582s sys 0m1.718s Without any qtest protocol improvements: real 0m14.171s user 0m12.072s sys 0m12.527s Signed-off-by: NJohn Snow <jsnow@redhat.com> Message-id: 1430864578-22072-6-git-send-email-jsnow@redhat.com
-
由 John Snow 提交于
Previously, memset was just a frontend to write() and only stupidly sent the pattern many times across the wire. Let's not discuss who stupidly wrote it like that in the first place. (Hint: It was me.) Signed-off-by: NJohn Snow <jsnow@redhat.com> Message-id: 1430864578-22072-4-git-send-email-jsnow@redhat.com
-
由 John Snow 提交于
For larger pieces of data that won't need to be debugged and viewing the hex nibbles is unlikely to be useful, we can encode data using base64 instead of encoding each byte as %02x, which leads to some space savings and faster reads/writes. For now, the default is left as hex nibbles in memwrite() and memread(). For the purposes of making qtest io easier to read and debug, some callers may want to specify using the old encoding format for small patches of data where the savings from base64 wouldn't be that profound. memwrite/memread use a data encoding that takes 2x the size of the original buffer, but base64 uses "only" (4/3)x, so for larger buffers we can save a decent amount of time and space. Signed-off-by: NJohn Snow <jsnow@redhat.com> Message-id: 1430864578-22072-3-git-send-email-jsnow@redhat.com
-
由 John Snow 提交于
qtest currently has a static buffer of size 1024 that if we overflow, ignores the additional data silently which leads to hangs or stream failures. Use glib's string facilities to allow arbitrarily long data, but split this off into a new function, qtest_sendf. Static data can still be sent using qtest_send, which avoids the malloc/copy overhead. Signed-off-by: NJohn Snow <jsnow@redhat.com> Reviewed-by: NEric Blake <eblake@redhat.com> Message-id: 1430864578-22072-2-git-send-email-jsnow@redhat.com
-
由 John Snow 提交于
Test migrating a halted DMA transaction. Resume, then test data integrity. Signed-off-by: NJohn Snow <jsnow@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Message-id: 1430417242-11859-10-git-send-email-jsnow@redhat.com
-
由 John Snow 提交于
If we're going to test the migration of halted DMA jobs, we should probably check to make sure we can resume them locally as a first step. Signed-off-by: NJohn Snow <jsnow@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Message-id: 1430417242-11859-9-git-send-email-jsnow@redhat.com
-
由 John Snow 提交于
Use blkdebug to inject an error on first flush, then attempt to flush on the first guest. When the error halts the VM, migrate to the second VM, and attempt to resume the command. Signed-off-by: NJohn Snow <jsnow@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Message-id: 1430417242-11859-8-git-send-email-jsnow@redhat.com
-
由 John Snow 提交于
Write to one guest, migrate, and then read from the other. adjust ahci_io to clear any buffers it creates, so that we can use ahci_io safely on both guests knowing we are using empty buffers and not accidentally re-using data. Signed-off-by: NJohn Snow <jsnow@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Message-id: 1430417242-11859-7-git-send-email-jsnow@redhat.com
-
由 John Snow 提交于
Notes: * The migration is performed on QOSState objects. * The migration is performed in such a way that it does not assume consistency between the allocators attached to each. That is to say, you can use each QOSState object completely independently and then at an arbitrary point decide to migrate, and the destination object will now be consistent with the memory within the source guest. The source object that was migrated from will have a completely blank allocator. ahci-test.c: - verify_state is added - ahci_migrate is added as a frontend to migrate - test_migrate_sanity test case is added. Signed-off-by: NJohn Snow <jsnow@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Message-id: 1430417242-11859-6-git-send-email-jsnow@redhat.com
-
由 John Snow 提交于
Lift the flag preventing the migration of the ICH9/AHCI devices. Signed-off-by: NJohn Snow <jsnow@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Message-id: 1430417242-11859-5-git-send-email-jsnow@redhat.com
-
由 John Snow 提交于
libqos.c: -set_context for addressing which commands go where -migrate performs the actual migration malloc.c: - Structure of the allocator is adjusted slightly with a second-tier malloc to make swapping around the allocators easy when we "migrate" the lists from the source to the destination. Signed-off-by: NJohn Snow <jsnow@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Message-id: 1430417242-11859-4-git-send-email-jsnow@redhat.com
-
由 John Snow 提交于
|| probably does not mean the same thing as |. Additionally, allow users to submit a prd_size of 0 to indicate that they'd like to continue using the default. Signed-off-by: NJohn Snow <jsnow@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Message-id: 1430417242-11859-3-git-send-email-jsnow@redhat.com
-
由 John Snow 提交于
Sometimes we want a command to halt the VM instead of complete successfully, so it'd be nice to let the libqos/ahci functions cope with such scenarios. Signed-off-by: NJohn Snow <jsnow@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Message-id: 1430417242-11859-2-git-send-email-jsnow@redhat.com
-
由 John Snow 提交于
Since we're bumping the version to 2.22+, remove the now-stale compat functions. Signed-off-by: NJohn Snow <jsnow@redhat.com> Reviewed-by: NMarkus Armbruster <armbru@redhat.com> Reviewed-by: NAlex Bennée <alex.bennee@linaro.org> Message-id: 1431469140-22208-2-git-send-email-jsnow@redhat.com
-
由 John Snow 提交于
This provides g_ptr_array_new_with_free_func, as well as a few other functions that we've been hacking around in glib-compat.h. Cleaning up the compatibility headers will come later. Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Signed-off-by: NJohn Snow <jsnow@redhat.com> Reviewed-by: NMarkus Armbruster <armbru@redhat.com> Reviewed-by: NAlex Bennée <alex.bennee@linaro.org> Message-id: 1431469140-22208-2-git-send-email-jsnow@redhat.com
-
- 22 5月, 2015 25 次提交
-
-
由 Peter Maydell 提交于
TriCore v1.6.1 ISA and missing v1.6 instructions # gpg: Signature made Fri May 22 16:02:45 2015 BST using RSA key ID 6B69CA14 # gpg: Good signature from "Bastian Koppelmann <kbastian@mail.uni-paderborn.de>" * remotes/bkoppelmann/tags/pull-tricore-20150522: target-tricore: add RR_DIV and RR_DIV_U instructions of the v1.6 ISA target-tricore: add FRET instructions of the v1.6 ISA target-tricore: add FCALL instructions of the v1.6 ISA target-tricore: add SYS_RESTORE instruction of the v1.6 ISA target-tricore: add RR_CRC32 instruction of the v1.6.1 ISA target-tricore: add SWAPMSK instructions of the v1.6.1 ISA target-tricore: add CMPSWP instructions of the v1.6.1 ISA target-tricore: Add SRC_MOV_E instruction of the v1.6 ISA target-tricore: introduce ISA v1.6.1 feature target-tricore: Add ISA v1.3.1 cpu and fix tc1796 to using v1.3 Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
-
由 Bastian Koppelmann 提交于
Signed-off-by: NBastian Koppelmann <kbastian@mail.uni-paderborn.de> Reviewed-by: NRichard Henderson <rth@twiddle.net>
-
由 Bastian Koppelmann 提交于
Signed-off-by: NBastian Koppelmann <kbastian@mail.uni-paderborn.de> Reviewed-by: NRichard Henderson <rth@twiddle.net>
-
由 Bastian Koppelmann 提交于
Signed-off-by: NBastian Koppelmann <kbastian@mail.uni-paderborn.de> Reviewed-by: NRichard Henderson <rth@twiddle.net>
-
由 Bastian Koppelmann 提交于
Signed-off-by: NBastian Koppelmann <kbastian@mail.uni-paderborn.de> Reviewed-by: NRichard Henderson <rth@twiddle.net>
-
由 Bastian Koppelmann 提交于
This instruction was introduced by the new Aurix platform. Signed-off-by: NBastian Koppelmann <kbastian@mail.uni-paderborn.de> Reviewed-by: NRichard Henderson <rth@twiddle.net>
-
由 Bastian Koppelmann 提交于
Those instruction were introduced in the new Aurix platform. Signed-off-by: NBastian Koppelmann <kbastian@mail.uni-paderborn.de> Reviewed-by: NRichard Henderson <rth@twiddle.net>
-
由 Bastian Koppelmann 提交于
Those instruction were introduced in the new Aurix platform. Signed-off-by: NBastian Koppelmann <kbastian@mail.uni-paderborn.de> Reviewed-by: NRichard Henderson <rth@twiddle.net>
-
由 Bastian Koppelmann 提交于
Signed-off-by: NBastian Koppelmann <kbastian@mail.uni-paderborn.de> Reviewed-by: NRichard Henderson <rth@twiddle.net>
-
由 Bastian Koppelmann 提交于
The aurix platform contains of several different cpu models and uses the 1.6.1 ISA. This patch changes the generic aurix model to the more specific tc27x cpu model and sets specific features. Signed-off-by: NBastian Koppelmann <kbastian@mail.uni-paderborn.de> Reviewed-by: NRichard Henderson <rth@twiddle.net>
-
由 Bastian Koppelmann 提交于
Signed-off-by: NBastian Koppelmann <kbastian@mail.uni-paderborn.de> Reviewed-by: NRichard Henderson <rth@twiddle.net>
-
由 Peter Maydell 提交于
# gpg: Signature made Fri May 22 10:00:53 2015 BST using RSA key ID 81AB73C8 # gpg: Good signature from "Stefan Hajnoczi <stefanha@redhat.com>" # gpg: aka "Stefan Hajnoczi <stefanha@gmail.com>" * remotes/stefanha/tags/block-pull-request: (38 commits) block: get_block_status: use "else" when testing the opposite condition qemu-iotests: Test unaligned sub-block zero write block: Fix NULL deference for unaligned write if qiov is NULL Revert "block: Fix unaligned zero write" block: align bounce buffers to page block: minimal bounce buffer alignment block: return EPERM on writes or discards to read-only devices configure: Add workaround for ccache and clang configure: silence glib unknown attribute __alloc_size__ configure: factor out supported flag check configure: handle clang -nopie argument warning block/parallels: improve image writing performance further block/parallels: optimize linear image expansion block/parallels: add prealloc-mode and prealloc-size open paramemets block/parallels: delay writing to BAT till bdrv_co_flush_to_os block/parallels: create bat_entry_off helper block/parallels: improve image reading performance iotests, parallels: check for incorrectly closed image in tests block/parallels: implement incorrect close detection block/parallels: implement parallels_check method of block driver ... Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
-
由 Peter Maydell 提交于
This reverts commit 32ad48ab. Unfortunately the SSE2 code here fails to compile on some versions of gcc: target-alpha/int_helper.c:77:24: error: invalid operands to binary >= (have '__vector(16) unsigned char' and '__vector(16) unsigned char') Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
-
由 Peter Maydell 提交于
Rewrite fp exceptions # gpg: Signature made Thu May 21 18:35:52 2015 BST using RSA key ID 4DD0279B # gpg: Good signature from "Richard Henderson <rth7680@gmail.com>" # gpg: aka "Richard Henderson <rth@redhat.com>" # gpg: aka "Richard Henderson <rth@twiddle.net>" * remotes/rth/tags/pull-axp-20150521: target-alpha: Add vector implementation for CMPBGE target-alpha: Rewrite helper_zapnot target-alpha: Raise IOV from CVTQL target-alpha: Suppress underflow from CVTTQ if DNZ target-alpha: Raise EXC_M_INV properly for fp inputs target-alpha: Disallow literal operand to 1C.30 to 1C.37 target-alpha: Implement WH64EN target-alpha: Fix integer overflow checking insns target-alpha: Fix cvttq vs inf target-alpha: Fix cvttq vs large integers target-alpha: Raise IOV from CVTTQ target-alpha: Set EXC_M_SWC for exceptions from /S insns target-alpha: Set fpcr_exc_status even for disabled exceptions target-alpha: Tidy FPCR representation target-alpha: Set PC correctly for floating-point exceptions target-alpha: Forget installed round mode after MT_FPCR target-alpha: Rename floating-point subroutines target-alpha: Move VAX helpers to a new file Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
-
由 Paolo Bonzini 提交于
A bit of Boolean algebra (and common sense) tells us that the second "if" here is looking for blocks that are not allocated. This is the opposite of the "if" that sets BDRV_BLOCK_ALLOCATED, and thus it can use an "else". Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Reviewed-by: NEric Blake <eblake@redhat.com> Reviewed-by: NFam Zheng <famz@redhat.com> Message-id: 1431599702-10431-1-git-send-email-pbonzini@redhat.com Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-
由 Fam Zheng 提交于
Test zero write in byte range 512~1024 for 4k alignment. Signed-off-by: NFam Zheng <famz@redhat.com> Reviewed-by: NStefan Hajnoczi <stefanha@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Message-id: 1431522721-3266-4-git-send-email-famz@redhat.com Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-
由 Fam Zheng 提交于
For zero write, callers pass in NULL qiov (qemu-io "write -z" or scsi-disk "write same"). Commit fc3959e4 fixed bdrv_co_write_zeroes which is the common case for this bug, but it still exists in bdrv_aio_write_zeroes. A simpler fix would be in bdrv_co_do_pwritev which is the NULL dereference point and covers both cases. So don't access it in bdrv_co_do_pwritev in this case, use three aligned writes. [Initialize ret to 0 in bdrv_co_do_zero_pwritev() to avoid uninitialized variable warning with gcc 4.9.2. --Stefan] Signed-off-by: NFam Zheng <famz@redhat.com> Message-id: 1431522721-3266-3-git-send-email-famz@redhat.com Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-
由 Fam Zheng 提交于
This reverts commit fc3959e4. The core write code already handles the case, so remove this duplication. Because commit 61007b31 moved the touched code from block.c to block/io.c, the change is manually reverted. Signed-off-by: NFam Zheng <famz@redhat.com> Reviewed-by: NStefan Hajnoczi <stefanha@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Message-id: 1431522721-3266-2-git-send-email-famz@redhat.com Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-
由 Denis V. Lunev 提交于
The following sequence int fd = open(argv[1], O_RDWR | O_CREAT | O_DIRECT, 0644); for (i = 0; i < 100000; i++) write(fd, buf, 4096); performs 5% better if buf is aligned to 4096 bytes. The difference is quite reliable. On the other hand we do not want at the moment to enforce bounce buffering if guest request is aligned to 512 bytes. The patch changes default bounce buffer optimal alignment to MAX(page size, 4k). 4k is chosen as maximal known sector size on real HDD. The justification of the performance improve is quite interesting. From the kernel point of view each request to the disk was split by two. This could be seen by blktrace like this: 9,0 11 1 0.000000000 11151 Q WS 312737792 + 1023 [qemu-img] 9,0 11 2 0.000007938 11151 Q WS 312738815 + 8 [qemu-img] 9,0 11 3 0.000030735 11151 Q WS 312738823 + 1016 [qemu-img] 9,0 11 4 0.000032482 11151 Q WS 312739839 + 8 [qemu-img] 9,0 11 5 0.000041379 11151 Q WS 312739847 + 1016 [qemu-img] 9,0 11 6 0.000042818 11151 Q WS 312740863 + 8 [qemu-img] 9,0 11 7 0.000051236 11151 Q WS 312740871 + 1017 [qemu-img] 9,0 5 1 0.169071519 11151 Q WS 312741888 + 1023 [qemu-img] After the patch the pattern becomes normal: 9,0 6 1 0.000000000 12422 Q WS 314834944 + 1024 [qemu-img] 9,0 6 2 0.000038527 12422 Q WS 314835968 + 1024 [qemu-img] 9,0 6 3 0.000072849 12422 Q WS 314836992 + 1024 [qemu-img] 9,0 6 4 0.000106276 12422 Q WS 314838016 + 1024 [qemu-img] and the amount of requests sent to disk (could be calculated counting number of lines in the output of blktrace) is reduced about 2 times. Both qemu-img and qemu-io are affected while qemu-kvm is not. The guest does his job well and real requests comes properly aligned (to page). Signed-off-by: NDenis V. Lunev <den@openvz.org> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Message-id: 1431441056-26198-3-git-send-email-den@openvz.org CC: Paolo Bonzini <pbonzini@redhat.com> CC: Kevin Wolf <kwolf@redhat.com> CC: Stefan Hajnoczi <stefanha@redhat.com> Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-
由 Denis V. Lunev 提交于
The patch introduces new concept: minimal memory alignment for bounce buffers. Original so called "optimal" value is actually minimal required value for aligment. It should be used for validation that the IOVec is properly aligned and bounce buffer is not required. Though, from the performance point of view, it would be better if bounce buffer or IOVec allocated by QEMU will be aligned stricter. The patch does not change any alignment value yet. Signed-off-by: NDenis V. Lunev <den@openvz.org> Reviewed-by: NKevin Wolf <kwolf@redhat.com> Message-id: 1431441056-26198-2-git-send-email-den@openvz.org CC: Paolo Bonzini <pbonzini@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com> CC: Stefan Hajnoczi <stefanha@redhat.com> Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-
由 Paolo Bonzini 提交于
This is the behavior in the operating system, for example Linux's blkdev_write_iter has the following: if (bdev_read_only(I_BDEV(bd_inode))) return -EPERM; This does not apply to opening a device for read/write, when the device only supports read-only operation. In this case any of EACCES, EPERM or EROFS is acceptable depending on why writing is not possible. Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com> Message-id: 1431013548-22492-1-git-send-email-pbonzini@redhat.com Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-
由 John Snow 提交于
Test if ccache is interfering with semantic analysis of macros, disable its habit of trying to compile already pre-processed versions of code if so. ccache attempts to save time by compiling pre-processed versions of code, but this disturbs clang's static analysis enough to produce false positives. ccache allows us to disable this feature, opting instead to compile the original version instead of its preprocessed version. This makes ccache much slower for cache misses, but at least it becomes usable with QEMU/clang. This workaround only activates for users using ccache AND clang, and only if their configuration is observed to be producing warnings. You may need to clear your ccache for builds started without -Werror, as those may continue to produce warnings from the cache. Thanks to Peter Eisentraut for his writeup on the issue: http://peter.eisentraut.org/blog/2014/12/01/ccache-and-clang-part-3/Signed-off-by: NJohn Snow <jsnow@redhat.com> Reviewed-by: NStefan Hajnoczi <stefanha@redhat.com> Message-id: 1427324259-1481-5-git-send-email-jsnow@redhat.com Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-
由 John Snow 提交于
The glib headers use GCC attributes. Unfortunately the __GNUC__ and __GNUC_MINOR__ version macros are also defined by clang, but clang doesn't support the same attributes as GCC. clang 3.5.0 does not support the __alloc_size__ attribute: https://github.com/llvm-mirror/clang/commit/c047507a9a79e89fc8339e074fa72822a7e7ea73 The following warning is produced: gstrfuncs.h:257:44: warning: unknown attribute '__alloc_size__' ignored [-Wunknown-attributes] G_GNUC_MALLOC G_GNUC_ALLOC_SIZE(2); gmacros.h:67:45: note: expanded from macro 'G_GNUC_ALLOC_SIZE' #define G_GNUC_ALLOC_SIZE(x) __attribute__((__alloc_size__(x))) This patch checks whether glib headers cause warnings and disables -Wunknown-attributes if it is able to. Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com> Signed-off-by: NJohn Snow <jsnow@redhat.com> Reviewed-by: NStefan Hajnoczi <stefanha@redhat.com> Message-id: 1427324259-1481-4-git-send-email-jsnow@redhat.com Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-
由 John Snow 提交于
Factor out the function that checks if a compiler flag is supported or not. Signed-off-by: NJohn Snow <jsnow@redhat.com> Reviewed-by: NStefan Hajnoczi <stefanha@redhat.com> Message-id: 1427324259-1481-3-git-send-email-jsnow@redhat.com Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-
由 Stefan Hajnoczi 提交于
gcc 4.9.2 treats -nopie as an error: cc: error: unrecognized command line option ‘-nopie’ clang 3.5.0 treats -nopie as a warning: clang: warning: argument unused during compilation: '-nopie' The causes ./configure to fail with clang: ERROR: configure test passed without -Werror but failed with -Werror. Make the -nopie test use -Werror so that compile_prog works for both gcc and clang. Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com> Signed-off-by: NJohn Snow <jsnow@redhat.com> Reviewed-by: NStefan Hajnoczi <stefanha@redhat.com> Message-id: 1427324259-1481-2-git-send-email-jsnow@redhat.com Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
-