Re: [PATCH] i3c: svc: Annotate struct svc_i3c_xfer with __counted_by

2023-09-22 Thread Miquel Raynal
Hi, keesc...@chromium.org wrote on Fri, 22 Sep 2023 10:50:23 -0700: > Prepare for the coming implementation by GCC and Clang of the __counted_by > attribute. Flexible array members annotated with __counted_by can have > their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS >

[PATCH] platform/surface: aggregator: Annotate struct ssam_event with __counted_by

2023-09-22 Thread Kees Cook
Prepare for the coming implementation by GCC and Clang of the __counted_by attribute. Flexible array members annotated with __counted_by can have their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS (for array indexing) and CONFIG_FORTIFY_SOURCE (for strcpy/memcpy-family funct

Re: [PATCH] libnvdimm: Annotate struct nd_region with __counted_by

2023-09-22 Thread Dave Jiang
On 9/22/23 10:52, Kees Cook wrote: > Prepare for the coming implementation by GCC and Clang of the __counted_by > attribute. Flexible array members annotated with __counted_by can have > their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS > (for array indexing) and CONFIG_

Re: [PATCH] cxl/acpi: Annotate struct cxl_cxims_data with __counted_by

2023-09-22 Thread Dave Jiang
On 9/22/23 10:53, Kees Cook wrote: > Prepare for the coming implementation by GCC and Clang of the __counted_by > attribute. Flexible array members annotated with __counted_by can have > their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS > (for array indexing) and CONFIG_

Re: [PATCH 14/14] net: sched: Annotate struct tc_pedit with __counted_by

2023-09-22 Thread Kees Cook
On Fri, Sep 22, 2023 at 10:28:56AM -0700, Kees Cook wrote: > Prepare for the coming implementation by GCC and Clang of the __counted_by > attribute. Flexible array members annotated with __counted_by can have > their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS > (for array

Re: [PATCH 14/14] net: sched: Annotate struct tc_pedit with __counted_by

2023-09-22 Thread Kees Cook
On Fri, Sep 22, 2023 at 10:28:56AM -0700, Kees Cook wrote: > Prepare for the coming implementation by GCC and Clang of the __counted_by > attribute. Flexible array members annotated with __counted_by can have > their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS > (for array

Re: [PATCH] cxl/acpi: Annotate struct cxl_cxims_data with __counted_by

2023-09-22 Thread Verma, Vishal L
On Fri, 2023-09-22 at 10:53 -0700, Kees Cook wrote: > Prepare for the coming implementation by GCC and Clang of the __counted_by > attribute. Flexible array members annotated with __counted_by can have > their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS > (for array indexin

Re: [PATCH] mm/memcg: Annotate struct mem_cgroup_threshold_ary with __counted_by

2023-09-22 Thread Shakeel Butt
On Fri, Sep 22, 2023 at 10:53 AM Kees Cook wrote: > > Prepare for the coming implementation by GCC and Clang of the __counted_by > attribute. Flexible array members annotated with __counted_by can have > their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS > (for array indexi

Re: [PATCH] md/md-linear: Annotate struct linear_conf with __counted_by

2023-09-22 Thread Song Liu
On Fri, Sep 15, 2023 at 1:27 PM Gustavo A. R. Silva wrote: > > > > On 9/15/23 14:03, Kees Cook wrote: > > Prepare for the coming implementation by GCC and Clang of the __counted_by > > attribute. Flexible array members annotated with __counted_by can have > > their accesses bounds-checked at run-t

Re: [PATCH] mm/memcg: Annotate struct mem_cgroup_threshold_ary with __counted_by

2023-09-22 Thread Kees Cook
On Fri, Sep 22, 2023 at 11:25:56AM -0700, Shakeel Butt wrote: > On Fri, Sep 22, 2023 at 10:53 AM Kees Cook wrote: > > > > Prepare for the coming implementation by GCC and Clang of the __counted_by > > attribute. Flexible array members annotated with __counted_by can have > > their accesses bounds-

Re: [PATCH] PCI: hv: Annotate struct hv_dr_state with __counted_by

2023-09-22 Thread Wei Liu
On Fri, Sep 22, 2023 at 10:52:57AM -0700, Kees Cook wrote: > Prepare for the coming implementation by GCC and Clang of the __counted_by > attribute. Flexible array members annotated with __counted_by can have > their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS > (for array

Re: [PATCH] i3c: dw: Annotate struct dw_i3c_xfer with __counted_by

2023-09-22 Thread Jeremy Kerr
Hi Kees, > Prepare for the coming implementation by GCC and Clang of the > __counted_by attribute. Flexible array members annotated with > __counted_by can have their accesses bounds-checked at run-time > checking via CONFIG_UBSAN_BOUNDS (for array indexing) and > CONFIG_FORTIFY_SOURCE (for strcpy

Re: [PATCH] mm/memcg: Annotate struct mem_cgroup_threshold_ary with __counted_by

2023-09-22 Thread Shakeel Butt
On Fri, Sep 22, 2023 at 10:53 AM Kees Cook wrote: > > Prepare for the coming implementation by GCC and Clang of the __counted_by > attribute. Flexible array members annotated with __counted_by can have > their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS > (for array indexi

Re: [PATCH] spi: mchp-pci1xxxx: Annotate struct pci1xxxx_spi with __counted_by

2023-09-22 Thread Mark Brown
On Fri, 22 Sep 2023 10:53:23 -0700, Kees Cook wrote: > Prepare for the coming implementation by GCC and Clang of the __counted_by > attribute. Flexible array members annotated with __counted_by can have > their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS > (for array indexi

Re: [PATCH] module: Annotate struct module_notes_attrs with __counted_by

2023-09-22 Thread Luis Chamberlain
On Fri, Sep 22, 2023 at 10:52:53AM -0700, Kees Cook wrote: > Prepare for the coming implementation by GCC and Clang of the __counted_by > attribute. Flexible array members annotated with __counted_by can have > their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS > (for array

Re: [PATCH] libnvdimm: Annotate struct nd_region with __counted_by

2023-09-22 Thread Verma, Vishal L
On Fri, 2023-09-22 at 10:52 -0700, Kees Cook wrote: > Prepare for the coming implementation by GCC and Clang of the > __counted_by > attribute. Flexible array members annotated with __counted_by can > have > their accesses bounds-checked at run-time checking via > CONFIG_UBSAN_BOUNDS > (for array i

Re: [PATCH] regulator: mc13xxx: Annotate struct mc13xxx_regulator_priv with __counted_by

2023-09-22 Thread Mark Brown
On Fri, 22 Sep 2023 10:54:02 -0700, Kees Cook wrote: > Prepare for the coming implementation by GCC and Clang of the __counted_by > attribute. Flexible array members annotated with __counted_by can have > their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS > (for array indexi

Re: [PATCH] mm/memcg: Annotate struct mem_cgroup_threshold_ary with __counted_by

2023-09-22 Thread Roman Gushchin
On Fri, Sep 22, 2023 at 10:53:28AM -0700, Kees Cook wrote: > Prepare for the coming implementation by GCC and Clang of the __counted_by > attribute. Flexible array members annotated with __counted_by can have > their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS > (for array

Re: [PATCH] power: supply: axp20x_ac_power: Annotate struct axp20x_ac_power with __counted_by

2023-09-22 Thread Sebastian Reichel
On Fri, 22 Sep 2023 10:53:55 -0700, Kees Cook wrote: > Prepare for the coming implementation by GCC and Clang of the __counted_by > attribute. Flexible array members annotated with __counted_by can have > their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS > (for array inde

Re: [PATCH] power: supply: axp20x_usb_power: Annotate struct axp20x_usb_power with __counted_by

2023-09-22 Thread Sebastian Reichel
On Fri, 22 Sep 2023 10:53:58 -0700, Kees Cook wrote: > Prepare for the coming implementation by GCC and Clang of the __counted_by > attribute. Flexible array members annotated with __counted_by can have > their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS > (for array inde

Re: [PATCH 06/14] net: hisilicon: Annotate struct rcb_common_cb with __counted_by

2023-09-22 Thread Gustavo A. R. Silva
On 9/22/23 11:28, Kees Cook wrote: Prepare for the coming implementation by GCC and Clang of the __counted_by attribute. Flexible array members annotated with __counted_by can have their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS (for array indexing) and CONFIG_FORTIF

Re: [PATCH 11/14] net: enetc: Annotate struct enetc_psfp_gate with __counted_by

2023-09-22 Thread Gustavo A. R. Silva
On 9/22/23 11:28, Kees Cook wrote: Prepare for the coming implementation by GCC and Clang of the __counted_by attribute. Flexible array members annotated with __counted_by can have their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS (for array indexing) and CONFIG_FORTIF

Re: [GIT PULL] hardening fixes for v6.6-rc3

2023-09-22 Thread Kees Cook
On Fri, Sep 22, 2023 at 04:55:45PM -0700, Linus Torvalds wrote: > On Fri, 22 Sept 2023 at 09:59, Kees Cook wrote: > > > > - Fix UAPI stddef.h to avoid C++-ism (Alexey Dobriyan) > > Ugh. Did we really have to make two different versions of that define? > > Ok, so C++ did something stupid wrt an e

Re: [PATCH 03/14] ipv6: Annotate struct ip6_sf_socklist with __counted_by

2023-09-22 Thread Gustavo A. R. Silva
On 9/22/23 11:28, Kees Cook wrote: Prepare for the coming implementation by GCC and Clang of the __counted_by attribute. Flexible array members annotated with __counted_by can have their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS (for array indexing) and CONFIG_FORTIF

Re: [PATCH 05/14] net: enetc: Annotate struct enetc_int_vector with __counted_by

2023-09-22 Thread Gustavo A. R. Silva
On 9/22/23 11:28, Kees Cook wrote: Prepare for the coming implementation by GCC and Clang of the __counted_by attribute. Flexible array members annotated with __counted_by can have their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS (for array indexing) and CONFIG_FORTIF

Re: [PATCH 14/14] net: sched: Annotate struct tc_pedit with __counted_by

2023-09-22 Thread Gustavo A. R. Silva
On 9/22/23 11:28, Kees Cook wrote: Prepare for the coming implementation by GCC and Clang of the __counted_by attribute. Flexible array members annotated with __counted_by can have their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS (for array indexing) and CONFIG_FORTIF

Re: [PATCH 09/14] net: mana: Annotate struct hwc_dma_buf with __counted_by

2023-09-22 Thread Gustavo A. R. Silva
On 9/22/23 11:28, Kees Cook wrote: Prepare for the coming implementation by GCC and Clang of the __counted_by attribute. Flexible array members annotated with __counted_by can have their accesses bounds-checked at run-time checking via CONFIG_UBSAN_BOUNDS (for array indexing) and CONFIG_FORTIF

<    1   2