Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 62731fa0 authored by Alexey Zaytsev's avatar Alexey Zaytsev Committed by Eric Paris
Browse files

fanotify: split version into version and metadata_len



To implement per event type optional headers we are interested in
knowing how long the metadata structure is.  This patch slits the __u32
version field into a __u8 version and a __u16 metadata_len field (with
__u8 left over).  This should allow for backwards compat ABI.

Signed-off-by: default avatarAlexey Zaytsev <alexey.zaytsev@gmail.com>
[rewrote descrtion and changed object sizes and ordering - eparis]
Signed-off-by: default avatarEric Paris <eparis@redhat.com>
parent fdbf3cee
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -83,11 +83,13 @@
				 FAN_ALL_PERM_EVENTS |\
				 FAN_Q_OVERFLOW)

#define FANOTIFY_METADATA_VERSION	2
#define FANOTIFY_METADATA_VERSION	3

struct fanotify_event_metadata {
	__u32 event_len;
	__u32 vers;
	__u8 vers;
	__u8 reserved;
	__u16 metadata_len;
	__aligned_u64 mask;
	__s32 fd;
	__s32 pid;