summaryrefslogtreecommitdiff
path: root/drivers/platform/msm
diff options
context:
space:
mode:
authorGidon Studinski <gidons@codeaurora.org>2016-04-17 17:54:18 +0300
committerJeevan Shriram <jshriram@codeaurora.org>2016-04-22 15:03:05 -0700
commitb391ac1b4859157ea8a386c41729d90f32914bb7 (patch)
treeae914adf493bf8fec2e162f4ec903e308f9c96b8 /drivers/platform/msm
parent752fcde3d8d94f2097ebd81b0b4a68bbf2c8ad06 (diff)
msm: ipa3: enable smart prefetch control for MHI
Enable smart prefetch control for MHI channels. This is done by configuring the channel scratch in GSI. Change-Id: Icff18699ce96e224d6f58b8aadce006f3d5210ee CRs-Fixed: 1004468 Signed-off-by: Gidon Studinski <gidons@codeaurora.org>
Diffstat (limited to 'drivers/platform/msm')
-rw-r--r--drivers/platform/msm/ipa/ipa_v3/ipa_mhi.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/platform/msm/ipa/ipa_v3/ipa_mhi.c b/drivers/platform/msm/ipa/ipa_v3/ipa_mhi.c
index 82f63d3cf5a5..401bb0f61ee8 100644
--- a/drivers/platform/msm/ipa/ipa_v3/ipa_mhi.c
+++ b/drivers/platform/msm/ipa/ipa_v3/ipa_mhi.c
@@ -1671,9 +1671,10 @@ static int ipa_mhi_start_gsi_channel(struct ipa3_mhi_channel_ctx *channel,
channel->channel_context_addr +
offsetof(struct ipa3_mhi_ch_ctx, wp));
ch_scratch.mhi.assert_bit40 = ipa3_mhi_ctx->assert_bit40;
- ch_scratch.mhi.max_outstanding_tre = 0;
+ ch_scratch.mhi.max_outstanding_tre =
+ ep_cfg->ipa_if_tlv * ch_props.re_size;
ch_scratch.mhi.outstanding_threshold =
- 4 * GSI_CHAN_RE_SIZE_16B;
+ min(ep_cfg->ipa_if_tlv / 2, 8) * ch_props.re_size;
ch_scratch.mhi.oob_mod_threshold = 4;
if (channel->ch_ctx_host.brstmode == IPA_MHI_BURST_MODE_DEFAULT ||
channel->ch_ctx_host.brstmode == IPA_MHI_BURST_MODE_ENABLE) {