Message ID | 1612514195-8257-1-git-send-email-loic.poulain@linaro.org |
---|---|
State | Accepted |
Commit | 026c5b1ec29cb9904406c7b3090eaf54e345e7f2 |
Headers | show |
Series | bus: mhi: pci_generic: Increase num of elements in hw event ring | expand |
On Fri, Feb 05, 2021 at 09:36:35AM +0100, Loic Poulain wrote: > We met some sporadic modem crashes during high throughput testing, this > has been root caused to a lack of elements in the event ring. Indeed, > the modem is simply crashing when event ring becomes empty. > > It appears that the total number event ring elements is too low given > the performances of the modem (IPA hardware accelerator). This change > increases the number of elements in the hardware event ring to 2048, > which is aligned with what is defined in downstream version: > https://source.codeaurora.org/quic/la/kernel/msm-4.14/tree/arch/arm64/boot/dts/qcom/sm8150-mhi.dtsi?h=msm-4.14#n482 > > With this change, modem coes not crash anymore. > > Note: An event ring element is 16-Byte, so the total memory usage of > a hardware event ring is now 32KB. > > Signed-off-by: Loic Poulain <loic.poulain@linaro.org> Reviewed-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org> Thanks, Mani > --- > drivers/bus/mhi/pci_generic.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/bus/mhi/pci_generic.c b/drivers/bus/mhi/pci_generic.c > index 5b3a23a4..c20f59e 100644 > --- a/drivers/bus/mhi/pci_generic.c > +++ b/drivers/bus/mhi/pci_generic.c > @@ -129,7 +129,7 @@ struct mhi_pci_dev_info { > > #define MHI_EVENT_CONFIG_HW_DATA(ev_ring, ch_num) \ > { \ > - .num_elements = 256, \ > + .num_elements = 2048, \ > .irq_moderation_ms = 1, \ > .irq = (ev_ring) + 1, \ > .priority = 1, \ > -- > 2.7.4 >
On Fri, Feb 05, 2021 at 09:36:35AM +0100, Loic Poulain wrote: > We met some sporadic modem crashes during high throughput testing, this > has been root caused to a lack of elements in the event ring. Indeed, > the modem is simply crashing when event ring becomes empty. > > It appears that the total number event ring elements is too low given > the performances of the modem (IPA hardware accelerator). This change > increases the number of elements in the hardware event ring to 2048, > which is aligned with what is defined in downstream version: > https://source.codeaurora.org/quic/la/kernel/msm-4.14/tree/arch/arm64/boot/dts/qcom/sm8150-mhi.dtsi?h=msm-4.14#n482 > > With this change, modem coes not crash anymore. > > Note: An event ring element is 16-Byte, so the total memory usage of > a hardware event ring is now 32KB. > > Signed-off-by: Loic Poulain <loic.poulain@linaro.org> Applied to mhi-next! Thanks, Mani > --- > drivers/bus/mhi/pci_generic.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/bus/mhi/pci_generic.c b/drivers/bus/mhi/pci_generic.c > index 5b3a23a4..c20f59e 100644 > --- a/drivers/bus/mhi/pci_generic.c > +++ b/drivers/bus/mhi/pci_generic.c > @@ -129,7 +129,7 @@ struct mhi_pci_dev_info { > > #define MHI_EVENT_CONFIG_HW_DATA(ev_ring, ch_num) \ > { \ > - .num_elements = 256, \ > + .num_elements = 2048, \ > .irq_moderation_ms = 1, \ > .irq = (ev_ring) + 1, \ > .priority = 1, \ > -- > 2.7.4 >
On 2/5/2021 5:34 AM, Manivannan Sadhasivam wrote: > On Fri, Feb 05, 2021 at 09:36:35AM +0100, Loic Poulain wrote: >> We met some sporadic modem crashes during high throughput testing, this >> has been root caused to a lack of elements in the event ring. Indeed, >> the modem is simply crashing when event ring becomes empty. >> >> It appears that the total number event ring elements is too low given >> the performances of the modem (IPA hardware accelerator). This change >> increases the number of elements in the hardware event ring to 2048, >> which is aligned with what is defined in downstream version: >> https://source.codeaurora.org/quic/la/kernel/msm-4.14/tree/arch/arm64/boot/dts/qcom/sm8150-mhi.dtsi?h=msm-4.14#n482 >> >> With this change, modem coes not crash anymore. >> >> Note: An event ring element is 16-Byte, so the total memory usage of >> a hardware event ring is now 32KB. >> >> Signed-off-by: Loic Poulain <loic.poulain@linaro.org> > > Applied to mhi-next! > > Thanks, > Mani Probably too late, but there is a typo in the commit text. "modem coes not crash" should be "modem does not crash". -- Jeffrey Hugo Qualcomm Technologies, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project.
Hello: This patch was applied to qcom/linux.git (refs/heads/for-next): On Fri, 5 Feb 2021 09:36:35 +0100 you wrote: > We met some sporadic modem crashes during high throughput testing, this > has been root caused to a lack of elements in the event ring. Indeed, > the modem is simply crashing when event ring becomes empty. > > It appears that the total number event ring elements is too low given > the performances of the modem (IPA hardware accelerator). This change > increases the number of elements in the hardware event ring to 2048, > which is aligned with what is defined in downstream version: > https://source.codeaurora.org/quic/la/kernel/msm-4.14/tree/arch/arm64/boot/dts/qcom/sm8150-mhi.dtsi?h=msm-4.14#n482 > > [...] Here is the summary with links: - bus: mhi: pci_generic: Increase num of elements in hw event ring https://git.kernel.org/qcom/c/026c5b1ec29c You are awesome, thank you! -- Deet-doot-dot, I am a bot. https://korg.docs.kernel.org/patchwork/pwbot.html
diff --git a/drivers/bus/mhi/pci_generic.c b/drivers/bus/mhi/pci_generic.c index 5b3a23a4..c20f59e 100644 --- a/drivers/bus/mhi/pci_generic.c +++ b/drivers/bus/mhi/pci_generic.c @@ -129,7 +129,7 @@ struct mhi_pci_dev_info { #define MHI_EVENT_CONFIG_HW_DATA(ev_ring, ch_num) \ { \ - .num_elements = 256, \ + .num_elements = 2048, \ .irq_moderation_ms = 1, \ .irq = (ev_ring) + 1, \ .priority = 1, \
We met some sporadic modem crashes during high throughput testing, this has been root caused to a lack of elements in the event ring. Indeed, the modem is simply crashing when event ring becomes empty. It appears that the total number event ring elements is too low given the performances of the modem (IPA hardware accelerator). This change increases the number of elements in the hardware event ring to 2048, which is aligned with what is defined in downstream version: https://source.codeaurora.org/quic/la/kernel/msm-4.14/tree/arch/arm64/boot/dts/qcom/sm8150-mhi.dtsi?h=msm-4.14#n482 With this change, modem coes not crash anymore. Note: An event ring element is 16-Byte, so the total memory usage of a hardware event ring is now 32KB. Signed-off-by: Loic Poulain <loic.poulain@linaro.org> --- drivers/bus/mhi/pci_generic.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.7.4