treewide: Replace 0-element memcpy() destinations with flexible arrays
[linux-2.6-microblaze.git] / drivers / net / wireless / ath / ath10k / bmi.h
index f6fadcb..0685c0d 100644 (file)
@@ -109,7 +109,7 @@ struct bmi_cmd {
                struct {
                        __le32 addr;
                        __le32 len;
-                       u8 payload[0];
+                       u8 payload[];
                } write_mem;
                struct {
                        __le32 addr;
@@ -138,18 +138,18 @@ struct bmi_cmd {
                } rompatch_uninstall;
                struct {
                        __le32 count;
-                       __le32 patch_ids[0]; /* length of @count */
+                       __le32 patch_ids[]; /* length of @count */
                } rompatch_activate;
                struct {
                        __le32 count;
-                       __le32 patch_ids[0]; /* length of @count */
+                       __le32 patch_ids[]; /* length of @count */
                } rompatch_deactivate;
                struct {
                        __le32 addr;
                } lz_start;
                struct {
                        __le32 len; /* max BMI_MAX_DATA_SIZE */
-                       u8 payload[0]; /* length of @len */
+                       u8 payload[]; /* length of @len */
                } lz_data;
                struct {
                        u8 name[BMI_NVRAM_SEG_NAME_SZ];
@@ -160,7 +160,7 @@ struct bmi_cmd {
 
 union bmi_resp {
        struct {
-               u8 payload[0];
+               DECLARE_FLEX_ARRAY(u8, payload);
        } read_mem;
        struct {
                __le32 result;