summaryrefslogtreecommitdiffstats
path: root/scripts/runqemu
diff options
context:
space:
mode:
authorAlexander Kanavin <alex.kanavin@gmail.com>2022-11-28 11:46:32 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2022-11-29 10:29:58 +0000
commit18fc5fb41aa673be646e7863be577f60b069e8af (patch)
tree1ca75d3bfd18922d5072cc6e099407b6b345c7c9 /scripts/runqemu
parentdea0b2d2a9345e6df771aaaf2f9f2796343d6e30 (diff)
downloadpoky-18fc5fb41aa673be646e7863be577f60b069e8af.tar.gz
runqemu: do not hardcode the ip address of the nfs server when using tap
Rather, set it similarly to the overall network config. (From OE-Core rev: d5e2ef31b151825613b62e58034e81f72526a944) Signed-off-by: Alexander Kanavin <alex@linutronix.de> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/runqemu')
-rwxr-xr-xscripts/runqemu3
1 files changed, 2 insertions, 1 deletions
diff --git a/scripts/runqemu b/scripts/runqemu
index 7bd9465593..04728673de 100755
--- a/scripts/runqemu
+++ b/scripts/runqemu
@@ -999,7 +999,7 @@ class BaseConfig(object):
999 if self.slirp_enabled: 999 if self.slirp_enabled:
1000 self.nfs_server = '10.0.2.2' 1000 self.nfs_server = '10.0.2.2'
1001 else: 1001 else:
1002 self.nfs_server = '192.168.7.1' 1002 self.nfs_server = '192.168.7.@GATEWAY@'
1003 1003
1004 # Figure out a new nfs_instance to allow multiple qemus running. 1004 # Figure out a new nfs_instance to allow multiple qemus running.
1005 ps = subprocess.check_output(("ps", "auxww")).decode('utf-8') 1005 ps = subprocess.check_output(("ps", "auxww")).decode('utf-8')
@@ -1187,6 +1187,7 @@ class BaseConfig(object):
1187 netconf = " " + self.cmdline_ip_tap 1187 netconf = " " + self.cmdline_ip_tap
1188 netconf = netconf.replace('@CLIENT@', str(client)) 1188 netconf = netconf.replace('@CLIENT@', str(client))
1189 netconf = netconf.replace('@GATEWAY@', str(gateway)) 1189 netconf = netconf.replace('@GATEWAY@', str(gateway))
1190 self.nfs_server = self.nfs_server.replace('@GATEWAY@', str(gateway))
1190 logger.info("Network configuration:%s", netconf) 1191 logger.info("Network configuration:%s", netconf)
1191 self.kernel_cmdline_script += netconf 1192 self.kernel_cmdline_script += netconf
1192 mac = "%s%02x" % (self.mac_tap, client) 1193 mac = "%s%02x" % (self.mac_tap, client)