aboutsummaryrefslogtreecommitdiffstats
path: root/tools/libxc/xc_private.h
diff options
context:
space:
mode:
authorKeir Fraser <keir@xensource.com>2007-11-11 18:22:33 +0000
committerKeir Fraser <keir@xensource.com>2007-11-11 18:22:33 +0000
commitc316590403819d9206b81ca5dd42136c86ee271c (patch)
treed9728245710b174c84dcbd28d9aba5cdb1d747c2 /tools/libxc/xc_private.h
parentbbceef66ead2fb6800a767a7625c598f196ce852 (diff)
downloadxen-c316590403819d9206b81ca5dd42136c86ee271c.tar.gz
xen-c316590403819d9206b81ca5dd42136c86ee271c.tar.bz2
xen-c316590403819d9206b81ca5dd42136c86ee271c.zip
libxc: Consolidate read()/write() syscall wrappers to read/write an
exact number of bytes. The consolidated versions are more watertight than the various versions previously distributed around the library source code. Signed-off-by: Keir Fraser <keir@xensource.com>
Diffstat (limited to 'tools/libxc/xc_private.h')
-rw-r--r--tools/libxc/xc_private.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/tools/libxc/xc_private.h b/tools/libxc/xc_private.h
index 09e1bdf4ad..b068e45dbe 100644
--- a/tools/libxc/xc_private.h
+++ b/tools/libxc/xc_private.h
@@ -180,4 +180,8 @@ int xc_add_mmu_update(int xc_handle, struct xc_mmu *mmu,
unsigned long long ptr, unsigned long long val);
int xc_flush_mmu_updates(int xc_handle, struct xc_mmu *mmu);
+/* Return 0 on success; -1 on error. */
+int read_exact(int fd, void *data, size_t size);
+int write_exact(int fd, const void *data, size_t size);
+
#endif /* __XC_PRIVATE_H__ */