iPXE
grant_table.h
Go to the documentation of this file.
1 /* SPDX-License-Identifier: MIT */
2 /******************************************************************************
3  * grant_table.h
4  *
5  * Interface for granting foreign access to page frames, and receiving
6  * page-ownership transfers.
7  *
8  * Copyright (c) 2004, K A Fraser
9  */
10 
11 #ifndef __XEN_PUBLIC_GRANT_TABLE_H__
12 #define __XEN_PUBLIC_GRANT_TABLE_H__
13 
14 FILE_LICENCE ( MIT );
15 
16 #include "xen.h"
17 
18 /*
19  * `incontents 150 gnttab Grant Tables
20  *
21  * Xen's grant tables provide a generic mechanism to memory sharing
22  * between domains. This shared memory interface underpins the split
23  * device drivers for block and network IO.
24  *
25  * Each domain has its own grant table. This is a data structure that
26  * is shared with Xen; it allows the domain to tell Xen what kind of
27  * permissions other domains have on its pages. Entries in the grant
28  * table are identified by grant references. A grant reference is an
29  * integer, which indexes into the grant table. It acts as a
30  * capability which the grantee can use to perform operations on the
31  * granter's memory.
32  *
33  * This capability-based system allows shared-memory communications
34  * between unprivileged domains. A grant reference also encapsulates
35  * the details of a shared page, removing the need for a domain to
36  * know the real machine address of a page it is sharing. This makes
37  * it possible to share memory correctly with domains running in
38  * fully virtualised memory.
39  */
40 
41 /***********************************
42  * GRANT TABLE REPRESENTATION
43  */
44 
45 /* Some rough guidelines on accessing and updating grant-table entries
46  * in a concurrency-safe manner. For more information, Linux contains a
47  * reference implementation for guest OSes (drivers/xen/grant_table.c, see
48  * http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=blob;f=drivers/xen/grant-table.c;hb=HEAD
49  *
50  * NB. WMB is a no-op on current-generation x86 processors. However, a
51  * compiler barrier will still be required.
52  *
53  * Introducing a valid entry into the grant table:
54  * 1. Write ent->domid.
55  * 2. Write ent->frame:
56  * GTF_permit_access: Frame to which access is permitted.
57  * GTF_accept_transfer: Pseudo-phys frame slot being filled by new
58  * frame, or zero if none.
59  * 3. Write memory barrier (WMB).
60  * 4. Write ent->flags, inc. valid type.
61  *
62  * Invalidating an unused GTF_permit_access entry:
63  * 1. flags = ent->flags.
64  * 2. Observe that !(flags & (GTF_reading|GTF_writing)).
65  * 3. Check result of SMP-safe CMPXCHG(&ent->flags, flags, 0).
66  * NB. No need for WMB as reuse of entry is control-dependent on success of
67  * step 3, and all architectures guarantee ordering of ctrl-dep writes.
68  *
69  * Invalidating an in-use GTF_permit_access entry:
70  * This cannot be done directly. Request assistance from the domain controller
71  * which can set a timeout on the use of a grant entry and take necessary
72  * action. (NB. This is not yet implemented!).
73  *
74  * Invalidating an unused GTF_accept_transfer entry:
75  * 1. flags = ent->flags.
76  * 2. Observe that !(flags & GTF_transfer_committed). [*]
77  * 3. Check result of SMP-safe CMPXCHG(&ent->flags, flags, 0).
78  * NB. No need for WMB as reuse of entry is control-dependent on success of
79  * step 3, and all architectures guarantee ordering of ctrl-dep writes.
80  * [*] If GTF_transfer_committed is set then the grant entry is 'committed'.
81  * The guest must /not/ modify the grant entry until the address of the
82  * transferred frame is written. It is safe for the guest to spin waiting
83  * for this to occur (detect by observing GTF_transfer_completed in
84  * ent->flags).
85  *
86  * Invalidating a committed GTF_accept_transfer entry:
87  * 1. Wait for (ent->flags & GTF_transfer_completed).
88  *
89  * Changing a GTF_permit_access from writable to read-only:
90  * Use SMP-safe CMPXCHG to set GTF_readonly, while checking !GTF_writing.
91  *
92  * Changing a GTF_permit_access from read-only to writable:
93  * Use SMP-safe bit-setting instruction.
94  */
95 
96 /*
97  * Reference to a grant entry in a specified domain's grant table.
98  */
100 
101 /*
102  * A grant table comprises a packed array of grant entries in one or more
103  * page frames shared between Xen and a guest.
104  * [XEN]: This field is written by Xen and read by the sharing guest.
105  * [GST]: This field is written by the guest and read by Xen.
106  */
107 
108 /*
109  * Version 1 of the grant table entry structure is maintained largely for
110  * backwards compatibility. New guests are recommended to support using
111  * version 2 to overcome version 1 limitations, but to default to version 1.
112  */
113 #if __XEN_INTERFACE_VERSION__ < 0x0003020a
114 #define grant_entry_v1 grant_entry
115 #define grant_entry_v1_t grant_entry_t
116 #endif
118  /* GTF_xxx: various type and flag information. [XEN,GST] */
120  /* The domain being granted foreign privileges. [GST] */
122  /*
123  * GTF_permit_access: GFN that @domid is allowed to map and access. [GST]
124  * GTF_accept_transfer: GFN that @domid is allowed to transfer into. [GST]
125  * GTF_transfer_completed: MFN whose ownership transferred by @domid
126  * (non-translated guests only). [XEN]
127  */
129 };
131 
132 /* The first few grant table entries will be preserved across grant table
133  * version changes and may be pre-populated at domain creation by tools.
134  */
135 #define GNTTAB_NR_RESERVED_ENTRIES 8
136 #define GNTTAB_RESERVED_CONSOLE 0
137 #define GNTTAB_RESERVED_XENSTORE 1
138 
139 /*
140  * Type of grant entry.
141  * GTF_invalid: This grant entry grants no privileges.
142  * GTF_permit_access: Allow @domid to map/access @frame.
143  * GTF_accept_transfer: Allow @domid to transfer ownership of one page frame
144  * to this guest. Xen writes the page number to @frame.
145  * GTF_transitive: Allow @domid to transitively access a subrange of
146  * @trans_grant in @trans_domid. No mappings are allowed.
147  */
148 #define GTF_invalid (0U<<0)
149 #define GTF_permit_access (1U<<0)
150 #define GTF_accept_transfer (2U<<0)
151 #define GTF_transitive (3U<<0)
152 #define GTF_type_mask (3U<<0)
153 
154 /*
155  * Subflags for GTF_permit_access and GTF_transitive.
156  * GTF_readonly: Restrict @domid to read-only mappings and accesses. [GST]
157  * GTF_reading: Grant entry is currently mapped for reading by @domid. [XEN]
158  * GTF_writing: Grant entry is currently mapped for writing by @domid. [XEN]
159  * Further subflags for GTF_permit_access only.
160  * GTF_PAT, GTF_PWT, GTF_PCD: (x86) cache attribute flags to be used for
161  * mappings of the grant [GST]
162  * GTF_sub_page: Grant access to only a subrange of the page. @domid
163  * will only be allowed to copy from the grant, and not
164  * map it. [GST]
165  */
166 #define _GTF_readonly (2)
167 #define GTF_readonly (1U<<_GTF_readonly)
168 #define _GTF_reading (3)
169 #define GTF_reading (1U<<_GTF_reading)
170 #define _GTF_writing (4)
171 #define GTF_writing (1U<<_GTF_writing)
172 #define _GTF_PWT (5)
173 #define GTF_PWT (1U<<_GTF_PWT)
174 #define _GTF_PCD (6)
175 #define GTF_PCD (1U<<_GTF_PCD)
176 #define _GTF_PAT (7)
177 #define GTF_PAT (1U<<_GTF_PAT)
178 #define _GTF_sub_page (8)
179 #define GTF_sub_page (1U<<_GTF_sub_page)
180 
181 /*
182  * Subflags for GTF_accept_transfer:
183  * GTF_transfer_committed: Xen sets this flag to indicate that it is committed
184  * to transferring ownership of a page frame. When a guest sees this flag
185  * it must /not/ modify the grant entry until GTF_transfer_completed is
186  * set by Xen.
187  * GTF_transfer_completed: It is safe for the guest to spin-wait on this flag
188  * after reading GTF_transfer_committed. Xen will always write the frame
189  * address, followed by ORing this flag, in a timely manner.
190  */
191 #define _GTF_transfer_committed (2)
192 #define GTF_transfer_committed (1U<<_GTF_transfer_committed)
193 #define _GTF_transfer_completed (3)
194 #define GTF_transfer_completed (1U<<_GTF_transfer_completed)
195 
196 /*
197  * Version 2 grant table entries. These fulfil the same role as
198  * version 1 entries, but can represent more complicated operations.
199  * Any given domain will have either a version 1 or a version 2 table,
200  * and every entry in the table will be the same version.
201  *
202  * The interface by which domains use grant references does not depend
203  * on the grant table version in use by the other domain.
204  */
205 #if __XEN_INTERFACE_VERSION__ >= 0x0003020a
206 /*
207  * Version 1 and version 2 grant entries share a common prefix. The
208  * fields of the prefix are documented as part of struct
209  * grant_entry_v1.
210  */
211 struct grant_entry_header {
212  uint16_t flags;
213  domid_t domid;
214 };
215 typedef struct grant_entry_header grant_entry_header_t;
216 
217 /*
218  * Version 2 of the grant entry structure.
219  */
220 union grant_entry_v2 {
221  grant_entry_header_t hdr;
222 
223  /*
224  * This member is used for V1-style full page grants, where either:
225  *
226  * -- hdr.type is GTF_accept_transfer, or
227  * -- hdr.type is GTF_permit_access and GTF_sub_page is not set.
228  *
229  * In that case, the frame field has the same semantics as the
230  * field of the same name in the V1 entry structure.
231  */
232  struct {
233  grant_entry_header_t hdr;
234  uint32_t pad0;
235  uint64_t frame;
236  } full_page;
237 
238  /*
239  * If the grant type is GTF_grant_access and GTF_sub_page is set,
240  * @domid is allowed to access bytes [@page_off,@page_off+@length)
241  * in frame @frame.
242  */
243  struct {
244  grant_entry_header_t hdr;
245  uint16_t page_off;
247  uint64_t frame;
248  } sub_page;
249 
250  /*
251  * If the grant is GTF_transitive, @domid is allowed to use the
252  * grant @gref in domain @trans_domid, as if it was the local
253  * domain. Obviously, the transitive access must be compatible
254  * with the original grant.
255  *
256  * The current version of Xen does not allow transitive grants
257  * to be mapped.
258  */
259  struct {
260  grant_entry_header_t hdr;
261  domid_t trans_domid;
262  uint16_t pad0;
263  grant_ref_t gref;
264  } transitive;
265 
266  uint32_t __spacer[4]; /* Pad to a power of two */
267 };
268 typedef union grant_entry_v2 grant_entry_v2_t;
269 
270 typedef uint16_t grant_status_t;
271 
272 #endif /* __XEN_INTERFACE_VERSION__ */
273 
274 /***********************************
275  * GRANT TABLE QUERIES AND USES
276  */
277 
278 /* ` enum neg_errnoval
279  * ` HYPERVISOR_grant_table_op(enum grant_table_op cmd,
280  * ` void *args,
281  * ` unsigned int count)
282  * `
283  *
284  * @args points to an array of a per-command data structure. The array
285  * has @count members
286  */
287 
288 /* ` enum grant_table_op { // GNTTABOP_* => struct gnttab_* */
289 #define GNTTABOP_map_grant_ref 0
290 #define GNTTABOP_unmap_grant_ref 1
291 #define GNTTABOP_setup_table 2
292 #define GNTTABOP_dump_table 3
293 #define GNTTABOP_transfer 4
294 #define GNTTABOP_copy 5
295 #define GNTTABOP_query_size 6
296 #define GNTTABOP_unmap_and_replace 7
297 #if __XEN_INTERFACE_VERSION__ >= 0x0003020a
298 #define GNTTABOP_set_version 8
299 #define GNTTABOP_get_status_frames 9
300 #define GNTTABOP_get_version 10
301 #define GNTTABOP_swap_grant_ref 11
302 #define GNTTABOP_cache_flush 12
303 #endif /* __XEN_INTERFACE_VERSION__ */
304 /* ` } */
305 
306 /*
307  * Handle to track a mapping created via a grant reference.
308  */
310 
311 /*
312  * GNTTABOP_map_grant_ref: Map the grant entry (<dom>,<ref>) for access
313  * by devices and/or host CPUs. If successful, <handle> is a tracking number
314  * that must be presented later to destroy the mapping(s). On error, <status>
315  * is a negative status code.
316  * NOTES:
317  * 1. If GNTMAP_device_map is specified then <dev_bus_addr> is the address
318  * via which I/O devices may access the granted frame.
319  * 2. If GNTMAP_host_map is specified then a mapping will be added at
320  * either a host virtual address in the current address space, or at
321  * a PTE at the specified machine address. The type of mapping to
322  * perform is selected through the GNTMAP_contains_pte flag, and the
323  * address is specified in <host_addr>.
324  * 3. Mappings should only be destroyed via GNTTABOP_unmap_grant_ref. If a
325  * host mapping is destroyed by other means then it is *NOT* guaranteed
326  * to be accounted to the correct grant reference!
327  */
329  /* IN parameters. */
331  uint32_t flags; /* GNTMAP_* */
334  /* OUT parameters. */
335  int16_t status; /* => enum grant_status */
338 };
341 
342 /*
343  * GNTTABOP_unmap_grant_ref: Destroy one or more grant-reference mappings
344  * tracked by <handle>. If <host_addr> or <dev_bus_addr> is zero, that
345  * field is ignored. If non-zero, they must refer to a device/host mapping
346  * that is tracked by <handle>
347  * NOTES:
348  * 1. The call may fail in an undefined manner if either mapping is not
349  * tracked by <handle>.
350  * 3. After executing a batch of unmaps, it is guaranteed that no stale
351  * mappings will remain in the device or host TLBs.
352  */
354  /* IN parameters. */
358  /* OUT parameters. */
359  int16_t status; /* => enum grant_status */
360 };
363 
364 /*
365  * GNTTABOP_setup_table: Set up a grant table for <dom> comprising at least
366  * <nr_frames> pages. The frame addresses are written to the <frame_list>.
367  * Only <nr_frames> addresses are written, even if the table is larger.
368  * NOTES:
369  * 1. <dom> may be specified as DOMID_SELF.
370  * 2. Only a sufficiently-privileged domain may specify <dom> != DOMID_SELF.
371  * 3. Xen may not support more than a single grant-table page per domain.
372  */
374  /* IN parameters. */
377  /* OUT parameters. */
378  int16_t status; /* => enum grant_status */
379 #if __XEN_INTERFACE_VERSION__ < 0x00040300
380  XEN_GUEST_HANDLE(ulong) frame_list;
381 #else
382  XEN_GUEST_HANDLE(xen_pfn_t) frame_list;
383 #endif
384 };
387 
388 /*
389  * GNTTABOP_dump_table: Dump the contents of the grant table to the
390  * xen console. Debugging use only.
391  */
393  /* IN parameters. */
395  /* OUT parameters. */
396  int16_t status; /* => enum grant_status */
397 };
400 
401 /*
402  * GNTTABOP_transfer: Transfer <frame> to a foreign domain. The foreign domain
403  * has previously registered its interest in the transfer via <domid, ref>.
404  *
405  * Note that, even if the transfer fails, the specified page no longer belongs
406  * to the calling domain *unless* the error is GNTST_bad_page.
407  *
408  * Note further that only PV guests can use this operation.
409  */
411  /* IN parameters. */
415  /* OUT parameters. */
417 };
420 
421 
422 /*
423  * GNTTABOP_copy: Hypervisor based copy
424  * source and destinations can be eithers MFNs or, for foreign domains,
425  * grant references. the foreign domain has to grant read/write access
426  * in its grant table.
427  *
428  * The flags specify what type source and destinations are (either MFN
429  * or grant reference).
430  *
431  * Note that this can also be used to copy data between two domains
432  * via a third party if the source and destination domains had previously
433  * grant appropriate access to their pages to the third party.
434  *
435  * source_offset specifies an offset in the source frame, dest_offset
436  * the offset in the target frame and len specifies the number of
437  * bytes to be copied.
438  */
439 
440 #define _GNTCOPY_source_gref (0)
441 #define GNTCOPY_source_gref (1<<_GNTCOPY_source_gref)
442 #define _GNTCOPY_dest_gref (1)
443 #define GNTCOPY_dest_gref (1<<_GNTCOPY_dest_gref)
444 
445 struct gnttab_copy {
446  /* IN parameters. */
448  union {
451  } u;
454  } source, dest;
456  uint16_t flags; /* GNTCOPY_* */
457  /* OUT parameters. */
459 };
460 typedef struct gnttab_copy gnttab_copy_t;
462 
463 /*
464  * GNTTABOP_query_size: Query the current and maximum sizes of the shared
465  * grant table.
466  * NOTES:
467  * 1. <dom> may be specified as DOMID_SELF.
468  * 2. Only a sufficiently-privileged domain may specify <dom> != DOMID_SELF.
469  */
471  /* IN parameters. */
473  /* OUT parameters. */
476  int16_t status; /* => enum grant_status */
477 };
480 
481 /*
482  * GNTTABOP_unmap_and_replace: Destroy one or more grant-reference mappings
483  * tracked by <handle> but atomically replace the page table entry with one
484  * pointing to the machine address under <new_addr>. <new_addr> will be
485  * redirected to the null entry.
486  * NOTES:
487  * 1. The call may fail in an undefined manner if either mapping is not
488  * tracked by <handle>.
489  * 2. After executing a batch of unmaps, it is guaranteed that no stale
490  * mappings will remain in the device or host TLBs.
491  */
493  /* IN parameters. */
497  /* OUT parameters. */
498  int16_t status; /* => enum grant_status */
499 };
502 
503 #if __XEN_INTERFACE_VERSION__ >= 0x0003020a
504 /*
505  * GNTTABOP_set_version: Request a particular version of the grant
506  * table shared table structure. This operation may be used to toggle
507  * between different versions, but must be performed while no grants
508  * are active. The only defined versions are 1 and 2.
509  */
510 struct gnttab_set_version {
511  /* IN/OUT parameters */
513 };
514 typedef struct gnttab_set_version gnttab_set_version_t;
515 DEFINE_XEN_GUEST_HANDLE(gnttab_set_version_t);
516 
517 
518 /*
519  * GNTTABOP_get_status_frames: Get the list of frames used to store grant
520  * status for <dom>. In grant format version 2, the status is separated
521  * from the other shared grant fields to allow more efficient synchronization
522  * using barriers instead of atomic cmpexch operations.
523  * <nr_frames> specify the size of vector <frame_list>.
524  * The frame addresses are returned in the <frame_list>.
525  * Only <nr_frames> addresses are returned, even if the table is larger.
526  * NOTES:
527  * 1. <dom> may be specified as DOMID_SELF.
528  * 2. Only a sufficiently-privileged domain may specify <dom> != DOMID_SELF.
529  */
530 struct gnttab_get_status_frames {
531  /* IN parameters. */
532  uint32_t nr_frames;
533  domid_t dom;
534  /* OUT parameters. */
535  int16_t status; /* => enum grant_status */
536  XEN_GUEST_HANDLE(uint64_t) frame_list;
537 };
538 typedef struct gnttab_get_status_frames gnttab_get_status_frames_t;
539 DEFINE_XEN_GUEST_HANDLE(gnttab_get_status_frames_t);
540 
541 /*
542  * GNTTABOP_get_version: Get the grant table version which is in
543  * effect for domain <dom>.
544  */
545 struct gnttab_get_version {
546  /* IN parameters */
547  domid_t dom;
548  uint16_t pad;
549  /* OUT parameters */
551 };
552 typedef struct gnttab_get_version gnttab_get_version_t;
553 DEFINE_XEN_GUEST_HANDLE(gnttab_get_version_t);
554 
555 /*
556  * GNTTABOP_swap_grant_ref: Swap the contents of two grant entries.
557  */
558 struct gnttab_swap_grant_ref {
559  /* IN parameters */
560  grant_ref_t ref_a;
561  grant_ref_t ref_b;
562  /* OUT parameters */
563  int16_t status; /* => enum grant_status */
564 };
565 typedef struct gnttab_swap_grant_ref gnttab_swap_grant_ref_t;
566 DEFINE_XEN_GUEST_HANDLE(gnttab_swap_grant_ref_t);
567 
568 /*
569  * Issue one or more cache maintenance operations on a portion of a
570  * page granted to the calling domain by a foreign domain.
571  */
572 struct gnttab_cache_flush {
573  union {
574  uint64_t dev_bus_addr;
576  } a;
577  uint16_t offset; /* offset from start of grant */
578  uint16_t length; /* size within the grant */
579 #define GNTTAB_CACHE_CLEAN (1u<<0)
580 #define GNTTAB_CACHE_INVAL (1u<<1)
581 #define GNTTAB_CACHE_SOURCE_GREF (1u<<31)
582  uint32_t op;
583 };
584 typedef struct gnttab_cache_flush gnttab_cache_flush_t;
585 DEFINE_XEN_GUEST_HANDLE(gnttab_cache_flush_t);
586 
587 #endif /* __XEN_INTERFACE_VERSION__ */
588 
589 /*
590  * Bitfield values for gnttab_map_grant_ref.flags.
591  */
592  /* Map the grant entry for access by I/O devices. */
593 #define _GNTMAP_device_map (0)
594 #define GNTMAP_device_map (1<<_GNTMAP_device_map)
595  /* Map the grant entry for access by host CPUs. */
596 #define _GNTMAP_host_map (1)
597 #define GNTMAP_host_map (1<<_GNTMAP_host_map)
598  /* Accesses to the granted frame will be restricted to read-only access. */
599 #define _GNTMAP_readonly (2)
600 #define GNTMAP_readonly (1<<_GNTMAP_readonly)
601  /*
602  * GNTMAP_host_map subflag:
603  * 0 => The host mapping is usable only by the guest OS.
604  * 1 => The host mapping is usable by guest OS + current application.
605  */
606 #define _GNTMAP_application_map (3)
607 #define GNTMAP_application_map (1<<_GNTMAP_application_map)
608 
609  /*
610  * GNTMAP_contains_pte subflag:
611  * 0 => This map request contains a host virtual address.
612  * 1 => This map request contains the machine addess of the PTE to update.
613  */
614 #define _GNTMAP_contains_pte (4)
615 #define GNTMAP_contains_pte (1<<_GNTMAP_contains_pte)
616 
617 /*
618  * Bits to be placed in guest kernel available PTE bits (architecture
619  * dependent; only supported when XENFEAT_gnttab_map_avail_bits is set).
620  */
621 #define _GNTMAP_guest_avail0 (16)
622 #define GNTMAP_guest_avail_mask ((uint32_t)~0 << _GNTMAP_guest_avail0)
623 
624 /*
625  * Values for error status returns. All errors are -ve.
626  */
627 /* ` enum grant_status { */
628 #define GNTST_okay (0) /* Normal return. */
629 #define GNTST_general_error (-1) /* General undefined error. */
630 #define GNTST_bad_domain (-2) /* Unrecognsed domain id. */
631 #define GNTST_bad_gntref (-3) /* Unrecognised or inappropriate gntref. */
632 #define GNTST_bad_handle (-4) /* Unrecognised or inappropriate handle. */
633 #define GNTST_bad_virt_addr (-5) /* Inappropriate virtual address to map. */
634 #define GNTST_bad_dev_addr (-6) /* Inappropriate device address to unmap.*/
635 #define GNTST_no_device_space (-7) /* Out of space in I/O MMU. */
636 #define GNTST_permission_denied (-8) /* Not enough privilege for operation. */
637 #define GNTST_bad_page (-9) /* Specified page was invalid for op. */
638 #define GNTST_bad_copy_arg (-10) /* copy arguments cross page boundary. */
639 #define GNTST_address_too_big (-11) /* transfer page address too large. */
640 #define GNTST_eagain (-12) /* Operation not done; try again. */
641 #define GNTST_no_space (-13) /* Out of space (handles etc). */
642 /* ` } */
643 
644 #define GNTTABOP_error_msgs { \
645  "okay", \
646  "undefined error", \
647  "unrecognised domain id", \
648  "invalid grant reference", \
649  "invalid mapping handle", \
650  "invalid virtual address", \
651  "invalid device address", \
652  "no spare translation slot in the I/O MMU", \
653  "permission denied", \
654  "bad page", \
655  "copy arguments cross page boundary", \
656  "page address size too large", \
657  "operation not done; try again", \
658  "out of space", \
659 }
660 
661 #endif /* __XEN_PUBLIC_GRANT_TABLE_H__ */
662 
663 /*
664  * Local variables:
665  * mode: C
666  * c-file-style: "BSD"
667  * c-basic-offset: 4
668  * tab-width: 4
669  * indent-tabs-mode: nil
670  * End:
671  */
grant_handle_t handle
Definition: grant_table.h:496
u16 length
Definition: sky2.h:9
unsigned short uint16_t
Definition: stdint.h:11
FILE_LICENCE(MIT)
uint16_t domid_t
Definition: xen.h:608
DEFINE_XEN_GUEST_HANDLE(gnttab_map_grant_ref_t)
struct golan_inbox_hdr hdr
Message header.
Definition: CIB_PRM.h:28
unsigned long long uint64_t
Definition: stdint.h:13
uint16_t flags
Definition: grant_table.h:456
u32 pad[9]
Padding.
Definition: ar9003_mac.h:90
int16_t status
Definition: grant_table.h:458
XEN_GUEST_HANDLE(ulong) frame_list
uint32_t grant_ref_t
Definition: grant_table.h:99
uint32_t a
Definition: md4.c:28
uint16_t len
Definition: grant_table.h:455
uint8_t status
Status.
Definition: ena.h:16
unsigned long frame
Definition: xengrant.h:179
grant_handle_t handle
Definition: grant_table.h:336
struct gnttab_copy::gnttab_copy_ptr dest
domid_t domid
Definition: grant_table.h:121
static userptr_t size_t offset
Offset of the first segment within the content.
Definition: deflate.h:259
uint32_t max_nr_frames
Definition: grant_table.h:475
static grant_ref_t domid_t domid
Definition: xengrant.h:173
unsigned long xen_pfn_t
Definition: nonxen.h:25
Definition: grant_table.h:117
unsigned int uint32_t
Definition: stdint.h:12
uint32_t grant_handle_t
Definition: grant_table.h:309
u32 version
Driver version.
Definition: ath9k_hw.c:1983
static uint16_t struct vmbus_xfer_pages_operations * op
Definition: netvsc.h:327
uint32_t frame
Definition: grant_table.h:128
uint32_t nr_frames
Definition: grant_table.h:474
uint16_t flags
Definition: grant_table.h:119
struct gnttab_copy::gnttab_copy_ptr source
grant_handle_t handle
Definition: grant_table.h:357
signed short int16_t
Definition: stdint.h:16
static const char grant_ref_t ref
Definition: netfront.h:91
union gnttab_copy::gnttab_copy_ptr::@607 u
grant_ref_t ref
Definition: grant_table.h:414
xen_pfn_t mfn
Definition: grant_table.h:412
#define XEN_GUEST_HANDLE(name)
Definition: nonxen.h:14
uint8_t flags
Flags.
Definition: ena.h:18