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

[PATCH] xen/include/public: add macro for invalid grant reference



Providing a macro for an invalid grant reference would be beneficial
for users, especially as some are using the wrong value "0" for that
purpose.

Signed-off-by: Juergen Gross <jgross@xxxxxxxx>
---
 xen/include/public/grant_table.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/xen/include/public/grant_table.h b/xen/include/public/grant_table.h
index 7fbd1c6d10..af00aacfd3 100644
--- a/xen/include/public/grant_table.h
+++ b/xen/include/public/grant_table.h
@@ -113,6 +113,8 @@
  */
 typedef uint32_t grant_ref_t;
 
+#define XEN_GRANT_REF_INVALID  ~0U
+
 /*
  * A grant table comprises a packed array of grant entries in one or more
  * page frames shared between Xen and a guest.
-- 
2.34.1




 


Rackspace

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