]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
scsi: bsg: Replace zero-length array with flexible array member
authorThorsten Blum <thorsten.blum@linux.dev>
Sun, 10 Nov 2024 22:33:24 +0000 (23:33 +0100)
committerMartin K. Petersen <martin.petersen@oracle.com>
Wed, 4 Dec 2024 18:04:42 +0000 (13:04 -0500)
Replace the deprecated zero-length array with a modern flexible array
member in the struct iscsi_bsg_host_vendor_reply.

Link: https://github.com/KSPP/linux/issues/78
Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev>
Link: https://lore.kernel.org/r/20241110223323.42772-2-thorsten.blum@linux.dev
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
include/scsi/scsi_bsg_iscsi.h

index 9b1f0f424a793ad2fbe21aa2e58cec1eaaa411a7..a569c35b258d23dda35aab07c911327e12638b56 100644 (file)
@@ -59,7 +59,7 @@ struct iscsi_bsg_host_vendor {
  */
 struct iscsi_bsg_host_vendor_reply {
        /* start of vendor response area */
-       uint32_t vendor_rsp[0];
+       DECLARE_FLEX_ARRAY(uint32_t, vendor_rsp);
 };