From: Anthony Liguori <aliguori@us.ibm.com>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] x86: Add NULL check to lsl
Date: Fri, 20 Mar 2009 12:32:04 -0500 [thread overview]
Message-ID: <49C3D314.6000307@us.ibm.com> (raw)
In-Reply-To: <49BE91C7.402@siemens.com>
Jan Kiszka wrote:
> According to the Intel specs, lsl performs a check against NULL for the
> provided selector, just like lar does. helper_lar() includes the
> corresponding code, helper_lsl() was lacking it so far.
>
> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
>
Applied to trunk and stable. Thanks.
Regards,
Anthony Liguori
> ---
>
> target-i386/op_helper.c | 2 ++
> 1 files changed, 2 insertions(+), 0 deletions(-)
>
> diff --git a/target-i386/op_helper.c b/target-i386/op_helper.c
> index 25e079b..be09263 100644
> --- a/target-i386/op_helper.c
> +++ b/target-i386/op_helper.c
> @@ -3241,6 +3241,8 @@ target_ulong helper_lsl(target_ulong selector1)
>
> selector = selector1 & 0xffff;
> eflags = helper_cc_compute_all(CC_OP);
> + if ((selector & 0xfffc) == 0)
> + goto fail;
> if (load_segment(&e1, &e2, selector) != 0)
> goto fail;
> rpl = selector & 3;
>
>
>
>
prev parent reply other threads:[~2009-03-20 17:32 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-03-16 17:52 [Qemu-devel] [PATCH] x86: Add NULL check to lsl Jan Kiszka
2009-03-20 17:32 ` Anthony Liguori [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=49C3D314.6000307@us.ibm.com \
--to=aliguori@us.ibm.com \
--cc=qemu-devel@nongnu.org \
/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.