cifs: silence compiler warnings showing up with gcc-8.0.0
[linux-2.6-microblaze.git] / fs / cifs / cifssmb.c
index 4e0922d..9ceebf3 100644 (file)
@@ -6343,9 +6343,7 @@ SetEARetry:
        pSMB->InformationLevel =
                cpu_to_le16(SMB_SET_FILE_EA);
 
-       parm_data =
-               (struct fealist *) (((char *) &pSMB->hdr.Protocol) +
-                                      offset);
+       parm_data = (void *)pSMB + offsetof(struct smb_hdr, Protocol) + offset;
        pSMB->ParameterOffset = cpu_to_le16(param_offset);
        pSMB->DataOffset = cpu_to_le16(offset);
        pSMB->SetupCount = 1;