Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0c35f526 authored by Skylar Chang's avatar Skylar Chang Committed by Gerrit - the friendly Code Review server
Browse files

msm: ipa: fix modem SW SRAM partition issue



In 8994 target with ipa HW version 2.0, we see the
boot-up crash when we try to use full ipa-sram, the
fix is to get the additional 256 bytes from
APPS_V4_FLT_SIZE

Change-Id: I06d8724869af2a201fa93ec59b7b43434e133ce3
Signed-off-by: default avatarSkylar Chang <chiaweic@codeaurora.org>
parent 6b4066e4
Loading
Loading
Loading
Loading
+8 −2
Original line number Diff line number Diff line
@@ -1191,8 +1191,14 @@ int ipa_init_q6_smem(void)

	ipa_inc_client_enable_clks();

	if (ipa_ctx->ipa_hw_type == IPA_HW_v2_0)
		rc = ipa_init_smem_region(IPA_MEM_PART(modem_size) -
			IPA_MEM_RAM_MODEM_NETWORK_STATS_SIZE,
			IPA_MEM_PART(modem_ofst));
	else
		rc = ipa_init_smem_region(IPA_MEM_PART(modem_size),
			IPA_MEM_PART(modem_ofst));

	if (rc) {
		IPAERR("failed to initialize Modem RAM memory\n");
		ipa_dec_client_disable_clks();
+2 −1
Original line number Diff line number Diff line
@@ -49,6 +49,7 @@
#define IPA_MEM_CANARY_SIZE 4
#define IPA_MEM_CANARY_VAL 0xdeadbeef

#define IPA_MEM_RAM_MODEM_NETWORK_STATS_SIZE 256
/*
 * IPA v2.0 and v2.1 SRAM memory layout:
 * +-------------+
@@ -166,7 +167,7 @@

#define IPA_MEM_v2_RAM_APPS_V4_FLT_OFST (IPA_MEM_v2_RAM_MODEM_OFST + \
		IPA_MEM_v2_RAM_MODEM_SIZE + IPA_MEM_CANARY_SIZE)
#define IPA_MEM_v2_RAM_APPS_V4_FLT_SIZE 2176
#define IPA_MEM_v2_RAM_APPS_V4_FLT_SIZE 1920

/* filtering rule is 4B aligned */
#if (IPA_MEM_v2_RAM_APPS_V4_FLT_OFST & 3)