Commit Graph

20 Commits

Author SHA1 Message Date
Hauke Mehrtens
497012ab4e scripts: qemustart: Fix x86/legacy bootup
The ide-drive option was renamed to ide-hd in qemu 6.0.
With this change qemu is starting again on Debian 12.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
2023-08-14 23:37:04 +02:00
Mathew McBride
36bf9d8610
scripts: qemustart: change armvirt references to armsr
The armvirt target has been renamed to 'armsr' (Arm SystemReady)
after inclusion of EFI support.
Change references (including subtargets) accordingly.

Signed-off-by: Mathew McBride <matt@traverse.com.au>
2023-06-10 21:30:24 +02:00
Andre Heider
f56d5932d2 scripts: qemustart: support CONFIG_BINARY_FOLDER
If CONFIG_BINARY_FOLDER is set in .config, use that instead of "bin" as
the bindir.

That allows to set that config and easily run e.g.
`./scripts/qemustart armvirt 32`.

Signed-off-by: Andre Heider <a.heider@gmail.com>
2023-02-03 21:22:49 +01:00
Hans Dedecker
abc7a97e9c Revert "ethtool: update to v5.14"
This reverts commit 7630001427

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2021-10-23 21:39:00 +02:00
Hans Dedecker
7630001427 ethtool: update to v5.14
Update to newly released version 5.14

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2021-10-23 21:35:38 +02:00
Paul Spooren
1b002434f0 scripts/qemustart: use squashfs instead of ext4
The qemustart script currently picks the ext4 filesystem rather than
squashfs, while the latter is default for nearly all OpenWrt targets.

Change the default behaviour of qemustart to be in line with the rest.

Signed-off-by: Paul Spooren <mail@aparcar.org>
2021-01-01 17:49:05 -10:00
Tony Ambardar
5b3ff53ebd scripts/qemustart: update malta to use MIPS64 R2 cpu
Explicitly set the QEMU cpu type and support the MIPS R2 ISA, for both
64-bit and 32-bit targets. The later previously supported MIPS R2 by
implicit default.

This is needed after commit 93608697f3 ("malta: update MIPS64 ISA to R2"),
otherwise booting malta images with scripts/qemustart will hang.

Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
2020-10-11 16:16:24 +02:00
Paul Spooren
2cb6d471b7 scripts: fixup qemustart for new x86 image names
qemustart allows easy testing of created images via `qemu`. The script
automatically selects created images and can setup e.g. networks.

As the x86 target now uses the generic image.mk the profile appears also
in the image name, this is *generic*.

Add the profile name to the qemustart script so it still finds the file.

Signed-off-by: Paul Spooren <mail@aparcar.org>
2020-03-21 10:36:00 +00:00
Yousong Zhou
c2fee615ce scripts/qemustart: add notes on adding new options
Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
2019-04-26 13:09:33 +00:00
Yousong Zhou
d726878546 scripts/qemustart: fix network device emulation
We only enabled pcnet driver for malta machine, and x86/legacy target
was supposed to only support e1000 model

Cc: Petr Štetiar <ynezz@true.cz>
Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
2019-04-26 13:09:33 +00:00
Yousong Zhou
647356a3d2 scripts/qemustart: no network by default and enable with -n
This should make it easier to set up and possibly provide a "work out of
the box" experience for most test usage.  Typical wan&lan networking
setup is only two characters argument away.

Cc: Petr Štetiar <ynezz@true.cz>
Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
Acked-by: Hans Dedecker <dedeckeh@gmail.com>
2019-04-26 13:08:38 +00:00
Hans Dedecker
9424b6f998 scripts/qemustart: fix usage with networking support
Commit 8bf500eb79 added support for qemu usage without networking
support but broke networking support as -n and -z do not work with
unquoted argument; fix this by quoting the arguments.

Fixes 8bf500eb79

Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
2019-04-24 20:02:54 +02:00
Petr Štetiar
4953b3891a scripts/qemustart: Allow specifying custom rootfs for malta
Currently it's not possible to test boot squashfs root images, so this
patch now allows this use case as well.

Cc: Yousong Zhou <yszhou4tech@gmail.com>
Signed-off-by: Petr Štetiar <ynezz@true.cz>
2019-04-08 18:37:05 +02:00
Petr Štetiar
b0e5e32daa scripts/qemustart: Allow specifying custom kernel for x86
Currently it's not possible to test boot squashfs root images, so this
patch now allows this use case as well.

Cc: Yousong Zhou <yszhou4tech@gmail.com>
Signed-off-by: Petr Štetiar <ynezz@true.cz>
2019-04-08 18:37:05 +02:00
Petr Štetiar
8bf500eb79 scripts/qemustart: Allow usage without networking
For basic tests it's not necessary to have the networking setup and this
allows testing as a normal user as well, without root privileges.

So this patch adds `--no-network` long option or `-n` short option,
which allows starting QEMU without network.

Cc: Yousong Zhou <yszhou4tech@gmail.com>
Signed-off-by: Petr Štetiar <ynezz@true.cz>
2019-04-08 18:37:05 +02:00
Yousong Zhou
73c60ef239 scripts/qemustart: allow machine selection with new option --machine
This can be used to set machine options like highmem=off for running old
armvirt/32 kernel lacking LPAE support with QEMU version 3.0 or later

 [1] Armv7 guest fails to boot with qemu-3.0.0-1,
     https://bugzilla.redhat.com/show_bug.cgi?id=1633328#c5

Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
2019-02-22 01:35:05 +00:00
Yousong Zhou
3cc31ea8d3 scripts/qemustart: more compact rand_mac()
Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
2018-12-17 04:16:34 +00:00
Yousong Zhou
aa66aa0c9a scripts/qemustart: more portable array operation
The following commands output 1,2,1,1

    cmd0='a=("${a[@]}" 'a'); echo "${#a}"'
    cmd1='a+=('a'); echo "${#a}"'
    bash -c "$cmd0"; zsh -c "$cmd0"
    bash -c "$cmd1"; zsh -c "$cmd1"

The following outputs 0,1,0,0

    cmd2='f() { echo "$#"; }; f "${a[@]}"'
    cmd3="a=(); $cmd2"
    bash -c "$cmd2"; zsh -c "$cmd2"
    bash -c "$cmd3"; zsh -c "$cmd3"

Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
2018-01-31 16:54:57 +08:00
Zoltan HERPAI
7b5c989ab9 merge: targets: update image generation and targets
Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
2017-12-08 19:41:18 +01:00
Yousong Zhou
50fcfd4b65 scripts/qemustart: initial version
The script can be used to quickly spin up QEMU virtual machines with lan
and wan network.  Please read the initial part of the script for
instructions about how to configure host machine

Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
2017-04-23 09:19:34 +08:00