summaryrefslogtreecommitdiff
path: root/tests/ide-test.c
AgeCommit message (Collapse)AuthorFilesLines
2014-01-22qtest: Fix the bug about disable vnc causes "make check" failKewei Yu1-3/+0
When we disable vnc from "./configure", QEMU can't use the vnc option. So qtest can't use the "vnc -none ", otherwise "make check" fails. If QEMU uses "-display none", "-vnc none" is excrescent, So we just need to drop it. Signed-off-by: Kewei Yu <keweihk@gmail.com> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
2013-11-07libqtest: rename qmp() to qmp_discard_response()Stefan Hajnoczi1-4/+6
Existing qmp() callers do not expect a response object. In order to implement real QMP test cases it will be necessary to inspect the response object. Rename qmp() to qmp_discard_response(). Later patches will introduce a qmp() function that returns the response object and tests that use it. Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Andreas Färber <afaerber@suse.de>
2013-10-28ide-test: Check what happens with bus mastering disabledKevin Wolf1-0/+26
The main goal is that qemu doesn't crash. Signed-off-by: Kevin Wolf <kwolf@redhat.com>
2013-07-18libqtest: New qtest_end() to go with qtest_start()Markus Armbruster1-1/+1
Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Andreas Färber <afaerber@suse.de> Reviewed-by: Anthony Liguori <aliguori@us.ibm.com> Message-id: 1371711329-9144-3-git-send-email-armbru@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-06-14ide-test: fix failure for test_flushMichael Roth1-1/+4
bd07684aacfb61668ae2c25b7dd00b64f3d7c7f3 added a test to ensure BSY flag is set when a flush request is in flight. It does this by setting a blkdebug breakpoint on flush_to_os before issuing a CMD_FLUSH_CACHE. It then resumes CMD_FLUSH_CACHE operation and checks that BSY is unset. The actual unsetting of BSY does not occur until ide_flush_cb gets called in a bh, however, so in some cases this check will race with the actual completion. Fix this by polling the ide status register until BSY flag gets unset before we do our final sanity checks. According to f68ec8379e88502b4841a110c070e9b118d3151c this is in line with how a guest would determine whether or not the device is still busy. Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-06-06ide-test: Add FLUSH CACHE test caseKevin Wolf1-0/+40
This checks in particular that BSY is set while the flush request is in flight. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
2013-06-06ide-test: Add enum value for DEVKevin Wolf1-1/+2
Get rid of the magic number. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
2013-05-15ide-test: Fix endianness problemsKevin Wolf1-5/+27
The test case passes on big endian hosts now (tested on ppc64) Signed-off-by: Kevin Wolf <kwolf@redhat.com> Message-id: 1368622839-7084-1-git-send-email-kwolf@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-05-08qtest/ide-test: Test short and long PRDTsKevin Wolf1-0/+54
This tests the behaviour of the DMA engine when the given PRDT contains physical region descriptors for either more or less bytes than the IDE request is for. Signed-off-by: Kevin Wolf <kwolf@redhat.com>
2013-05-08qtest/ide-test: Add simple DMA read/write test caseKevin Wolf1-0/+221
This tests that single sectors can be successfully written and correctly read back. Signed-off-by: Kevin Wolf <kwolf@redhat.com>
2013-05-08qtest: Add IDE test caseKevin Wolf1-0/+165
This adds a simple IDE test case and starts by verifying that IDENTIFY can be successfully used and return the correct serial number, version and the WCE flag is set for cache=writeback. Signed-off-by: Kevin Wolf <kwolf@redhat.com>