Signed-off-by: Alan Huang <[email protected]>
---
 fs/bcachefs/xattr_format.h | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/fs/bcachefs/xattr_format.h b/fs/bcachefs/xattr_format.h
index e9f810539552..8fe0bb897038 100644
--- a/fs/bcachefs/xattr_format.h
+++ b/fs/bcachefs/xattr_format.h
@@ -13,6 +13,12 @@ struct bch_xattr {
        __u8                    x_type;
        __u8                    x_name_len;
        __le16                  x_val_len;
+       /*
+        * Do not reintroduce __counted_by(x_name_len) here.
+        * There is a value following x_name. __counted_by requires
+        * that the flexible array member contains exactly the
+        * amount of elements that are specified.
+        */
        __u8                    x_name[];
 } __packed __aligned(8);
 
-- 
2.48.1


Reply via email to