Re: [Xen-devel] [PATCH v5 2/2] xen: modify kernel mappingscorresponding to granted pages

From: Ian Campbell
Date: Thu Sep 29 2011 - 10:18:11 EST


On Thu, 2011-09-29 at 14:55 +0100, Konrad Rzeszutek Wilk wrote:
> > /* Xen machine address */
> > @@ -31,8 +32,10 @@ typedef struct xpaddr {
> > #define INVALID_P2M_ENTRY (~0UL)
> > #define FOREIGN_FRAME_BIT (1UL<<(BITS_PER_LONG-1))
> > #define IDENTITY_FRAME_BIT (1UL<<(BITS_PER_LONG-2))
> > +#define GRANT_FRAME_BIT (1UL<<(BITS_PER_LONG-3))
>
> I am going to change that to (BITS_PER_LONG-1) as we aren't
> using the P2M. (and add that comment in the file).

You should also move it away from/out of the "/**** MACHINE <-> PHYSICAL
CONVERSION MACROS ****/" section, otherwise it's just confusing.

The associated GRANT_FRAME macro seems to be unused.

But what is that bit in page->private actually used for? This patch adds
it in m2p_add_override and masks it off in m2p_find_override, but
doesn't otherwise appear to use it.

Ian.

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