xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Tej <bewith.tej@gmail.com>
To: xen-devel@lists.xensource.com
Subject: Confusion about copy_to/from_guest
Date: Mon, 26 Apr 2010 08:02:40 +0530	[thread overview]
Message-ID: <h2gf1c9d251004251932s19c2f51ofb422ee27c366fca@mail.gmail.com> (raw)

All,

Small and naive question about the semantics of copy_to/from_guest. In
Kernel space I have created a linked list lets say 10 elements. Now I
have created similar list in hypervisor.

Now passing the list_head from kernel using hypercall. Now how do I
copy the element between kernel and hypervisor.

1. copy_from_guest(hyp_list_head, arg, 1) or
copy_from_guest(hyp_list_head, arg, <num_of_elements_list>)
2. copy_to_guest(arg, hyp_list_head, 1) or copy_to_guest(arg,
hyp_list_head, <num of element in list>)

2nd question:
I did first one, but first element of list was not accessible in
hypervisor space, why?


It looks like I am doing something horribly wrong, so can someone
point out that.

Thanks for any help
-tej

             reply	other threads:[~2010-04-26  2:32 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-26  2:32 Tej [this message]
2010-04-26  5:33 ` Confusion about copy_to/from_guest Keir Fraser
2010-04-27 11:52   ` Tej

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=h2gf1c9d251004251932s19c2f51ofb422ee27c366fca@mail.gmail.com \
    --to=bewith.tej@gmail.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 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).