[GIT,PULL] flexible-array transformations for 6.5-rc1

Message ID ZJxZJDUDs1ry84Rc@work
State New
Headers
Series [GIT,PULL] flexible-array transformations for 6.5-rc1 |

Pull-request

git://git.kernel.org/pub/scm/linux/kernel/git/gustavoars/linux.git tags/flex-array-transformations-6.5-rc1

Message

Gustavo A. R. Silva June 28, 2023, 4 p.m. UTC
  The following changes since commit f1fcbaa18b28dec10281551dfe6ed3a3ed80e3d6:

  Linux 6.4-rc2 (2023-05-14 12:51:40 -0700)

are available in the Git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/gustavoars/linux.git tags/flex-array-transformations-6.5-rc1

for you to fetch changes up to 1fa89cccd288cea4370ce08042b749b72ea8b059:

  media: venus: hfi_cmds: Replace fake flex-arrays with flexible-array members (2023-06-11 09:51:08 -0600)

----------------------------------------------------------------
flexible-array transformations for 6.5-rc1

Hi Linus,

Please, pull the following patches that transform zero-length and
one-element arrays into C99 flexible-array members. These patches
have been baking in linux-next for a while.

Thanks
--
Gustavo

----------------------------------------------------------------
Gustavo A. R. Silva (2):
      uapi: wireless: Replace zero-length array with flexible-array member
      media: venus: hfi_cmds: Replace fake flex-arrays with flexible-array members

 drivers/media/platform/qcom/venus/hfi_cmds.h | 8 ++++----
 include/uapi/linux/wireless.h                | 2 +-
 2 files changed, 5 insertions(+), 5 deletions(-)
  

Comments

Linus Torvalds June 30, 2023, 12:07 a.m. UTC | #1
On Wed, 28 Jun 2023 at 08:59, Gustavo A. R. Silva <gustavoars@kernel.org> wrote:
>
> Please, pull the following patches that transform zero-length and
> one-element arrays into C99 flexible-array members. These patches
> have been baking in linux-next for a while.

This must stop.

Honestly, this is just making things *WORSE*.

That drivers/media/platform/qcom/venus/hfi_cmds.h needs to be
converted all-or-nothing, not this crazy piece-meal conversion effort.

You literally seem to be converting structure definitions that ARE NOT
USED, and then leaving the ones that actually *are* used alone,
because they have uses like

    struct hfi_sys_set_resource_pkt {
    ..
        u32 resource_data[1];
    };

                pkt->hdr.size += sizeof(*res) - sizeof(u32);

where 'res' is a pointer to that packet type.

I'm not at all interested in patches that convert structures that have
zero use. You might as well just *remove* them in that case, rather
than make some syntactic change that doesn't matter.

And yes, that header file already has a mix of '[]' arrays and '[1]'
arrays. I'm not interested in continuing that kind of pointless
conversion.

Either this gets converted properly, or it gets left alone. No more of
this kind of crazy "let's convert the types that are never used".

            Linus