mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Pratyush Yadav <pratyush@kernel.org>
To: George Guo <dongtai.guo@linux.dev>
Cc: chenhuacai@kernel.org,  rppt@kernel.org,
	 pasha.tatashin@soleen.com, pratyush@kernel.org,
	 shuah@kernel.org,  ardb@kernel.org, guodongtai@kylinos.cn,
	 kernel@xen0n.name,  graf@amazon.com, liukexin@kylinos.cn,
	 loongarch@lists.linux.dev, linux-kernel@vger.kernel.org,
	 kexec@lists.infradead.org, linux-mm@kvack.org,
	 linux-kselftest@vger.kernel.org, linux-efi@vger.kernel.org,
	Sourabh Jain <sourabhjain@linux.ibm.com>
Subject: Re: [PATCH v4 4/4] selftests/kho: add LoongArch vmtest support
Date: Fri, 04 Sep 2026 18:31:15 +0200	[thread overview]
Message-ID: <2vxzpkytvuzw.fsf@kernel.org> (raw)
In-Reply-To: <20260904031108.11986-1-dongtai.guo@linux.dev> (George Guo's message of "Fri, 4 Sep 2026 11:11:08 +0800")

On Fri, Sep 04 2026, George Guo wrote:

> Hi,
>
> While preparing v5, I retested the LoongArch vmtest without the explicit
> `kho_scratch=16M,16M,16M` setting. That setting was masking a pre-existing
> bug in the generic percentage-based KHO scratch sizing.
>
> The percentage heuristic itself is reasonable, but the old implementation
> calculated each per-node baseline after allocating the lowmem and global
> scratch areas. Since memblock allocations are marked MEMBLOCK_RSRV_KERN,
> those scratch areas were counted as new kernel demand and scaled again.
>
> On the 1 GiB LoongArch guest, the 98.45 MiB reservation baseline and 32 MiB
> alignment made the old ordering request 224 MiB of lowmem scratch followed
> by 672 MiB for node 0. The node allocation failed and disabled KHO. I sent
> a separate generic fix here:
>
>   https://lore.kernel.org/loongarch/20260904025101.9959-1-dongtai.guo@linux.dev

Oh, cool! Nice find. I just wrote Sourabh (+Cc) an email [0] about this
too.

I think there is other wonky stuff going on with scratch sizing, like
global scratch being inflated. See my email [0] about that.

Let me go review that patch, since this seems to be causing a lot of
pain.

[0] https://lore.kernel.org/kexec/20260821105609.983622-1-sourabhjain@linux.ibm.com/T/#t

>
> With that fix, the total aligned request is 448 MiB and the LoongArch
> vmtest passes using the default percentage-based sizing. I also ran the x86
> KHO vmtest with the fix; it passes as well.
>
> Therefore, I will remove `kho_scratch=16M,16M,16M` from loongarch.conf in
> v5 so that it tests the default sizing path, matching the existing x86
> selftest behavior.
>
> Thanks,
> George

-- 
Regards,
Pratyush Yadav

      reply	other threads:[~2026-09-04 16:31 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-07 10:37 [PATCH v4 0/4] LoongArch: add KHO support and selftests George Guo
2026-08-07 10:37 ` [PATCH v4 1/4] efi: add a KHO configuration table GUID George Guo
2026-08-09  4:18   ` Huacai Chen
2026-08-10 13:13     ` Ard Biesheuvel
2026-08-10 14:35       ` Huacai Chen
2026-08-10 16:19         ` Pratyush Yadav
2026-08-07 10:37 ` [PATCH v4 2/4] LoongArch: kexec: add KHO support George Guo
2026-08-10 14:42   ` Huacai Chen
2026-08-10 17:37   ` Pratyush Yadav
2026-08-07 10:37 ` [PATCH v4 3/4] liveupdate: luo_session: include linux/mm.h for virt/phys translation George Guo
2026-08-10 14:37   ` Huacai Chen
2026-08-10 17:39     ` Pratyush Yadav
2026-08-10 17:44       ` Pratyush Yadav
2026-08-12 10:25         ` George Guo
2026-08-07 10:37 ` [PATCH v4 4/4] selftests/kho: add LoongArch vmtest support George Guo
2026-08-09  4:16   ` Huacai Chen
2026-08-13 16:03     ` George Guo
2026-08-14  8:26       ` Huacai Chen
2026-08-25 14:58         ` George Guo
2026-09-04  3:11   ` George Guo
2026-09-04 16:31     ` Pratyush Yadav [this message]

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=2vxzpkytvuzw.fsf@kernel.org \
    --to=pratyush@kernel.org \
    --cc=ardb@kernel.org \
    --cc=chenhuacai@kernel.org \
    --cc=dongtai.guo@linux.dev \
    --cc=graf@amazon.com \
    --cc=guodongtai@kylinos.cn \
    --cc=kernel@xen0n.name \
    --cc=kexec@lists.infradead.org \
    --cc=linux-efi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=liukexin@kylinos.cn \
    --cc=loongarch@lists.linux.dev \
    --cc=pasha.tatashin@soleen.com \
    --cc=rppt@kernel.org \
    --cc=shuah@kernel.org \
    --cc=sourabhjain@linux.ibm.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

all inboxes | Powered by JetHome®