From: Claudio Imbrenda <imbrenda@linux.ibm.com>
To: Janosch Frank <frankja@linux.ibm.com>
Cc: kvm@vger.kernel.org, linux-s390@vger.kernel.org,
david@redhat.com, thuth@redhat.com
Subject: Re: [kvm-unit-tests PATCH] s390x: snippets: c: Load initial cr0
Date: Thu, 31 Mar 2022 16:58:42 +0200 [thread overview]
Message-ID: <20220331165842.4e79083f@p-imbrenda> (raw)
In-Reply-To: <20220331125515.1941-1-frankja@linux.ibm.com>
On Thu, 31 Mar 2022 12:55:15 +0000
Janosch Frank <frankja@linux.ibm.com> wrote:
> As soon as we use C we need to set the AFP bit in cr0 so we can use
> all fprs.
>
seems like a good idea
> Signed-off-by: Janosch Frank <frankja@linux.ibm.com>
Reviewed-by: Claudio Imbrenda <imbrenda@linux.ibm.com>
> ---
> s390x/snippets/c/cstart.S | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/s390x/snippets/c/cstart.S b/s390x/snippets/c/cstart.S
> index aaa5380c..a7d4cd42 100644
> --- a/s390x/snippets/c/cstart.S
> +++ b/s390x/snippets/c/cstart.S
> @@ -12,6 +12,8 @@
> .section .init
> .globl start
> start:
> + larl %r1, initial_cr0
> + lctlg %c0, %c0, 0(%r1)
> /* XOR all registers with themselves to clear them fully. */
> .irp i, 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15
> xgr \i,\i
> @@ -34,3 +36,7 @@ exit:
> /* For now let's only use cpu 0 in snippets so this will always work. */
> xgr %r0, %r0
> sigp %r2, %r0, SIGP_STOP
> +
> +initial_cr0:
> + /* enable AFP-register control, so FP regs (+BFP instr) can be used */
> + .quad 0x0000000000040000
prev parent reply other threads:[~2022-03-31 14:58 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-31 12:55 [kvm-unit-tests PATCH] s390x: snippets: c: Load initial cr0 Janosch Frank
2022-03-31 14:58 ` Claudio Imbrenda [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=20220331165842.4e79083f@p-imbrenda \
--to=imbrenda@linux.ibm.com \
--cc=david@redhat.com \
--cc=frankja@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox