firewire updates for 6.7

The pull request includes a slight change for flexible length of array
 in core function.
 
 Kees Cook provides a patch to annotate the array embedded in fw_node
 structure referring to structure member for the length of array. The
 annotation would be defined by future extension of C compilers, and
 used for access bound-check at run-time enabled by UBSAN and
 FORTIFY_SOURCE.
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYIAB0WIQQE66IEYNDXNBPeGKSsLtaWM8LwEwUCZUebWgAKCRCsLtaWM8Lw
 E9ONAQDJgJrJ8NkA2L/RMq+og3hdz+PFSNgCjLMudpJOzqBr8gD+Mds+Kjkt3PyL
 gNeixdoc2H2xaGw+Lij/czASbWiywQ4=
 =+/gn
 -----END PGP SIGNATURE-----

Merge tag 'firewire-updates-6.7' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394

Pull firewire update from Takashi Sakamoto:
 "A slight change for flexible length of array in core function.

  Kees Cook provides a patch to annotate the array embedded in fw_node
  structure referring to structure member for the length of array. The
  annotation would be defined by future extension of C compilers, and
  used for access bound-check at run-time enabled by UBSAN and
  FORTIFY_SOURCE"

* tag 'firewire-updates-6.7' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394:
  firewire: Annotate struct fw_node with __counted_by
This commit is contained in:
Linus Torvalds 2023-11-05 08:50:41 -10:00
commit 1cfb751165

View File

@ -191,7 +191,7 @@ struct fw_node {
/* Upper layer specific data. */
void *data;
struct fw_node *ports[];
struct fw_node *ports[] __counted_by(port_count);
};
static inline struct fw_node *fw_node_get(struct fw_node *node)