lkml.org 
[lkml]   [2007]   [Aug]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 1/3] Implement emulator_write_phys()
From
Date

On Mon, 2007-08-27 at 18:45 +0300, Avi Kivity wrote:
> Anthony Liguori wrote:
> > Since a hypercall may span two pages and is a gva, we need a function to write
> > to a gva that may span multiple pages. emulator_write_phys() seems like the
> > logical choice for this.
> >
> > @@ -962,8 +962,35 @@ static int emulator_write_std(unsigned long addr,
> > unsigned int bytes,
> > struct kvm_vcpu *vcpu
>
> I think that emulator_write_emulated(), except for being awkwardly
> named, should do the job. We have enough APIs.

I'll drop this patch. My mistakenly thought emulator_write_emulated()
took a GPA. Thanks!

Regards,

Anthony Liguori

> But! We may not overwrite the hypercall instruction while a vcpu may be
> executing, since there's no atomicity guarantee for code fetch. We have
> to to be out of guest mode while writing that insn.
>

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2007-08-27 20:13    [W:0.103 / U:0.864 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site