From: "Jan Beulich" Subject: [PATCH 6/6] gnttab: make struct grant_mapping private Date: Fri, 12 Jun 2015 11:38:44 +0100 Message-ID: <557AD2D40200007800084232@mail.emea.novell.com> References: <557AD03E02000078000841B4@mail.emea.novell.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=__Part556177A4.1__=" Return-path: Received: from mail6.bemta3.messagelabs.com ([195.245.230.39]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1Z3MMI-0004Qz-IW for xen-devel@lists.xenproject.org; Fri, 12 Jun 2015 10:38:46 +0000 In-Reply-To: <557AD03E02000078000841B4@mail.emea.novell.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: xen-devel Cc: Ian Campbell , Keir Fraser , Ian Jackson , Tim Deegan List-Id: xen-devel@lists.xenproject.org This is a MIME message. If you are reading this text, you may want to consider changing to a mail reader or gateway that understands how to properly handle MIME multipart messages. --=__Part556177A4.1__= Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable Content-Disposition: inline This documents that no entity outside of gnttab.c actually accesses objects of that type. Signed-off-by: Jan Beulich --- a/xen/common/grant_table.c +++ b/xen/common/grant_table.c @@ -113,6 +113,16 @@ struct gnttab_unmap_common { goto _lbl; \ } while ( 0 ) =20 +/* + * Tracks a mapping of another domain's grant reference. Each domain has = a + * table of these, indexes into which are returned as a 'mapping handle'. + */ +struct grant_mapping { + u32 ref; /* grant ref */ + u16 flags; /* 0-4: GNTMAP_* ; 5-15: unused */ + domid_t domid; /* granting domain */ +}; + #define MAPTRACK_PER_PAGE (PAGE_SIZE / sizeof(struct grant_mapping)) #define maptrack_entry(t, e) \ ((t)->maptrack[(e)/MAPTRACK_PER_PAGE][(e)%MAPTRACK_PER_PAGE]) --- a/xen/include/xen/grant_table.h +++ b/xen/include/xen/grant_table.h @@ -52,16 +52,6 @@ /* The maximum size of a grant table. */ extern unsigned int max_grant_frames; =20 -/* - * Tracks a mapping of another domain's grant reference. Each domain has = a - * table of these, indexes into which are returned as a 'mapping handle'. - */ -struct grant_mapping { - u32 ref; /* grant ref */ - u16 flags; /* 0-4: GNTMAP_* ; 5-15: unused */ - domid_t domid; /* granting domain */ -}; - /* Per-domain grant information. */ struct grant_table { /* Table size. Number of frames shared with guest */ --=__Part556177A4.1__= Content-Type: text/plain; name="gnttab-hide-struct-grant_mapping.patch" Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename="gnttab-hide-struct-grant_mapping.patch" gnttab: make struct grant_mapping private=0A=0AThis documents that no = entity outside of gnttab.c actually accesses=0Aobjects of that type.=0A=0AS= igned-off-by: Jan Beulich =0A=0A--- a/xen/common/grant_t= able.c=0A+++ b/xen/common/grant_table.c=0A@@ -113,6 +113,16 @@ struct = gnttab_unmap_common {=0A goto _lbl; = \=0A } while ( 0 )=0A =0A+/*=0A+ * Tracks a mapping of another = domain's grant reference. Each domain has a=0A+ * table of these, indexes = into which are returned as a 'mapping handle'.=0A+ */=0A+struct grant_mappi= ng {=0A+ u32 ref; /* grant ref */=0A+ u16 flags; = /* 0-4: GNTMAP_* ; 5-15: unused */=0A+ domid_t domid; = /* granting domain */=0A+};=0A+=0A #define MAPTRACK_PER_PAGE (PAGE_SIZE / = sizeof(struct grant_mapping))=0A #define maptrack_entry(t, e) \=0A = ((t)->maptrack[(e)/MAPTRACK_PER_PAGE][(e)%MAPTRACK_PER_PAGE])=0A--- = a/xen/include/xen/grant_table.h=0A+++ b/xen/include/xen/grant_table.h=0A@@ = -52,16 +52,6 @@=0A /* The maximum size of a grant table. */=0A extern = unsigned int max_grant_frames;=0A =0A-/*=0A- * Tracks a mapping of another = domain's grant reference. Each domain has a=0A- * table of these, indexes = into which are returned as a 'mapping handle'.=0A- */=0A-struct grant_mappi= ng {=0A- u32 ref; /* grant ref */=0A- u16 flags; = /* 0-4: GNTMAP_* ; 5-15: unused */=0A- domid_t domid; = /* granting domain */=0A-};=0A-=0A /* Per-domain grant information. */=0A = struct grant_table {=0A /* Table size. Number of frames shared with = guest */=0A --=__Part556177A4.1__= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel --=__Part556177A4.1__=--