- 31 10月, 2018 8 次提交
-
-
由 Max Reitz 提交于
There are two imports that need to be modified when running the iotests under Python 3: One is StringIO, which no longer exists; instead, the StringIO class comes from the io module, so import it from there (and use the BytesIO class for Python 2). The other is the ConfigParser, which has just been renamed to configparser. Signed-off-by: NMax Reitz <mreitz@redhat.com> Reviewed-by: NEduardo Habkost <ehabkost@redhat.com> Reviewed-by: NCleber Rosa <crosa@redhat.com> Message-Id: <20181022135307.14398-9-mreitz@redhat.com> Signed-off-by: NEduardo Habkost <ehabkost@redhat.com>
-
由 Max Reitz 提交于
iotest 169 uses the 'new' module to add methods to a class. This module no longer exists in Python 3. Instead, we can use a lambda. Best of all, this works in 2.7 just as well. Signed-off-by: NMax Reitz <mreitz@redhat.com> Reviewed-by: NEduardo Habkost <ehabkost@redhat.com> Reviewed-by: NCleber Rosa <crosa@redhat.com> Message-Id: <20181022135307.14398-8-mreitz@redhat.com> Signed-off-by: NEduardo Habkost <ehabkost@redhat.com>
-
由 Max Reitz 提交于
Python 3.4 introduced the inheritable attribute for FDs. At the same time, it changed the default so that all FDs are not inheritable by default, that only inheritable FDs are inherited to subprocesses, and only if close_fds is explicitly set to False. Adhere to this by setting close_fds to False when working with subprocesses that may want to inherit FDs, and by trying to set_inheritable() on FDs that we do want to bequeath to them. Signed-off-by: NMax Reitz <mreitz@redhat.com> Reviewed-by: NEduardo Habkost <ehabkost@redhat.com> Reviewed-by: NCleber Rosa <crosa@redhat.com> Message-Id: <20181022135307.14398-7-mreitz@redhat.com> Signed-off-by: NEduardo Habkost <ehabkost@redhat.com>
-
由 Max Reitz 提交于
In Python 3, several functions now return iterators instead of lists. This includes range(), items(), map(), and filter(). This means that if we really want a list, we have to wrap those instances with list(). But then again, the two instances where this is the case for map() and filter(), there are shorter expressions which work without either function. On the other hand, sometimes we do just want an iterator, in which case we have sometimes used xrange() and iteritems() which no longer exist in Python 3. Just change these calls to be range() and items(), works in both Python 2 and 3, and is really what we want in 3 (which is what matters). But because it is so simple to do (and to find and remove once we completely switch to Python 3), make range() be an alias for xrange() in the two affected tests (044 and 163). In one instance, we only wanted the first instance of the result of a filter() call. Instead of using next(filter()) which would work only in Python 3, or list(filter())[0] which would work everywhere but is a bit weird, this instance is changed to use a generator expression with a next() wrapped around, which works both in 2.7 and 3. Signed-off-by: NMax Reitz <mreitz@redhat.com> Reviewed-by: NEduardo Habkost <ehabkost@redhat.com> Reviewed-by: NCleber Rosa <crosa@redhat.com> Message-Id: <20181022135307.14398-6-mreitz@redhat.com> Signed-off-by: NEduardo Habkost <ehabkost@redhat.com>
-
由 Max Reitz 提交于
In Python 3, / is always a floating-point division. We usually do not want this, and as Python 2.7 understands // as well, change all integer divisions to use that. Signed-off-by: NMax Reitz <mreitz@redhat.com> Reviewed-by: NEduardo Habkost <ehabkost@redhat.com> Reviewed-by: NCleber Rosa <crosa@redhat.com> Message-Id: <20181022135307.14398-5-mreitz@redhat.com> Signed-off-by: NEduardo Habkost <ehabkost@redhat.com>
-
由 Max Reitz 提交于
Since byte strings are no longer the default in Python 3, we have to explicitly use them where we need to, which is mostly when working with structures. It also means that we need to open a file in binary mode when we want to use structures. On the other hand, we have to accomodate for the fact that some functions (still) work with byte strings but we want to use unicode strings (in Python 3 at least, and it does not matter in Python 2). This includes base64 encoding, but it is most notable when working with the subprocess module: Either we set universal_newlines to True so that the default streams are opened in text mode (hence this parameter is aliased as "text" as of 3.7), or, if that is not possible, we have to decode the output to a normal string. Signed-off-by: NMax Reitz <mreitz@redhat.com> Reviewed-by: NEduardo Habkost <ehabkost@redhat.com> Message-Id: <20181022135307.14398-4-mreitz@redhat.com> Signed-off-by: NEduardo Habkost <ehabkost@redhat.com>
-
由 Max Reitz 提交于
After issuing a command, flush the pipe. This does not change anything in Python 2, but it makes a difference in Python 3. Signed-off-by: NMax Reitz <mreitz@redhat.com> Reviewed-by: NEduardo Habkost <ehabkost@redhat.com> Reviewed-by: NCleber Rosa <crosa@redhat.com> Message-Id: <20181022135307.14398-3-mreitz@redhat.com> Signed-off-by: NEduardo Habkost <ehabkost@redhat.com>
-
由 Max Reitz 提交于
When closing a connection, make the nbd-fault-injector flush the socket. Without this, the output is a bit unreliable with Python 3. Signed-off-by: NMax Reitz <mreitz@redhat.com> Reviewed-by: NEduardo Habkost <ehabkost@redhat.com> Reviewed-by: NCleber Rosa <crosa@redhat.com> Reviewed-by: NEric Blake <eblake@redhat.com> Message-Id: <20181022135307.14398-2-mreitz@redhat.com> Signed-off-by: NEduardo Habkost <ehabkost@redhat.com>
-
- 30 10月, 2018 3 次提交
-
-
Test that we can resume source vm after [failed] migration, and bitmaps are ok. Signed-off-by: NVladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Signed-off-by: NJohn Snow <jsnow@redhat.com>
-
Before previous patch, iotest 169 was actually broken for the case test_persistent__not_migbitmap__offline_shared, while formally passing. After migration log of vm_b had message: qemu-system-x86_64: Could not reopen qcow2 layer: Bitmap already exists: bitmap0 which means that invalidation failed and bs->drv = NULL. It was because we've loaded bitmap twice: on open and on invalidation. Add code to 169, to catch such fails. Signed-off-by: NVladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Signed-off-by: NJohn Snow <jsnow@redhat.com>
-
Signed-off-by: NVladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Reviewed-by: NJohn Snow <jsnow@redhat.com> Signed-off-by: NJohn Snow <jsnow@redhat.com>
-
- 26 10月, 2018 13 次提交
-
-
由 Philippe Mathieu-Daudé 提交于
Patch created mechanically by rerunning: $ spatch --sp-file scripts/coccinelle/typecast.cocci \ --macro-file scripts/cocci-macro-file.h \ --dir . --in-place Signed-off-by: NPhilippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by: NMarkus Armbruster <armbru@redhat.com> Acked-by: NMichael S. Tsirkin <mst@redhat.com> Message-Id: <20180705155811.20366-5-f4bug@amsat.org> Signed-off-by: NLaurent Vivier <laurent@vivier.eu>
-
由 Stefan Weil 提交于
Fix also a grammar issue. Signed-off-by: NStefan Weil <sw@weilnetz.de> Reviewed-by: NAlex Bennée <alex.bennee@linaro.org> Message-Id: <20180713054755.23323-1-sw@weilnetz.de> Signed-off-by: NLaurent Vivier <laurent@vivier.eu>
-
由 Cleber Rosa 提交于
Commit 990dc39c made all tests executable at the time, but 218 came in later, and missing those permissions. Signed-off-by: NCleber Rosa <crosa@redhat.com> Message-Id: <20181004161852.11673-4-crosa@redhat.com> Signed-off-by: NLaurent Vivier <laurent@vivier.eu>
-
由 Cleber Rosa 提交于
Commit cce293a2 moved some functions from common.config to common.rc, but the error messages still reference the old file location. Signed-off-by: NCleber Rosa <crosa@redhat.com> Reviewed-by: NMax Reitz <mreitz@redhat.com> Reviewed-by: NPhilippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20181004161852.11673-5-crosa@redhat.com> Signed-off-by: NLaurent Vivier <laurent@vivier.eu>
-
由 Cleber Rosa 提交于
Point to the right and obvious location for lm32 tests. Signed-off-by: NCleber Rosa <crosa@redhat.com> Reviewed-by: NThomas Huth <thuth@redhat.com> Acked-by: NAlex Bennée <alex.bennee@linaro.org> Message-Id: <20181004161852.11673-3-crosa@redhat.com> Signed-off-by: NLaurent Vivier <laurent@vivier.eu>
-
由 Philippe Mathieu-Daudé 提交于
Signed-off-by: NPhilippe Mathieu-Daudé <f4bug@amsat.org> Message-Id: <20181013004034.6968-9-f4bug@amsat.org> Reviewed-by: NRichard Henderson <richard.henderson@linaro.org> Signed-off-by: NFam Zheng <famz@redhat.com>
-
由 Philippe Mathieu-Daudé 提交于
Signed-off-by: NPhilippe Mathieu-Daudé <f4bug@amsat.org> Message-Id: <20181013004034.6968-8-f4bug@amsat.org> Reviewed-by: NRichard Henderson <richard.henderson@linaro.org> Signed-off-by: NFam Zheng <famz@redhat.com>
-
由 Philippe Mathieu-Daudé 提交于
The 'arch' property gives a hint on which architecture the guest image runs. This can be use to select the correct QEMU binary path. Signed-off-by: NPhilippe Mathieu-Daudé <f4bug@amsat.org> Message-Id: <20181013004034.6968-6-f4bug@amsat.org> Reviewed-by: NRichard Henderson <richard.henderson@linaro.org> Signed-off-by: NFam Zheng <famz@redhat.com>
-
由 Philippe Mathieu-Daudé 提交于
Signed-off-by: NPhilippe Mathieu-Daudé <f4bug@amsat.org> Message-Id: <20181013004034.6968-5-f4bug@amsat.org> Reviewed-by: NRichard Henderson <richard.henderson@linaro.org> Signed-off-by: NFam Zheng <famz@redhat.com>
-
由 Philippe Mathieu-Daudé 提交于
Signed-off-by: NPhilippe Mathieu-Daudé <f4bug@amsat.org> Message-Id: <20181013004034.6968-4-f4bug@amsat.org> Reviewed-by: NRichard Henderson <richard.henderson@linaro.org> Signed-off-by: NFam Zheng <famz@redhat.com>
-
由 Philippe Mathieu-Daudé 提交于
Signed-off-by: NPhilippe Mathieu-Daudé <f4bug@amsat.org> Message-Id: <20181013004034.6968-3-f4bug@amsat.org> Reviewed-by: NRichard Henderson <richard.henderson@linaro.org> Signed-off-by: NFam Zheng <famz@redhat.com>
-
由 Philippe Mathieu-Daudé 提交于
Signed-off-by: NPhilippe Mathieu-Daudé <f4bug@amsat.org> Message-Id: <20181013004034.6968-2-f4bug@amsat.org> Reviewed-by: NRichard Henderson <richard.henderson@linaro.org> Signed-off-by: NFam Zheng <famz@redhat.com>
-
由 Paolo Bonzini 提交于
--with-gtkabi does not exist anymore; remove it from the configure invocation. Fixes: 89d85cdeSigned-off-by: NPaolo Bonzini <pbonzini@redhat.com> Message-Id: <1539886203-33670-1-git-send-email-pbonzini@redhat.com> Tested-by: NPhilippe Mathieu-Daudé <philmd@redhat.com> Reviewed-by: NThomas Huth <thuth@redhat.com> Reviewed-by: NPhilippe Mathieu-Daudé <philmd@redhat.com> Signed-off-by: NFam Zheng <famz@redhat.com>
-
- 25 10月, 2018 3 次提交
-
-
由 Daniel P. Berrangé 提交于
Validate that the XTS cipher mode will correctly operate with plain text, cipher text and IV buffers that are not 64-bit aligned. Reviewed-by: NAlberto Garcia <berto@igalia.com> Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
-
由 Daniel P. Berrangé 提交于
The current XTS test overloads two different tests in a single function making the code a little hard to follow. Split it into distinct test cases. Reviewed-by: NAlberto Garcia <berto@igalia.com> Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
-
由 Daniel P. Berrangé 提交于
Add testing coverage for AES with XTS, ECB and CTR modes Reviewed-by: NMarc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: NAlberto Garcia <berto@igalia.com> Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
-
- 24 10月, 2018 11 次提交
-
-
由 Fredrik Noring 提交于
Add a test for DIVU1. Reviewed-by: NAleksandar Markovic <amarkovic@wavecomp.com> Signed-off-by: NFredrik Noring <noring@nocrew.org> Signed-off-by: NAleksandar Markovic <amarkovic@wavecomp.com>
-
由 Fredrik Noring 提交于
Add a test for DIV1. Reviewed-by: NAleksandar Markovic <amarkovic@wavecomp.com> Signed-off-by: NFredrik Noring <noring@nocrew.org> Signed-off-by: NAleksandar Markovic <amarkovic@wavecomp.com>
-
由 Fredrik Noring 提交于
Add a test for MTLO1 and MTHI1. Reviewed-by: NAleksandar Markovic <amarkovic@wavecomp.com> Signed-off-by: NFredrik Noring <noring@nocrew.org> Signed-off-by: NAleksandar Markovic <amarkovic@wavecomp.com>
-
由 Fredrik Noring 提交于
Add a test for MFLO1 and MFHI1. Reviewed-by: NAleksandar Markovic <amarkovic@wavecomp.com> Signed-off-by: NFredrik Noring <noring@nocrew.org> Signed-off-by: NAleksandar Markovic <amarkovic@wavecomp.com>
-
由 Fredrik Noring 提交于
Add a test for MULTU1. Reviewed-by: NAleksandar Markovic <amarkovic@wavecomp.com> Signed-off-by: NFredrik Noring <noring@nocrew.org> Signed-off-by: NAleksandar Markovic <amarkovic@wavecomp.com>
-
由 Fredrik Noring 提交于
Add a test for MULT1. Reviewed-by: NAleksandar Markovic <amarkovic@wavecomp.com> Signed-off-by: NFredrik Noring <noring@nocrew.org> Signed-off-by: NAleksandar Markovic <amarkovic@wavecomp.com>
-
由 Fredrik Noring 提交于
Add a test for MULTU. Reviewed-by: NAleksandar Markovic <amarkovic@wavecomp.com> Signed-off-by: NFredrik Noring <noring@nocrew.org> Signed-off-by: NAleksandar Markovic <amarkovic@wavecomp.com>
-
由 Fredrik Noring 提交于
Add a test for MULT. Reviewed-by: NAleksandar Markovic <amarkovic@wavecomp.com> Signed-off-by: NFredrik Noring <noring@nocrew.org> Signed-off-by: NAleksandar Markovic <amarkovic@wavecomp.com>
-
由 Igor Mammedov 提交于
-smp [cpus],sockets/cores/threads[,maxcpus] should describe topology so that total number of logical CPUs [sockets * cores * threads] would be equal to [maxcpus], however historically we didn't have such check in QEMU and it is possible to start VM with an invalid topology. Deprecate invalid options combination so we can make sure that the topology VM started with is always correct in the future. Users with an invalid sockets/cores/threads/maxcpus values should fix their CLI to make sure that [sockets * cores * threads] == [maxcpus] Signed-off-by: NIgor Mammedov <imammedo@redhat.com> Reviewed-by: NAndrew Jones <drjones@redhat.com> Reviewed-by: NEduardo Habkost <ehabkost@redhat.com> Message-Id: <1536836762-273036-2-git-send-email-imammedo@redhat.com> Reviewed-by: NEric Blake <eblake@redhat.com> [ehabkost: squashed unit test fix] Message-Id: <20181019215345.521d58d7@igors-macbook-pro.local> Signed-off-by: NEduardo Habkost <ehabkost@redhat.com>
-
由 Mao Zhongyi 提交于
Various shell files contain a mix between obsolete `` and modern $(); It would be nice to convert to using $() everywhere. Signed-off-by: NMao Zhongyi <maozhongyi@cmss.chinamobile.com> Reviewed-by: NAlex Bennée <alex.bennee@linaro.org> Tested-by: NAlex Bennée <alex.bennee@linaro.org> Signed-off-by: NThomas Huth <thuth@redhat.com>
-
由 Thomas Huth 提交于
The migration test for s390x sometimes hangs when running with TCG, similar to the problems that we have already observed with TCG for the ppc64 guests. Thus disable the s390x test when we are not running with KVM for now until the problem with TCG has been resolved. Reviewed-by: NLaurent Vivier <lvivier@redhat.com> Reviewed-by: NEmilio G. Cota <cota@braap.org> Signed-off-by: NThomas Huth <thuth@redhat.com>
-
- 19 10月, 2018 2 次提交
-
-
由 Daniel P. Berrangé 提交于
nettle 2.7.1 was released in 2013 and all the distros that are build target platforms for QEMU [1] include it: RHEL-7: 2.7.1 Debian (Stretch): 3.3 Debian (Jessie): 2.7.1 OpenBSD (ports): 3.4 FreeBSD (ports): 3.4 OpenSUSE Leap 15: 3.4 Ubuntu (Xenial): 3.2 macOS (Homebrew): 3.4 Based on this, it is reasonable to require nettle >= 2.7.1 in QEMU which allows for some conditional version checks in the code to be removed. [1] https://qemu.weilnetz.de/doc/qemu-doc.html#Supported-build-platformsReviewed-by: NEric Blake <eblake@redhat.com> Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
-
由 Markus Armbruster 提交于
bdrv_img_create() takes an Error ** argument and uses it in the conventional way, except for one place: when qemu_opts_do_parse() fails, it first reports its error to stderr or the HMP monitor with error_report_err(), then error_setg()'s a generic error. When the caller reports that second error similarly, this produces two consecutive error messages on stderr or the HMP monitor. When the caller does something else with it, such as send it via QMP, the first error still goes to stderr or the HMP monitor. Fortunately, no such caller exists. Simply use the first error as is. Update expected output of qemu-iotest 049 accordingly. Cc: Kevin Wolf <kwolf@redhat.com> Cc: Max Reitz <mreitz@redhat.com> Signed-off-by: NMarkus Armbruster <armbru@redhat.com> Reviewed-by: NEric Blake <eblake@redhat.com> Message-Id: <20181017082702.5581-37-armbru@redhat.com> Reviewed-by: NKevin Wolf <kwolf@redhat.com>
-