[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] Re: [PATCH] Fix >4G i386 PAE grant table interface



Keir Fraser wrote:


On 4/11/06 2:25 pm, "Steven Rostedt" <srostedt@xxxxxxxxxx> wrote:

So is there a difference between create_grant_pte_mapping and
create_grant_va_mapping. As well as destroy_grant_pte_mapping and
destroy_grant_va_mapping. So calling pte create, and then va destroy on
the same mapping is not a bug?

That would be a bug, if it were possible, which it's not. 'flags' is not a
parameter to the gnttab_unmap operation. Xen remembers the flags from the
original map operation.


OK, took me some time to find what you mean:

__gnttab_unmap_grant_ref(
    struct gnttab_unmap_grant_ref *op)
{
 [...]

    map = &ld->grant_table->maptrack[op->handle];

 [...]

    dom   = map->domid;
    ref   = map->ref;
    flags = map->flags;

 [...]

    if ( (op->host_addr != 0) && (flags & GNTMAP_host_map) )
    {
        if ( (rc = destroy_grant_host_mapping(op->host_addr,
                                              frame, flags)) < 0 )
            goto unmap_out;



OK, but it can be a problem on the kernel side because of the Xen auto translate physmap feature. But not as bad as I thought.

But it's still good to be consistent.

-- Steve

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.