All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Nico Boehr" <nrb@linux.ibm.com>
To: "Janosch Frank" <frankja@linux.ibm.com>, <kvm@vger.kernel.org>
Cc: <linux-s390@vger.kernel.org>, <imbrenda@linux.ibm.com>,
	<thuth@redhat.com>, <david@redhat.com>
Subject: Re: [kvm-unit-tests PATCH 2/2] s390x: diag10: Check page clear
Date: Wed, 28 May 2025 16:56:33 +0200	[thread overview]
Message-ID: <DA7VQLOWWTUJ.P37SCGP032T3@linux.ibm.com> (raw)
In-Reply-To: <20250528091412.19483-3-frankja@linux.ibm.com>

On Wed May 28, 2025 at 11:13 AM CEST, Janosch Frank wrote:
> We should get a new page after we discarded the page.
> So let's check for that.
>
> Signed-off-by: Janosch Frank <frankja@linux.ibm.com>
> ---
>  s390x/diag10.c | 11 +++++++++++
>  1 file changed, 11 insertions(+)
>
> diff --git a/s390x/diag10.c b/s390x/diag10.c
> index 00725f58..b68481ad 100644
> --- a/s390x/diag10.c
> +++ b/s390x/diag10.c
> @@ -94,6 +94,16 @@ static void test_priv(void)
>  	report_prefix_pop();
>  }
>  
> +static void test_content(void)
> +{
> +	report_prefix_push("content");
> +	memset((void *)page0, 0x42, PAGE_SIZE);
> +	memset((void *)page1, 0, PAGE_SIZE);
> +	diag10(page0, page0);
> +	report(!memcmp((void *)page0, (void *)page1, PAGE_SIZE), "Page cleared");
> +	report_prefix_pop();
> +}

Would be nice to test that we don't clear too much, but this is clearly better
than what we had before so:

Reviewed-by: Nico Boehr <nrb@linux.ibm.com>

      parent reply	other threads:[~2025-05-28 14:56 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-28  9:13 [kvm-unit-tests PATCH 0/2] s390x: diag10: Fixup Janosch Frank
2025-05-28  9:13 ` [kvm-unit-tests PATCH 1/2] s390x: diag10: Fence tcg and pv environments Janosch Frank
2025-05-28  9:41   ` Claudio Imbrenda
2025-05-28 11:13     ` Janosch Frank
2025-05-28 12:02       ` Claudio Imbrenda
2025-05-28  9:55   ` Thomas Huth
2025-05-28 10:59     ` Janosch Frank
2025-05-28 14:50   ` Nico Boehr
2025-05-28  9:13 ` [kvm-unit-tests PATCH 2/2] s390x: diag10: Check page clear Janosch Frank
2025-05-28  9:42   ` Claudio Imbrenda
2025-05-28 14:56   ` Nico Boehr [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=DA7VQLOWWTUJ.P37SCGP032T3@linux.ibm.com \
    --to=nrb@linux.ibm.com \
    --cc=david@redhat.com \
    --cc=frankja@linux.ibm.com \
    --cc=imbrenda@linux.ibm.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-s390@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.