Jason Lowe-Power has submitted this change. ( https://gem5-review.googlesource.com/c/public/gem5/+/36175 )

Change subject: sim,python: Flip logic on loopback listeners
......................................................................

sim,python: Flip logic on loopback listeners

People are bitten by allowing external connections to gem5 runs too often
(it happend to me again today). This change flips the logic so the
default is to only allow localhost connections.

Change-Id: If9233f5ca383721017b30b5837a26c5042d925fd
Signed-off-by: Jason Lowe-Power <[email protected]>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/36175
Reviewed-by: Hoa Nguyen <[email protected]>
Reviewed-by: Ayaz Akram <[email protected]>
Reviewed-by: Andreas Sandberg <[email protected]>
Maintainer: Gabe Black <[email protected]>
Tested-by: kokoro <[email protected]>
---
M src/python/m5/main.py
1 file changed, 4 insertions(+), 4 deletions(-)

Approvals:
  Andreas Sandberg: Looks good to me, approved
  Ayaz Akram: Looks good to me, but someone else must approve
  Hoa Nguyen: Looks good to me, approved
  Gabe Black: Looks good to me, approved
  kokoro: Regressions pass



diff --git a/src/python/m5/main.py b/src/python/m5/main.py
index 6fe9218..3408889 100644
--- a/src/python/m5/main.py
+++ b/src/python/m5/main.py
@@ -97,9 +97,9 @@
         choices=listener_modes, default="auto",
         help="Port (e.g., gdb) listener mode (auto: Enable if running " \
         "interactively) [Default: %default]")
-    option("--listener-loopback-only", action="store_true", default=False,
-        help="Port listeners will only accept connections over the " \
-        "loopback device")
+ option("--allow-remote-connections", action="store_true", default=False, + help="Port listeners will accept connections from anywhere (0.0.0.0). "
+        "Default is only localhost.")
     option('-i', "--interactive", action="store_true", default=False,
         help="Invoke the interactive interpreter after running the script")
     option("--pdb", action="store_true", default=False,
@@ -379,7 +379,7 @@
     else:
         panic("Unhandled listener mode: %s" % options.listener_mode)

-    if options.listener_loopback_only:
+    if not options.allow_remote_connections:
         m5.listenersLoopbackOnly()

     # set debugging options

--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/36175
To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings

Gerrit-Project: public/gem5
Gerrit-Branch: develop
Gerrit-Change-Id: If9233f5ca383721017b30b5837a26c5042d925fd
Gerrit-Change-Number: 36175
Gerrit-PatchSet: 2
Gerrit-Owner: Jason Lowe-Power <[email protected]>
Gerrit-Reviewer: Andreas Sandberg <[email protected]>
Gerrit-Reviewer: Ayaz Akram <[email protected]>
Gerrit-Reviewer: Gabe Black <[email protected]>
Gerrit-Reviewer: Hoa Nguyen <[email protected]>
Gerrit-Reviewer: Jason Lowe-Power <[email protected]>
Gerrit-Reviewer: Maryam Babaie <[email protected]>
Gerrit-Reviewer: kokoro <[email protected]>
Gerrit-CC: Earl Ou <[email protected]>
Gerrit-CC: Weiping Liao <[email protected]>
Gerrit-MessageType: merged
_______________________________________________
gem5-dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s

Reply via email to