* [PATCH] mhi: pci_generic: Add FIREHOSE channels
@ 2021-04-07 8:41 Loic Poulain
2021-04-07 8:35 ` Manivannan Sadhasivam
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Loic Poulain @ 2021-04-07 8:41 UTC (permalink / raw)
To: manivannan.sadhasivam, hemantk; +Cc: linux-arm-msm, Loic Poulain
When device enters flash programmer context (FP), it exposes firehose
protocol through the EDL dedicated channels.
Signed-off-by: Loic Poulain <loic.poulain@linaro.org>
---
drivers/bus/mhi/pci_generic.c | 35 +++++++++++++++++++++++++++++++++++
1 file changed, 35 insertions(+)
diff --git a/drivers/bus/mhi/pci_generic.c b/drivers/bus/mhi/pci_generic.c
index 544853c..fda3e88d 100644
--- a/drivers/bus/mhi/pci_generic.c
+++ b/drivers/bus/mhi/pci_generic.c
@@ -145,6 +145,36 @@ struct mhi_pci_dev_info {
.doorbell_mode_switch = false, \
}
+#define MHI_CHANNEL_CONFIG_UL_FP(ch_num, ch_name, el_count, ev_ring) \
+ { \
+ .num = ch_num, \
+ .name = ch_name, \
+ .num_elements = el_count, \
+ .event_ring = ev_ring, \
+ .dir = DMA_TO_DEVICE, \
+ .ee_mask = BIT(MHI_EE_FP), \
+ .pollcfg = 0, \
+ .doorbell = MHI_DB_BRST_DISABLE, \
+ .lpm_notify = false, \
+ .offload_channel = false, \
+ .doorbell_mode_switch = false, \
+ } \
+
+#define MHI_CHANNEL_CONFIG_DL_FP(ch_num, ch_name, el_count, ev_ring) \
+ { \
+ .num = ch_num, \
+ .name = ch_name, \
+ .num_elements = el_count, \
+ .event_ring = ev_ring, \
+ .dir = DMA_FROM_DEVICE, \
+ .ee_mask = BIT(MHI_EE_FP), \
+ .pollcfg = 0, \
+ .doorbell = MHI_DB_BRST_DISABLE, \
+ .lpm_notify = false, \
+ .offload_channel = false, \
+ .doorbell_mode_switch = false, \
+ }
+
#define MHI_EVENT_CONFIG_DATA(ev_ring, el_count) \
{ \
.num_elements = el_count, \
@@ -181,6 +211,8 @@ static const struct mhi_channel_config modem_qcom_v1_mhi_channels[] = {
MHI_CHANNEL_CONFIG_DL(15, "QMI", 4, 0),
MHI_CHANNEL_CONFIG_UL(20, "IPCR", 8, 0),
MHI_CHANNEL_CONFIG_DL(21, "IPCR", 8, 0),
+ MHI_CHANNEL_CONFIG_UL_FP(34, "FIREHOSE", 32, 0),
+ MHI_CHANNEL_CONFIG_DL_FP(35, "FIREHOSE", 32, 0),
MHI_CHANNEL_CONFIG_HW_UL(100, "IP_HW0", 128, 2),
MHI_CHANNEL_CONFIG_HW_DL(101, "IP_HW0", 128, 3),
};
@@ -241,6 +273,9 @@ static const struct mhi_channel_config mhi_quectel_em1xx_channels[] = {
MHI_CHANNEL_CONFIG_DL(13, "MBIM", 32, 0),
MHI_CHANNEL_CONFIG_UL(32, "DUN", 32, 0),
MHI_CHANNEL_CONFIG_DL(33, "DUN", 32, 0),
+ /* The EDL firmware is a flash-programmer exposing firehose protocol */
+ MHI_CHANNEL_CONFIG_UL_FP(34, "FIREHOSE", 32, 0),
+ MHI_CHANNEL_CONFIG_DL_FP(35, "FIREHOSE", 32, 0),
MHI_CHANNEL_CONFIG_HW_UL(100, "IP_HW0_MBIM", 128, 2),
MHI_CHANNEL_CONFIG_HW_DL(101, "IP_HW0_MBIM", 128, 3),
};
--
2.7.4
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] mhi: pci_generic: Add FIREHOSE channels
2021-04-07 8:41 [PATCH] mhi: pci_generic: Add FIREHOSE channels Loic Poulain
@ 2021-04-07 8:35 ` Manivannan Sadhasivam
2021-04-07 8:41 ` Manivannan Sadhasivam
2021-05-26 19:03 ` patchwork-bot+linux-arm-msm
2 siblings, 0 replies; 4+ messages in thread
From: Manivannan Sadhasivam @ 2021-04-07 8:35 UTC (permalink / raw)
To: Loic Poulain; +Cc: hemantk, linux-arm-msm
On Wed, Apr 07, 2021 at 10:41:00AM +0200, Loic Poulain wrote:
> When device enters flash programmer context (FP), it exposes firehose
> protocol through the EDL dedicated channels.
>
> 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 | 35 +++++++++++++++++++++++++++++++++++
> 1 file changed, 35 insertions(+)
>
> diff --git a/drivers/bus/mhi/pci_generic.c b/drivers/bus/mhi/pci_generic.c
> index 544853c..fda3e88d 100644
> --- a/drivers/bus/mhi/pci_generic.c
> +++ b/drivers/bus/mhi/pci_generic.c
> @@ -145,6 +145,36 @@ struct mhi_pci_dev_info {
> .doorbell_mode_switch = false, \
> }
>
> +#define MHI_CHANNEL_CONFIG_UL_FP(ch_num, ch_name, el_count, ev_ring) \
> + { \
> + .num = ch_num, \
> + .name = ch_name, \
> + .num_elements = el_count, \
> + .event_ring = ev_ring, \
> + .dir = DMA_TO_DEVICE, \
> + .ee_mask = BIT(MHI_EE_FP), \
> + .pollcfg = 0, \
> + .doorbell = MHI_DB_BRST_DISABLE, \
> + .lpm_notify = false, \
> + .offload_channel = false, \
> + .doorbell_mode_switch = false, \
> + } \
> +
> +#define MHI_CHANNEL_CONFIG_DL_FP(ch_num, ch_name, el_count, ev_ring) \
> + { \
> + .num = ch_num, \
> + .name = ch_name, \
> + .num_elements = el_count, \
> + .event_ring = ev_ring, \
> + .dir = DMA_FROM_DEVICE, \
> + .ee_mask = BIT(MHI_EE_FP), \
> + .pollcfg = 0, \
> + .doorbell = MHI_DB_BRST_DISABLE, \
> + .lpm_notify = false, \
> + .offload_channel = false, \
> + .doorbell_mode_switch = false, \
> + }
> +
> #define MHI_EVENT_CONFIG_DATA(ev_ring, el_count) \
> { \
> .num_elements = el_count, \
> @@ -181,6 +211,8 @@ static const struct mhi_channel_config modem_qcom_v1_mhi_channels[] = {
> MHI_CHANNEL_CONFIG_DL(15, "QMI", 4, 0),
> MHI_CHANNEL_CONFIG_UL(20, "IPCR", 8, 0),
> MHI_CHANNEL_CONFIG_DL(21, "IPCR", 8, 0),
> + MHI_CHANNEL_CONFIG_UL_FP(34, "FIREHOSE", 32, 0),
> + MHI_CHANNEL_CONFIG_DL_FP(35, "FIREHOSE", 32, 0),
> MHI_CHANNEL_CONFIG_HW_UL(100, "IP_HW0", 128, 2),
> MHI_CHANNEL_CONFIG_HW_DL(101, "IP_HW0", 128, 3),
> };
> @@ -241,6 +273,9 @@ static const struct mhi_channel_config mhi_quectel_em1xx_channels[] = {
> MHI_CHANNEL_CONFIG_DL(13, "MBIM", 32, 0),
> MHI_CHANNEL_CONFIG_UL(32, "DUN", 32, 0),
> MHI_CHANNEL_CONFIG_DL(33, "DUN", 32, 0),
> + /* The EDL firmware is a flash-programmer exposing firehose protocol */
> + MHI_CHANNEL_CONFIG_UL_FP(34, "FIREHOSE", 32, 0),
> + MHI_CHANNEL_CONFIG_DL_FP(35, "FIREHOSE", 32, 0),
> MHI_CHANNEL_CONFIG_HW_UL(100, "IP_HW0_MBIM", 128, 2),
> MHI_CHANNEL_CONFIG_HW_DL(101, "IP_HW0_MBIM", 128, 3),
> };
> --
> 2.7.4
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] mhi: pci_generic: Add FIREHOSE channels
2021-04-07 8:41 [PATCH] mhi: pci_generic: Add FIREHOSE channels Loic Poulain
2021-04-07 8:35 ` Manivannan Sadhasivam
@ 2021-04-07 8:41 ` Manivannan Sadhasivam
2021-05-26 19:03 ` patchwork-bot+linux-arm-msm
2 siblings, 0 replies; 4+ messages in thread
From: Manivannan Sadhasivam @ 2021-04-07 8:41 UTC (permalink / raw)
To: Loic Poulain; +Cc: hemantk, linux-arm-msm
On Wed, Apr 07, 2021 at 10:41:00AM +0200, Loic Poulain wrote:
> When device enters flash programmer context (FP), it exposes firehose
> protocol through the EDL dedicated channels.
>
> Signed-off-by: Loic Poulain <loic.poulain@linaro.org>
Applied to mhi-next!
Thanks,
Mani
> ---
> drivers/bus/mhi/pci_generic.c | 35 +++++++++++++++++++++++++++++++++++
> 1 file changed, 35 insertions(+)
>
> diff --git a/drivers/bus/mhi/pci_generic.c b/drivers/bus/mhi/pci_generic.c
> index 544853c..fda3e88d 100644
> --- a/drivers/bus/mhi/pci_generic.c
> +++ b/drivers/bus/mhi/pci_generic.c
> @@ -145,6 +145,36 @@ struct mhi_pci_dev_info {
> .doorbell_mode_switch = false, \
> }
>
> +#define MHI_CHANNEL_CONFIG_UL_FP(ch_num, ch_name, el_count, ev_ring) \
> + { \
> + .num = ch_num, \
> + .name = ch_name, \
> + .num_elements = el_count, \
> + .event_ring = ev_ring, \
> + .dir = DMA_TO_DEVICE, \
> + .ee_mask = BIT(MHI_EE_FP), \
> + .pollcfg = 0, \
> + .doorbell = MHI_DB_BRST_DISABLE, \
> + .lpm_notify = false, \
> + .offload_channel = false, \
> + .doorbell_mode_switch = false, \
> + } \
> +
> +#define MHI_CHANNEL_CONFIG_DL_FP(ch_num, ch_name, el_count, ev_ring) \
> + { \
> + .num = ch_num, \
> + .name = ch_name, \
> + .num_elements = el_count, \
> + .event_ring = ev_ring, \
> + .dir = DMA_FROM_DEVICE, \
> + .ee_mask = BIT(MHI_EE_FP), \
> + .pollcfg = 0, \
> + .doorbell = MHI_DB_BRST_DISABLE, \
> + .lpm_notify = false, \
> + .offload_channel = false, \
> + .doorbell_mode_switch = false, \
> + }
> +
> #define MHI_EVENT_CONFIG_DATA(ev_ring, el_count) \
> { \
> .num_elements = el_count, \
> @@ -181,6 +211,8 @@ static const struct mhi_channel_config modem_qcom_v1_mhi_channels[] = {
> MHI_CHANNEL_CONFIG_DL(15, "QMI", 4, 0),
> MHI_CHANNEL_CONFIG_UL(20, "IPCR", 8, 0),
> MHI_CHANNEL_CONFIG_DL(21, "IPCR", 8, 0),
> + MHI_CHANNEL_CONFIG_UL_FP(34, "FIREHOSE", 32, 0),
> + MHI_CHANNEL_CONFIG_DL_FP(35, "FIREHOSE", 32, 0),
> MHI_CHANNEL_CONFIG_HW_UL(100, "IP_HW0", 128, 2),
> MHI_CHANNEL_CONFIG_HW_DL(101, "IP_HW0", 128, 3),
> };
> @@ -241,6 +273,9 @@ static const struct mhi_channel_config mhi_quectel_em1xx_channels[] = {
> MHI_CHANNEL_CONFIG_DL(13, "MBIM", 32, 0),
> MHI_CHANNEL_CONFIG_UL(32, "DUN", 32, 0),
> MHI_CHANNEL_CONFIG_DL(33, "DUN", 32, 0),
> + /* The EDL firmware is a flash-programmer exposing firehose protocol */
> + MHI_CHANNEL_CONFIG_UL_FP(34, "FIREHOSE", 32, 0),
> + MHI_CHANNEL_CONFIG_DL_FP(35, "FIREHOSE", 32, 0),
> MHI_CHANNEL_CONFIG_HW_UL(100, "IP_HW0_MBIM", 128, 2),
> MHI_CHANNEL_CONFIG_HW_DL(101, "IP_HW0_MBIM", 128, 3),
> };
> --
> 2.7.4
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] mhi: pci_generic: Add FIREHOSE channels
2021-04-07 8:41 [PATCH] mhi: pci_generic: Add FIREHOSE channels Loic Poulain
2021-04-07 8:35 ` Manivannan Sadhasivam
2021-04-07 8:41 ` Manivannan Sadhasivam
@ 2021-05-26 19:03 ` patchwork-bot+linux-arm-msm
2 siblings, 0 replies; 4+ messages in thread
From: patchwork-bot+linux-arm-msm @ 2021-05-26 19:03 UTC (permalink / raw)
To: Loic Poulain; +Cc: linux-arm-msm
Hello:
This patch was applied to qcom/linux.git (refs/heads/for-next):
On Wed, 7 Apr 2021 10:41:00 +0200 you wrote:
> When device enters flash programmer context (FP), it exposes firehose
> protocol through the EDL dedicated channels.
>
> Signed-off-by: Loic Poulain <loic.poulain@linaro.org>
> ---
> drivers/bus/mhi/pci_generic.c | 35 +++++++++++++++++++++++++++++++++++
> 1 file changed, 35 insertions(+)
Here is the summary with links:
- mhi: pci_generic: Add FIREHOSE channels
https://git.kernel.org/qcom/c/11134390d742
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2021-05-26 19:04 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-04-07 8:41 [PATCH] mhi: pci_generic: Add FIREHOSE channels Loic Poulain
2021-04-07 8:35 ` Manivannan Sadhasivam
2021-04-07 8:41 ` Manivannan Sadhasivam
2021-05-26 19:03 ` patchwork-bot+linux-arm-msm
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).