From: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
To: 马耀 <327801865@qq.com>
Cc: Xen-devel <Xen-devel@lists.xensource.com>
Subject: Re: HVM (hypercall_grant_table_op) Problem
Date: Tue, 3 Jan 2012 15:30:08 -0500 [thread overview]
Message-ID: <20120103203008.GC17472@phenom.dumpdata.com> (raw)
In-Reply-To: <tencent_1975194D595A261C1C28650E@qq.com>
On Fri, Nov 18, 2011 at 12:52:13AM +0800, 马耀 wrote:
> Hi:
> I modified the netfont.c of Linux HVM domU installed PVonHVM.In it, I call hypercall_grant_table_op
> (GNTTABOP_map_grant_ref...), then dom0 shutdown and restart at once.
> I'm confused about this.
> Before Xen 3.4.3, Xen/arch/x86/HVM/hvm.c look like this:
> static long hvm_grant_table_op(unsigned int cmd, XEN_GUEST_HANDLE(void) uop, unsigned int count)
> {
> if ( (cmd != GNTTABOP_query_size) && (cmd != GNTTABOP_setup_table) )
> return -ENOSYS; /* all other commands need auditing */
> return do_grant_table_op(cmd, uop, count);
> }
> I know it hadn't support all grant_table_op but only two:GNTTABOP_query_size and GNTTABOP_setup_table.
>
> Now, after Xen4.0.0 and later, it look like below:
> static long hvm_grant_table_op( unsigned int cmd, XEN_GUEST_HANDLE(void) uop, unsigned int count)
> {
> if ( !grant_table_op_is_allowed(cmd) )
> return -ENOSYS; /* all other commands need auditing */
> return do_grant_table_op(cmd, uop, count);
> }
> static int grant_table_op_is_allowed(unsigned int cmd)
> {
> switch (cmd) {
> case GNTTABOP_query_size:
> case GNTTABOP_setup_table:
> case GNTTABOP_set_version:
> case GNTTABOP_copy:
> case GNTTABOP_map_grant_ref:
> case GNTTABOP_unmap_grant_ref:
> return 1;
> default:
> /* all other commands need auditing */
> return 0;
> }
> }
> From above, I conclude that I can map a HVM's page to another HVM, just like two PVs.
> Am I wrong? Who can give me some suggestion?
I am not sure if we ever came to a conclusion on what might be the trouble. Are you still experiencing
problems?
Thanks
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
prev parent reply other threads:[~2012-01-03 20:30 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-17 16:52 HVM (hypercall_grant_table_op) Problem 马耀
2011-11-24 11:58 ` Tim Deegan
2012-01-03 20:30 ` Konrad Rzeszutek Wilk [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=20120103203008.GC17472@phenom.dumpdata.com \
--to=konrad.wilk@oracle.com \
--cc=327801865@qq.com \
--cc=Xen-devel@lists.xensource.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.