QEMU-Devel Archive mirror
 help / color / mirror / Atom feed
From: Bibo Mao <maobibo@loongson.cn>
To: Song Gao <gaosong@loongson.cn>, Peter Xu <peterx@redhat.com>,
	Fabiano Rosas <farosas@suse.de>, Thomas Huth <thuth@redhat.com>,
	Laurent Vivier <lvivier@redhat.com>
Cc: Paolo Bonzini <pbonzini@redhat.com>, qemu-devel@nongnu.org
Subject: [PATCH v4 4/5] hw/loongarch: Set minimium memory size as 256M
Date: Wed,  8 May 2024 11:11:09 +0800	[thread overview]
Message-ID: <20240508031110.2507477-5-maobibo@loongson.cn> (raw)
In-Reply-To: <20240508031110.2507477-1-maobibo@loongson.cn>

The minimum memory size for LoongArch UEFI bios is 256M, also some
test cases such as migration and qos use 256M memory by default.

Here set minimum memory size for Loongarch VirtMachine with 256M rather
than 1G, so that test cases with 256M memory can pass to run.

Signed-off-by: Bibo Mao <maobibo@loongson.cn>
---
 hw/loongarch/virt.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/hw/loongarch/virt.c b/hw/loongarch/virt.c
index c3bb343574..5d590cf92f 100644
--- a/hw/loongarch/virt.c
+++ b/hw/loongarch/virt.c
@@ -894,8 +894,8 @@ static void virt_init(MachineState *machine)
         cpu_model = LOONGARCH_CPU_TYPE_NAME("la464");
     }
 
-    if (ram_size < 1 * GiB) {
-        error_report("ram_size must be greater than 1G.");
+    if (ram_size < 256 * MiB) {
+        error_report("ram_size must be greater than 256M.");
         exit(1);
     }
     create_fdt(lvms);
-- 
2.39.3



  parent reply	other threads:[~2024-05-08  3:12 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-08  3:11 [PATCH v4 0/5] Add migration test for loongarch64 Bibo Mao
2024-05-08  3:11 ` [PATCH v4 1/5] hw/loongarch: Rename LOONGARCH_MACHINE with LOONGARCH_VIRT_MACHINE Bibo Mao
2024-05-08 15:08   ` Philippe Mathieu-Daudé
2024-05-08  3:11 ` [PATCH v4 2/5] hw/loongarch: Rename LoongArchMachineState with LoongArchVirtMachineState Bibo Mao
2024-05-08 15:08   ` Philippe Mathieu-Daudé
2024-05-08  3:11 ` [PATCH v4 3/5] hw/loongarch: Add compat machine for 9.0 Bibo Mao
2024-05-08  3:11 ` Bibo Mao [this message]
2024-05-08  3:11 ` [PATCH v4 5/5] tests: Add migration test for loongarch64 Bibo Mao
2024-05-08 21:58 ` [PATCH v4 0/5] " Philippe Mathieu-Daudé

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240508031110.2507477-5-maobibo@loongson.cn \
    --to=maobibo@loongson.cn \
    --cc=farosas@suse.de \
    --cc=gaosong@loongson.cn \
    --cc=lvivier@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=peterx@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=thuth@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).