From 2a8f2c51d78daf5384c2a2e786ee9497bfbc6d3c Mon Sep 17 00:00:00 2001 From: Marc Bonnici Date: Wed, 22 Nov 2017 11:32:46 +0000 Subject: [PATCH] SSH/Gem5Connection: Adds `shell_echo` parameter This flag is used to indicate whether gem5 echos the exectued command which requires removal for correct parsing. --- devlib/utils/ssh.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/devlib/utils/ssh.py b/devlib/utils/ssh.py index 5f9ed0b..8aad005 100644 --- a/devlib/utils/ssh.py +++ b/devlib/utils/ssh.py @@ -333,6 +333,7 @@ class Gem5Connection(TelnetConnection): timeout=None, password_prompt=None, original_prompt=None, + strip_echoed_commands=False, ): if host is not None: host_system = socket.gethostname() @@ -349,6 +350,8 @@ class Gem5Connection(TelnetConnection): self.is_rooted = True self.password = None self.port = None + # Flag to indicate whether commands are echoed by the simulated system + self.strip_echoed_commands = strip_echoed_commands # Long timeouts to account for gem5 being slow # Can be overriden if the given timeout is longer self.default_timeout = 3600