From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.90_1) id 1mZsrJ-0005vf-Pi for mharc-grub-devel@gnu.org; Mon, 11 Oct 2021 06:48:43 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:49460) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mZsrG-0005sl-T1 for grub-devel@gnu.org; Mon, 11 Oct 2021 06:48:39 -0400 Received: from mail-pf1-x429.google.com ([2607:f8b0:4864:20::429]:41808) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mZsrE-0003Ep-T3 for grub-devel@gnu.org; Mon, 11 Oct 2021 06:48:38 -0400 Received: by mail-pf1-x429.google.com with SMTP id y7so4976501pfg.8 for ; Mon, 11 Oct 2021 03:48:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=axtens.net; s=google; h=from:to:cc:subject:in-reply-to:references:date:message-id :mime-version; bh=D8IhZqbGGjzWJbxh2GkvJJMs9iIKnJ82/5hsxkoR+Xo=; b=UCnZlEXGtkXT0ezuty3zP3pzEHlt7M/4WiHCZQgIF7i79ONsNIV0RBUotwrlvBMchU l8NDufnPbxGxDDyf+PuZ2DC1YaR++CTcGybASFofNk8unudlFGzpbhk06MGenxGnmWkj 5C/sd5lX0jTzNwzwVwGrrendMsDWqxVKootIM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date :message-id:mime-version; bh=D8IhZqbGGjzWJbxh2GkvJJMs9iIKnJ82/5hsxkoR+Xo=; b=6k508BWkL+Dxm4Tps8bitxjdpCKlvFJ13qsIQiNcdl2XS+w5jZ+NRZHq4H/7H46vuQ 7YnDRu9sX084mEJQ8RLxGyJRxF8r0JU33O+MAm3h16ZxsAX5xaQNm2tB/xbxAGldNYqI PwZX3ph036Pkg2z8On0ih1AmADG/xXEYV9HmSfhBNk4DfSouUCN/klaui4yJ39jqrIRc 1yr0LqUrSN3lWShHB3Ge/8+S3WinHAl/TWQ1UlbiDuVunWCBBG1g9Bgy95PmsXk+79sE f/mnbiD/JgbQnJtEg6FjJt+lrL75rdhNNs0yKvfP7gPkaAn6YcftQ5EWMyByZnIGLp3b kd1w== X-Gm-Message-State: AOAM530rCVNynXf3LdkQF4BRllGP4nO96J+fGOSJ6CKppaV7HeVj9T/d Xj0pJQwlRdbTPOvDGVd6CoDtJS0pNDBY5Q== X-Google-Smtp-Source: ABdhPJyQDleskV1d4C+fnDhBtd5XrIM5BApMkJ6VnlqYKVEgLQ0c7umPoCLyVru+OS2PUHVKhf3jTQ== X-Received: by 2002:a65:5a8e:: with SMTP id c14mr17785665pgt.125.1633949314402; Mon, 11 Oct 2021 03:48:34 -0700 (PDT) Received: from localhost ([2001:4479:e300:600:f15c:ff7:8daf:5112]) by smtp.gmail.com with ESMTPSA id j8sm6981121pfe.105.2021.10.11.03.48.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 11 Oct 2021 03:48:33 -0700 (PDT) From: Daniel Axtens To: Glenn Washburn , grub-devel@gnu.org, Daniel Kiper Cc: Glenn Washburn Subject: Re: [PATCH v2] grub-shell: Boot PowerPC using PMU instead of CUDA for power management In-Reply-To: <20211007205251.159703-1-development@efficientek.com> References: <20211007205251.159703-1-development@efficientek.com> Date: Mon, 11 Oct 2021 21:48:30 +1100 Message-ID: <87fst74z29.fsf@dja-thinkpad.axtens.net> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2607:f8b0:4864:20::429; envelope-from=dja@axtens.net; helo=mail-pf1-x429.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Oct 2021 10:48:40 -0000 Glenn Washburn writes: > A recent refactoring of CUDA command code has exposed a bug in OpenBIOS[1] > which was causing system powerdown and system reset to fail, thus causing > the Qemu instance to hang. This in turn caused the grub-shell command to > timeout causing it to return an error code when the test actually completed > successfully. > > Since it could be a while before the patch fixing this issue in OpenBIOS > filters down to the average distro, switch to PMU to allow powerdowns and > reboots to work as expected. > This is good for ppc, but it breaks for pseries: $ echo 'echo hi;' | ./grub-shell --pseries WARNING: Image format was not specified for '/tmp/tmp.W9bYMpcqGX' and probing guessed raw. Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted. Specify the 'raw' format explicitly to remove the restrictions. qemu-system-ppc64: Property 'pseries-hirsute-machine.via' not found It ends up being: timeout -s KILL 60 qemu-system-ppc64 -M mac99,via=pmu -M pseries \ -no-reboot -nographic -monitor file:/dev/null \ -fw_cfg name=etc/sercon-port,string=0 -serial file:/dev/stdout \ -hda /tmp/tmp.i96l2WaBHo -boot c I think `-M pseries` will override the `mac99` part but not the `via=pmu`. Kind regards, Daniel > [1] https://gitlab.com/qemu-project/qemu/-/issues/624 > > Signed-off-by: Glenn Washburn > --- > This is a correction of the commit message from patch #8 of the patch series > titled "More test fixes/improvements". The changes remain the same. > > Glenn > > Range-diff against v1: > 1: e13454839 ! 1: 754e7e77b grub-shell: Boot PowerPC using PMU instead of CUDA for power management > @@ Metadata > ## Commit message ## > grub-shell: Boot PowerPC using PMU instead of CUDA for power management > > - At some point it looks like the defualt machine for qemu-system-ppc started > - using CUDA as a backend for power management. This causes the machine to > - throw an exception and not actually power down the VM[1]. Switching to PMU > - allows power downs and reboots to work as expceted. > + A recent refactoring of CUDA command code has exposed a bug in OpenBIOS[1] > + which was causing system powerdown and system reset to fail, thus causing > + the Qemu instance to hang. This in turn caused the grub-shell command to > + timeout causing it to return an error code when the test actually completed > + successfully. > + > + Since it could be a while before the patch fixing this issue in OpenBIOS > + filters down to the average distro, switch to PMU to allow powerdowns and > + reboots to work as expected. > > [1] https://gitlab.com/qemu-project/qemu/-/issues/624 > > > tests/util/grub-shell.in | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/tests/util/grub-shell.in b/tests/util/grub-shell.in > index 93e9f5148..5354d8678 100644 > --- a/tests/util/grub-shell.in > +++ b/tests/util/grub-shell.in > @@ -84,6 +84,7 @@ case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in > serial_null="-serial null" > netbootext=elf > trim=1 > + qemuopts="-M mac99,via=pmu $qemuopts" > ;; > > sparc64-ieee1275) > -- > 2.27.0 > > > _______________________________________________ > Grub-devel mailing list > Grub-devel@gnu.org > https://lists.gnu.org/mailman/listinfo/grub-devel