qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Avi Kivity <avi@qumranet.com>
To: Glauber Costa <glommer@redhat.com>
Cc: aliguori@us.ibm.com, kvm@vger.kernel.org, apevec@redhat.com,
	Glauber Costa <glommer@gmail.com>,
	qemu-devel@nongnu.org, chrisw@sous-sol.org,
	Eduardo Habkost <ehabkost@redhat.com>
Subject: [Qemu-devel] Re: [PATCH] Fix up pxe boot
Date: Tue, 09 Sep 2008 17:17:32 +0300	[thread overview]
Message-ID: <48C6857C.9010404@qumranet.com> (raw)
In-Reply-To: <20080908153801.GA3724@poweredge.glommer>

Glauber Costa wrote:
> On Sun, Sep 07, 2008 at 09:42:07AM +0300, Avi Kivity wrote:
>   
>> Glauber Costa wrote:
>>     
>>> After a second look, here's what it seems to me:
>>>
>>> It's not in a generic place, such as ldl, because in general, we may want to grab
>>> a 32-bit value from a 64-bit address. This is perfectly valid.
>>>
>>> It's a specifity that the pop instruction, when not in long mode (manual says that in 64-bit mode
>>> no 32-bit operand is valid, but then again, qemu should use the POPQ macro), that ssp:sp may overflow,
>>> but we don't want it.
>>>
>>> It would be possible to do something more generic if we had a segment_to_linear() function, that returned
>>> the linear address, but we don't.
>>>
>>> Does it make more sense to you?
>>>   
>>>       
>> Yes.
>>
>> I guess tcg code is mostly safe since it generates 32-bit additions for  
>> segment bases, so this is limited to the places you identified.  And a  
>> helper to add segment bases would be helpful.
>>
>> -- 
>> error compiling committee.c: too many arguments to function
>>
>>     
>
> what do you think of the attached version?
>   

Looks fine to me.  One can thing of a cleverer helper (that receives the 
segment number and adds its base to the offset), but there's not reason 
to do this all at one.

-- 
error compiling committee.c: too many arguments to function

  reply	other threads:[~2008-09-09 14:17 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-09-01 21:11 [Qemu-devel] [PATCH] Fix up pxe boot Glauber Costa
2008-09-02  8:39 ` [Qemu-devel] " Avi Kivity
2008-09-02 11:07   ` Glauber Costa
2008-09-02 15:20     ` Avi Kivity
2008-09-02 15:22       ` Glauber Costa
2008-09-03 19:27       ` Glauber Costa
2008-09-07  6:42         ` Avi Kivity
2008-09-08 15:38           ` Glauber Costa
2008-09-09 14:17             ` Avi Kivity [this message]
2008-09-09 14:48             ` Anthony Liguori

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=48C6857C.9010404@qumranet.com \
    --to=avi@qumranet.com \
    --cc=aliguori@us.ibm.com \
    --cc=apevec@redhat.com \
    --cc=chrisw@sous-sol.org \
    --cc=ehabkost@redhat.com \
    --cc=glommer@gmail.com \
    --cc=glommer@redhat.com \
    --cc=kvm@vger.kernel.org \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).