goto out;
}
- bhdr = (struct binary_header *)(adev->discovery + PSP_HEADER_SIZE);
+ bhdr = (struct binary_header *)adev->discovery;
if (le32_to_cpu(bhdr->binary_signature) != BINARY_SIGNATURE) {
DRM_ERROR("invalid ip discovery binary signature\n");
goto out;
}
- offset = PSP_HEADER_SIZE +
- offsetof(struct binary_header, binary_checksum) +
+ offset = offsetof(struct binary_header, binary_checksum) +
sizeof(bhdr->binary_checksum);
size = bhdr->binary_size - offset;
checksum = bhdr->binary_checksum;
return -EINVAL;
}
- bhdr = (struct binary_header *)(adev->discovery + PSP_HEADER_SIZE);
+ bhdr = (struct binary_header *)adev->discovery;
ihdr = (struct ip_discovery_header *)(adev->discovery +
le16_to_cpu(bhdr->table_list[IP_DISCOVERY].offset));
num_dies = le16_to_cpu(ihdr->num_dies);
return -EINVAL;
}
- bhdr = (struct binary_header *)(adev->discovery + PSP_HEADER_SIZE);
+ bhdr = (struct binary_header *)adev->discovery;
ihdr = (struct ip_discovery_header *)(adev->discovery +
le16_to_cpu(bhdr->table_list[IP_DISCOVERY].offset));
num_dies = le16_to_cpu(ihdr->num_dies);
return -EINVAL;
}
- bhdr = (struct binary_header *)(adev->discovery + PSP_HEADER_SIZE);
+ bhdr = (struct binary_header *)adev->discovery;
gc_info = (struct gc_info_v1_0 *)(adev->discovery +
le16_to_cpu(bhdr->table_list[GC].offset));