On 2025-04-29 14:03:40-0600, Gustavo A. R. Silva wrote: > -Wflex-array-member-not-at-end was introduced in GCC-14, and we are > getting ready to enable it, globally. > > Replace an on-stack definition of a flexible structure with a call > to utility function cros_ec_cmd(). > > So, with these changes, fix the following warning: > > drivers/power/supply/cros_charge-control.c:57:40: warning: structure > containing a flexible array member is not at the end of another structure > [-Wflex-array-member-not-at-end] > > Signed-off-by: Gustavo A. R. Silva <[email protected]>
Thanks, Acked-by: Thomas Weißschuh <[email protected]> > --- > Changes in v2: > - Use utility function cros_ec_cmd() instead of DEFINE_RAW_FLEX(). (Thomas > Weißschuh) > > v1: > - Link: https://lore.kernel.org/linux-hardening/aBEmk6ixfrQ2XpTw@kspp/ > > drivers/power/supply/cros_charge-control.c | 23 +++++++--------------- > 1 file changed, 7 insertions(+), 16 deletions(-) <snip>
