Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

scsi: bsg: Replace zero-length array with flexible array member

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>

authored by

Thorsten Blum and committed by
Martin K. Petersen
cdb03e59 5f8822c4

+1 -1
+1 -1
include/scsi/scsi_bsg_iscsi.h
··· 59 59 */ 60 60 struct iscsi_bsg_host_vendor_reply { 61 61 /* start of vendor response area */ 62 - uint32_t vendor_rsp[0]; 62 + DECLARE_FLEX_ARRAY(uint32_t, vendor_rsp); 63 63 }; 64 64 65 65