Skip to content

Commit

Permalink
Merge tag 'flex-array-transformations-6.3-rc1' of git://git.kernel.or…
Browse files Browse the repository at this point in the history
…g/pub/scm/linux/kernel/git/gustavoars/linux

Pull flexible-array updates from Gustavo Silva:
 "Transform zero-length arrays, in unions, into flexible arrays"

* tag 'flex-array-transformations-6.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gustavoars/linux:
  bcache: Replace zero-length arrays with DECLARE_FLEX_ARRAY() helper
  mm/memremap: Replace zero-length array with DECLARE_FLEX_ARRAY() helper
  exportfs: Replace zero-length array with DECLARE_FLEX_ARRAY() helper
  • Loading branch information
torvalds committed Feb 25, 2023
2 parents e534a58 + b942a52 commit 472a2ab
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
8 changes: 4 additions & 4 deletions drivers/md/bcache/bcache_ondisk.h
Original file line number Diff line number Diff line change
Expand Up @@ -360,8 +360,8 @@ struct jset {
__u64 prio_bucket[MAX_CACHES_PER_SET];

union {
struct bkey start[0];
__u64 d[0];
DECLARE_FLEX_ARRAY(struct bkey, start);
DECLARE_FLEX_ARRAY(__u64, d);
};
};

Expand Down Expand Up @@ -425,8 +425,8 @@ struct bset {
__u32 keys;

union {
struct bkey start[0];
__u64 d[0];
DECLARE_FLEX_ARRAY(struct bkey, start);
DECLARE_FLEX_ARRAY(__u64, d);
};
};

Expand Down
2 changes: 1 addition & 1 deletion include/linux/exportfs.h
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ struct fid {
u32 parent_block;
u32 parent_generation;
} udf;
__u32 raw[0];
DECLARE_FLEX_ARRAY(__u32, raw);
};
};

Expand Down
2 changes: 1 addition & 1 deletion include/linux/memremap.h
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ struct dev_pagemap {
int nr_range;
union {
struct range range;
struct range ranges[0];
DECLARE_FLEX_ARRAY(struct range, ranges);
};
};

Expand Down

0 comments on commit 472a2ab

Please sign in to comment.