WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] Support for mii_xxx functions?

To: "Paul K. Fisher" <pfisher@xxxxxxxxxxxxxxxxxxxx>
Subject: Re: [Xen-devel] Support for mii_xxx functions?
From: Keir Fraser <Keir.Fraser@xxxxxxxxxxxx>
Date: Fri, 24 Oct 2003 11:16:12 +0100
Cc: "Keir Fraser" <Keir.Fraser@xxxxxxxxxxxx>, "Xen-Devel" <xen-devel@xxxxxxxxxxxxxxxxxxxxx>
Delivery-date: Fri, 24 Oct 2003 13:23:30 +0100
Envelope-to: steven.hand@xxxxxxxxxxxx
In-reply-to: Your message of "Wed, 22 Oct 2003 08:28:37 CDT." <DEEKLMFOILALDEICNAAPIEGICAAA.pfisher@xxxxxxxxxxxxxxxxxxxx>
List-archive: <http://sourceforge.net/mailarchive/forum.php?forum=xen-devel>
List-help: <mailto:xen-devel-request@lists.sourceforge.net?subject=help>
List-id: List for Xen developers <xen-devel.lists.sourceforge.net>
List-post: <mailto:xen-devel@lists.sourceforge.net>
List-subscribe: <https://lists.sourceforge.net/lists/listinfo/xen-devel>, <mailto:xen-devel-request@lists.sourceforge.net?subject=subscribe>
List-unsubscribe: <https://lists.sourceforge.net/lists/listinfo/xen-devel>, <mailto:xen-devel-request@lists.sourceforge.net?subject=unsubscribe>
Sender: xen-devel-admin@xxxxxxxxxxxxxxxxxxxxx
> One the receive side the code compiles as is, but I have not yet verified if
> the interface it calls -- eth_copy_and_sum() -- will work, or if I need to
> changed it to somehting like this:
> 
> >  vdata = map_domain_mem(skb->data);
> >  copy 'len' bytes to 'vdata' from NIC buffer
> >  unmap_domain_mem(vdata);
> >  skb_put(len);
> 
> as you suggested.  If you (or anyone else) has any thoughts on why this (and
> other) skbuff interfaces where not supported in Xen, that would help with my
> digging.  Remember, I'm not at all familiar with the linux kernel source so
> I have to read it all to know what anything is doing... on the other hand it
> is just time and code...

You will have to change it. Any function which will access the packet
data must use map_domain_mem(), as the data pointer within the skbuff
is not usable directly by Xen.

Note that some skb_* functions already do the map_domain_mem() for you
--- any skb copying function based on skb_copy_bits() is safe.

Note also that we hope fairly soon (within the next few months) to
move all device drivers into "I/O domains" running outside of Xen in
ring 1. At that point we will hopefully be able to run Linux device
drivers unmodified, so this porting pain will no longer be necessary
:-)

 -- Keir


-------------------------------------------------------
This SF.net email is sponsored by: The SF.net Donation Program.
Do you like what SourceForge.net is doing for the Open
Source Community?  Make a contribution, and help us add new
features and functionality. Click here: http://sourceforge.net/donate/
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/xen-devel