summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSivan Reinstein <sivanr@codeaurora.org>2016-03-09 14:27:16 +0200
committerDavid Keitel <dkeitel@codeaurora.org>2016-03-25 16:03:30 -0700
commit02e71b3dfd5a89b5a1ace3c1dbcd4b553fa4a919 (patch)
tree3ada1bdcdce60c697b211be8a3cc6d271bc1b2d9
parentdb599a70cb5bcbab7db755a09c926057f0591ca8 (diff)
msm: ipa3: use vaddr instead of paddr to load IPA FWs
In order to provide an identical ELF file format between MSM and MDM, the IPA core driver needs to utilize p_vaddr field as the destination address for the FW loader. Change-Id: I818fbe37601dbd4250fc428223a4a1b72b91487a CRs-Fixed: 987522 Acked-by: David Arinzon <darinzon@qti.qualcomm.com> Signed-off-by: Sivan Reinstein <sivanr@codeaurora.org>
-rw-r--r--drivers/platform/msm/ipa/ipa_v3/ipa_utils.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/drivers/platform/msm/ipa/ipa_v3/ipa_utils.c b/drivers/platform/msm/ipa/ipa_v3/ipa_utils.c
index 1b1ab8bac6a7..bfa62552f090 100644
--- a/drivers/platform/msm/ipa/ipa_v3/ipa_utils.c
+++ b/drivers/platform/msm/ipa/ipa_v3/ipa_utils.c
@@ -5119,10 +5119,6 @@ int ipa3_generate_eq_from_hw_rule(
*/
int ipa3_load_fws(const struct firmware *firmware)
{
- /*
- * TODO: Do we need to use a generic elf_hdr/elf_phdr
- * so we won't have issues with 64bit systems?
- */
const struct elf32_hdr *ehdr;
const struct elf32_phdr *phdr;
const uint8_t *elf_phdr_ptr;
@@ -5142,15 +5138,15 @@ int ipa3_load_fws(const struct firmware *firmware)
phdr = (struct elf32_phdr *)elf_phdr_ptr;
/*
- * p_addr will contain the physical address to which the
+ * p_vaddr will contain the starting address to which the
* FW needs to be loaded.
* p_memsz will contain the size of the IRAM.
* p_filesz will contain the size of the FW image.
*/
- fw_mem_base = ioremap(phdr->p_paddr, phdr->p_memsz);
+ fw_mem_base = ioremap(phdr->p_vaddr, phdr->p_memsz);
if (!fw_mem_base) {
IPAERR("Failed to map 0x%x for the size of %u\n",
- phdr->p_paddr, phdr->p_memsz);
+ phdr->p_vaddr, phdr->p_memsz);
return -ENOMEM;
}