From 285da2b9a83353703d07e141fdb447e82944146c Mon Sep 17 00:00:00 2001 From: Peter Maydell Date: Thu, 6 Jan 2011 15:04:18 +0000 Subject: linux-user: Implement FS_IOC_FIEMAP ioctl Implement the FS_IOC_FIEMAP ioctl using the new support for custom handling of ioctls; this is needed because the struct that is passed includes a variable-length array. Signed-off-by: Peter Maydell Signed-off-by: Riku Voipio --- linux-user/syscall_types.h | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'linux-user/syscall_types.h') diff --git a/linux-user/syscall_types.h b/linux-user/syscall_types.h index 340dbd367f..0e67cd8f30 100644 --- a/linux-user/syscall_types.h +++ b/linux-user/syscall_types.h @@ -165,3 +165,19 @@ STRUCT(vt_stat, TYPE_SHORT, /* v_active */ TYPE_SHORT, /* v_signal */ TYPE_SHORT) /* v_state */ + +STRUCT(fiemap_extent, + TYPE_ULONGLONG, /* fe_logical */ + TYPE_ULONGLONG, /* fe_physical */ + TYPE_ULONGLONG, /* fe_length */ + MK_ARRAY(TYPE_ULONGLONG, 2), /* fe_reserved64[2] */ + TYPE_INT, /* fe_flags */ + MK_ARRAY(TYPE_INT, 3)) /* fe_reserved[3] */ + +STRUCT(fiemap, + TYPE_ULONGLONG, /* fm_start */ + TYPE_ULONGLONG, /* fm_length */ + TYPE_INT, /* fm_flags */ + TYPE_INT, /* fm_mapped_extents */ + TYPE_INT, /* fm_extent_count */ + TYPE_INT) /* fm_reserved */ -- cgit 1.4.1