--- a/fs/thing.c
+++ b/fs/thing.c
@@ -30,6 +30,18 @@
 }
 #endif
 
+static int validate_acl(struct smb_acl *pacl, char *end)
+{
+	int i, hdr_size;
+	u16 num_aces;
+
+	if (!pacl)
+		return 0;
+
+	num_aces = le16_to_cpu(pacl->num_aces);
+	return num_aces;
+}
+
 static void parse_acl(struct smb_acl *pacl, char *end,
 		      struct smb_sid *powner,
 		      struct cifs_fattr *fattr)
