Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(509)

Unified Diff: client/tests/kvm/tests/iofuzz.py

Issue 6124004: Revert "Merge remote branch 'cros/upstream' into autotest-rebase" (Closed) Base URL: ssh://git@gitrw.chromium.org:9222/autotest.git@master
Patch Set: Created 9 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « client/tests/kvm/tests/image_copy.py ('k') | client/tests/kvm/tests/ioquit.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: client/tests/kvm/tests/iofuzz.py
diff --git a/client/tests/kvm/tests/iofuzz.py b/client/tests/kvm/tests/iofuzz.py
index e77540eb2ffcc2eb82df5ea01635e5e8b0e5a501..45a0eb99ae5659534367092a18e5ce4625b6b2c9 100644
--- a/client/tests/kvm/tests/iofuzz.py
+++ b/client/tests/kvm/tests/iofuzz.py
@@ -33,10 +33,11 @@ def run_iofuzz(test, params, env):
logging.debug("outb(0x%x, 0x%x)", port, data)
outb_cmd = ("echo -e '\\%s' | dd of=/dev/port seek=%d bs=1 count=1" %
(oct(data), port))
- try:
- session.cmd(outb_cmd)
- except kvm_subprocess.ShellError, e:
- logging.debug(e)
+ s, o = session.get_command_status_output(outb_cmd)
+ if s is None:
+ logging.debug("Command did not return")
+ if s != 0:
+ logging.debug("Command returned status %s", s)
def inb(session, port):
@@ -48,10 +49,11 @@ def run_iofuzz(test, params, env):
"""
logging.debug("inb(0x%x)", port)
inb_cmd = "dd if=/dev/port seek=%d of=/dev/null bs=1 count=1" % port
- try:
- session.cmd(inb_cmd)
- except kvm_subprocess.ShellError, e:
- logging.debug(e)
+ s, o = session.get_command_status_output(inb_cmd)
+ if s is None:
+ logging.debug("Command did not return")
+ if s != 0:
+ logging.debug("Command returned status %s", s)
def fuzz(session, inst_list):
@@ -98,7 +100,7 @@ def run_iofuzz(test, params, env):
r = random.SystemRandom()
logging.info("Enumerate guest devices through /proc/ioports")
- ioports = session.cmd_output("cat /proc/ioports")
+ ioports = session.get_command_output("cat /proc/ioports")
logging.debug(ioports)
devices = re.findall("(\w+)-(\w+)\ : (.*)", ioports)
« no previous file with comments | « client/tests/kvm/tests/image_copy.py ('k') | client/tests/kvm/tests/ioquit.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698