All of lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Huth <thuth@redhat.com>
To: Paolo Bonzini <pbonzini@redhat.com>, kvm@vger.kernel.org
Cc: namit@vmware.com
Subject: Re: [PATCH kvm-unit-tests] x86: fix stack pointer after call
Date: Thu, 25 Jun 2020 15:01:39 +0200	[thread overview]
Message-ID: <ae3f91d8-9e6a-c90d-0fca-5e4df2833a0c@redhat.com> (raw)
In-Reply-To: <20200625111526.1620-1-pbonzini@redhat.com>

On 25/06/2020 13.15, Paolo Bonzini wrote:
> Since setup_multiboot has a C calling convention, the stack pointer must
> be adjusted after the call.  Without this change, the bottom of the
> percpu area would be 4 bytes below the bottom of the stack.
> 
> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
> ---
>   x86/cstart.S | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/x86/cstart.S b/x86/cstart.S
> index deb08b7..409cb00 100644
> --- a/x86/cstart.S
> +++ b/x86/cstart.S
> @@ -116,6 +116,7 @@ start:
>   
>           push %ebx
>           call setup_multiboot
> +        addl $4, %esp
>           call setup_libcflat
>           mov mb_cmdline(%ebx), %eax
>           mov %eax, __args

Looks right.

Reviewed-by: Thomas Huth <thuth@redhat.com>


      reply	other threads:[~2020-06-25 13:01 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-25 11:15 [PATCH kvm-unit-tests] x86: fix stack pointer after call Paolo Bonzini
2020-06-25 13:01 ` Thomas Huth [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=ae3f91d8-9e6a-c90d-0fca-5e4df2833a0c@redhat.com \
    --to=thuth@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=namit@vmware.com \
    --cc=pbonzini@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.