* [PATCH 1/3] net: ipa: Fix v4.7 resource group names
2025-02-27 10:33 [PATCH 0/3] Fixes for IPA v4.7 Luca Weiss
@ 2025-02-27 10:33 ` Luca Weiss
2025-03-04 16:50 ` Alex Elder
2025-02-27 10:33 ` [PATCH 2/3] net: ipa: Fix QSB data for v4.7 Luca Weiss
` (3 subsequent siblings)
4 siblings, 1 reply; 10+ messages in thread
From: Luca Weiss @ 2025-02-27 10:33 UTC (permalink / raw)
To: Alex Elder, Andrew Lunn, David S. Miller, Eric Dumazet,
Jakub Kicinski, Paolo Abeni
Cc: ~postmarketos/upstreaming, phone-devel, netdev, linux-kernel,
Luca Weiss
In the downstream IPA driver there's only one group defined for source
and destination, and the destination group doesn't have a _DPL suffix.
Fixes: b310de784bac ("net: ipa: add IPA v4.7 support")
Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
---
drivers/net/ipa/data/ipa_data-v4.7.c | 12 +++++-------
1 file changed, 5 insertions(+), 7 deletions(-)
diff --git a/drivers/net/ipa/data/ipa_data-v4.7.c b/drivers/net/ipa/data/ipa_data-v4.7.c
index c8c23d9be961b1b818e8a1592a7f7dd76cdd5468..7e315779e66480c2a3f2473a068278ab5e513a3d 100644
--- a/drivers/net/ipa/data/ipa_data-v4.7.c
+++ b/drivers/net/ipa/data/ipa_data-v4.7.c
@@ -28,12 +28,10 @@ enum ipa_resource_type {
enum ipa_rsrc_group_id {
/* Source resource group identifiers */
IPA_RSRC_GROUP_SRC_UL_DL = 0,
- IPA_RSRC_GROUP_SRC_UC_RX_Q,
IPA_RSRC_GROUP_SRC_COUNT, /* Last in set; not a source group */
/* Destination resource group identifiers */
- IPA_RSRC_GROUP_DST_UL_DL_DPL = 0,
- IPA_RSRC_GROUP_DST_UNUSED_1,
+ IPA_RSRC_GROUP_DST_UL_DL = 0,
IPA_RSRC_GROUP_DST_COUNT, /* Last; not a destination group */
};
@@ -81,7 +79,7 @@ static const struct ipa_gsi_endpoint_data ipa_gsi_endpoint_data[] = {
},
.endpoint = {
.config = {
- .resource_group = IPA_RSRC_GROUP_DST_UL_DL_DPL,
+ .resource_group = IPA_RSRC_GROUP_DST_UL_DL,
.aggregation = true,
.status_enable = true,
.rx = {
@@ -128,7 +126,7 @@ static const struct ipa_gsi_endpoint_data ipa_gsi_endpoint_data[] = {
},
.endpoint = {
.config = {
- .resource_group = IPA_RSRC_GROUP_DST_UL_DL_DPL,
+ .resource_group = IPA_RSRC_GROUP_DST_UL_DL,
.qmap = true,
.aggregation = true,
.rx = {
@@ -197,12 +195,12 @@ static const struct ipa_resource ipa_resource_src[] = {
/* Destination resource configuration data for an SoC having IPA v4.7 */
static const struct ipa_resource ipa_resource_dst[] = {
[IPA_RESOURCE_TYPE_DST_DATA_SECTORS] = {
- .limits[IPA_RSRC_GROUP_DST_UL_DL_DPL] = {
+ .limits[IPA_RSRC_GROUP_DST_UL_DL] = {
.min = 7, .max = 7,
},
},
[IPA_RESOURCE_TYPE_DST_DPS_DMARS] = {
- .limits[IPA_RSRC_GROUP_DST_UL_DL_DPL] = {
+ .limits[IPA_RSRC_GROUP_DST_UL_DL] = {
.min = 2, .max = 2,
},
},
--
2.48.1
^ permalink raw reply related [flat|nested] 10+ messages in thread* Re: [PATCH 1/3] net: ipa: Fix v4.7 resource group names
2025-02-27 10:33 ` [PATCH 1/3] net: ipa: Fix v4.7 resource group names Luca Weiss
@ 2025-03-04 16:50 ` Alex Elder
0 siblings, 0 replies; 10+ messages in thread
From: Alex Elder @ 2025-03-04 16:50 UTC (permalink / raw)
To: Luca Weiss, Alex Elder, Andrew Lunn, David S. Miller,
Eric Dumazet, Jakub Kicinski, Paolo Abeni
Cc: ~postmarketos/upstreaming, phone-devel, netdev, linux-kernel
On 2/27/25 4:33 AM, Luca Weiss wrote:
> In the downstream IPA driver there's only one group defined for source
> and destination, and the destination group doesn't have a _DPL suffix.
>
> Fixes: b310de784bac ("net: ipa: add IPA v4.7 support")
> Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
FYI, I used this to check what you're saying:
https://git.codelinaro.org/clo/la/platform/vendor/opensource/dataipa/-/blob/clo/main/drivers/platform/msm/ipa/ipa_v3/ipa_utils.c
This looks good, thanks a lot for the patch.
Reviewed-by: Alex Elder <elder@riscstar.com>
> ---
> drivers/net/ipa/data/ipa_data-v4.7.c | 12 +++++-------
> 1 file changed, 5 insertions(+), 7 deletions(-)
>
> diff --git a/drivers/net/ipa/data/ipa_data-v4.7.c b/drivers/net/ipa/data/ipa_data-v4.7.c
> index c8c23d9be961b1b818e8a1592a7f7dd76cdd5468..7e315779e66480c2a3f2473a068278ab5e513a3d 100644
> --- a/drivers/net/ipa/data/ipa_data-v4.7.c
> +++ b/drivers/net/ipa/data/ipa_data-v4.7.c
> @@ -28,12 +28,10 @@ enum ipa_resource_type {
> enum ipa_rsrc_group_id {
> /* Source resource group identifiers */
> IPA_RSRC_GROUP_SRC_UL_DL = 0,
> - IPA_RSRC_GROUP_SRC_UC_RX_Q,
> IPA_RSRC_GROUP_SRC_COUNT, /* Last in set; not a source group */
>
> /* Destination resource group identifiers */
> - IPA_RSRC_GROUP_DST_UL_DL_DPL = 0,
> - IPA_RSRC_GROUP_DST_UNUSED_1,
> + IPA_RSRC_GROUP_DST_UL_DL = 0,
> IPA_RSRC_GROUP_DST_COUNT, /* Last; not a destination group */
> };
>
> @@ -81,7 +79,7 @@ static const struct ipa_gsi_endpoint_data ipa_gsi_endpoint_data[] = {
> },
> .endpoint = {
> .config = {
> - .resource_group = IPA_RSRC_GROUP_DST_UL_DL_DPL,
> + .resource_group = IPA_RSRC_GROUP_DST_UL_DL,
> .aggregation = true,
> .status_enable = true,
> .rx = {
> @@ -128,7 +126,7 @@ static const struct ipa_gsi_endpoint_data ipa_gsi_endpoint_data[] = {
> },
> .endpoint = {
> .config = {
> - .resource_group = IPA_RSRC_GROUP_DST_UL_DL_DPL,
> + .resource_group = IPA_RSRC_GROUP_DST_UL_DL,
> .qmap = true,
> .aggregation = true,
> .rx = {
> @@ -197,12 +195,12 @@ static const struct ipa_resource ipa_resource_src[] = {
> /* Destination resource configuration data for an SoC having IPA v4.7 */
> static const struct ipa_resource ipa_resource_dst[] = {
> [IPA_RESOURCE_TYPE_DST_DATA_SECTORS] = {
> - .limits[IPA_RSRC_GROUP_DST_UL_DL_DPL] = {
> + .limits[IPA_RSRC_GROUP_DST_UL_DL] = {
> .min = 7, .max = 7,
> },
> },
> [IPA_RESOURCE_TYPE_DST_DPS_DMARS] = {
> - .limits[IPA_RSRC_GROUP_DST_UL_DL_DPL] = {
> + .limits[IPA_RSRC_GROUP_DST_UL_DL] = {
> .min = 2, .max = 2,
> },
> },
>
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH 2/3] net: ipa: Fix QSB data for v4.7
2025-02-27 10:33 [PATCH 0/3] Fixes for IPA v4.7 Luca Weiss
2025-02-27 10:33 ` [PATCH 1/3] net: ipa: Fix v4.7 resource group names Luca Weiss
@ 2025-02-27 10:33 ` Luca Weiss
2025-03-04 16:50 ` Alex Elder
2025-02-27 10:33 ` [PATCH 3/3] net: ipa: Enable checksum for IPA_ENDPOINT_AP_MODEM_{RX,TX} " Luca Weiss
` (2 subsequent siblings)
4 siblings, 1 reply; 10+ messages in thread
From: Luca Weiss @ 2025-02-27 10:33 UTC (permalink / raw)
To: Alex Elder, Andrew Lunn, David S. Miller, Eric Dumazet,
Jakub Kicinski, Paolo Abeni
Cc: ~postmarketos/upstreaming, phone-devel, netdev, linux-kernel,
Luca Weiss
As per downstream reference, max_writes should be 12 and max_reads
should be 13.
Fixes: b310de784bac ("net: ipa: add IPA v4.7 support")
Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
---
drivers/net/ipa/data/ipa_data-v4.7.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/ipa/data/ipa_data-v4.7.c b/drivers/net/ipa/data/ipa_data-v4.7.c
index 7e315779e66480c2a3f2473a068278ab5e513a3d..e63dcf8d45567b0851393c2cea7a0d630afa20cd 100644
--- a/drivers/net/ipa/data/ipa_data-v4.7.c
+++ b/drivers/net/ipa/data/ipa_data-v4.7.c
@@ -38,8 +38,8 @@ enum ipa_rsrc_group_id {
/* QSB configuration data for an SoC having IPA v4.7 */
static const struct ipa_qsb_data ipa_qsb_data[] = {
[IPA_QSB_MASTER_DDR] = {
- .max_writes = 8,
- .max_reads = 0, /* no limit (hardware max) */
+ .max_writes = 12,
+ .max_reads = 13,
.max_reads_beats = 120,
},
};
--
2.48.1
^ permalink raw reply related [flat|nested] 10+ messages in thread* Re: [PATCH 2/3] net: ipa: Fix QSB data for v4.7
2025-02-27 10:33 ` [PATCH 2/3] net: ipa: Fix QSB data for v4.7 Luca Weiss
@ 2025-03-04 16:50 ` Alex Elder
0 siblings, 0 replies; 10+ messages in thread
From: Alex Elder @ 2025-03-04 16:50 UTC (permalink / raw)
To: Luca Weiss, Alex Elder, Andrew Lunn, David S. Miller,
Eric Dumazet, Jakub Kicinski, Paolo Abeni
Cc: ~postmarketos/upstreaming, phone-devel, netdev, linux-kernel
On 2/27/25 4:33 AM, Luca Weiss wrote:
> As per downstream reference, max_writes should be 12 and max_reads
> should be 13.
>
> Fixes: b310de784bac ("net: ipa: add IPA v4.7 support")
> Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
Looks good.
Reviewed-by: Alex Elder <elder@riscstar.com>
> ---
> drivers/net/ipa/data/ipa_data-v4.7.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/net/ipa/data/ipa_data-v4.7.c b/drivers/net/ipa/data/ipa_data-v4.7.c
> index 7e315779e66480c2a3f2473a068278ab5e513a3d..e63dcf8d45567b0851393c2cea7a0d630afa20cd 100644
> --- a/drivers/net/ipa/data/ipa_data-v4.7.c
> +++ b/drivers/net/ipa/data/ipa_data-v4.7.c
> @@ -38,8 +38,8 @@ enum ipa_rsrc_group_id {
> /* QSB configuration data for an SoC having IPA v4.7 */
> static const struct ipa_qsb_data ipa_qsb_data[] = {
> [IPA_QSB_MASTER_DDR] = {
> - .max_writes = 8,
> - .max_reads = 0, /* no limit (hardware max) */
> + .max_writes = 12,
> + .max_reads = 13,
> .max_reads_beats = 120,
> },
> };
>
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH 3/3] net: ipa: Enable checksum for IPA_ENDPOINT_AP_MODEM_{RX,TX} for v4.7
2025-02-27 10:33 [PATCH 0/3] Fixes for IPA v4.7 Luca Weiss
2025-02-27 10:33 ` [PATCH 1/3] net: ipa: Fix v4.7 resource group names Luca Weiss
2025-02-27 10:33 ` [PATCH 2/3] net: ipa: Fix QSB data for v4.7 Luca Weiss
@ 2025-02-27 10:33 ` Luca Weiss
2025-03-04 16:50 ` Alex Elder
2025-02-28 22:52 ` [PATCH 0/3] Fixes for IPA v4.7 Jakub Kicinski
2025-03-05 0:30 ` patchwork-bot+netdevbpf
4 siblings, 1 reply; 10+ messages in thread
From: Luca Weiss @ 2025-02-27 10:33 UTC (permalink / raw)
To: Alex Elder, Andrew Lunn, David S. Miller, Eric Dumazet,
Jakub Kicinski, Paolo Abeni
Cc: ~postmarketos/upstreaming, phone-devel, netdev, linux-kernel,
Luca Weiss
Enable the checksum option for these two endpoints in order to allow
mobile data to actually work. Without this, no packets seem to make it
through the IPA.
Fixes: b310de784bac ("net: ipa: add IPA v4.7 support")
Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
---
drivers/net/ipa/data/ipa_data-v4.7.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/net/ipa/data/ipa_data-v4.7.c b/drivers/net/ipa/data/ipa_data-v4.7.c
index e63dcf8d45567b0851393c2cea7a0d630afa20cd..41f212209993f10fee338e28027739a7402d5089 100644
--- a/drivers/net/ipa/data/ipa_data-v4.7.c
+++ b/drivers/net/ipa/data/ipa_data-v4.7.c
@@ -104,6 +104,7 @@ static const struct ipa_gsi_endpoint_data ipa_gsi_endpoint_data[] = {
.filter_support = true,
.config = {
.resource_group = IPA_RSRC_GROUP_SRC_UL_DL,
+ .checksum = true,
.qmap = true,
.status_enable = true,
.tx = {
@@ -127,6 +128,7 @@ static const struct ipa_gsi_endpoint_data ipa_gsi_endpoint_data[] = {
.endpoint = {
.config = {
.resource_group = IPA_RSRC_GROUP_DST_UL_DL,
+ .checksum = true,
.qmap = true,
.aggregation = true,
.rx = {
--
2.48.1
^ permalink raw reply related [flat|nested] 10+ messages in thread* Re: [PATCH 3/3] net: ipa: Enable checksum for IPA_ENDPOINT_AP_MODEM_{RX,TX} for v4.7
2025-02-27 10:33 ` [PATCH 3/3] net: ipa: Enable checksum for IPA_ENDPOINT_AP_MODEM_{RX,TX} " Luca Weiss
@ 2025-03-04 16:50 ` Alex Elder
0 siblings, 0 replies; 10+ messages in thread
From: Alex Elder @ 2025-03-04 16:50 UTC (permalink / raw)
To: Luca Weiss, Alex Elder, Andrew Lunn, David S. Miller,
Eric Dumazet, Jakub Kicinski, Paolo Abeni
Cc: ~postmarketos/upstreaming, phone-devel, netdev, linux-kernel
On 2/27/25 4:33 AM, Luca Weiss wrote:
> Enable the checksum option for these two endpoints in order to allow
> mobile data to actually work. Without this, no packets seem to make it
> through the IPA.
>
> Fixes: b310de784bac ("net: ipa: add IPA v4.7 support")
> Signed-off-by: Luca Weiss <luca.weiss@fairphone.com>
This makes sense. The checksum option affects how outgoing
packets are formatted and incoming packets are interpreted
by the IPA hardware. So with this being wrong, I suppose
packets (one way and/or the other) might just be getting
dropped as invalid.
This looks good to me. I'm really pleased you were able to
get this working.
Reviewed-by: Alex Elder <elder@riscstar.com>
> ---
> drivers/net/ipa/data/ipa_data-v4.7.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/net/ipa/data/ipa_data-v4.7.c b/drivers/net/ipa/data/ipa_data-v4.7.c
> index e63dcf8d45567b0851393c2cea7a0d630afa20cd..41f212209993f10fee338e28027739a7402d5089 100644
> --- a/drivers/net/ipa/data/ipa_data-v4.7.c
> +++ b/drivers/net/ipa/data/ipa_data-v4.7.c
> @@ -104,6 +104,7 @@ static const struct ipa_gsi_endpoint_data ipa_gsi_endpoint_data[] = {
> .filter_support = true,
> .config = {
> .resource_group = IPA_RSRC_GROUP_SRC_UL_DL,
> + .checksum = true,
> .qmap = true,
> .status_enable = true,
> .tx = {
> @@ -127,6 +128,7 @@ static const struct ipa_gsi_endpoint_data ipa_gsi_endpoint_data[] = {
> .endpoint = {
> .config = {
> .resource_group = IPA_RSRC_GROUP_DST_UL_DL,
> + .checksum = true,
> .qmap = true,
> .aggregation = true,
> .rx = {
>
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH 0/3] Fixes for IPA v4.7
2025-02-27 10:33 [PATCH 0/3] Fixes for IPA v4.7 Luca Weiss
` (2 preceding siblings ...)
2025-02-27 10:33 ` [PATCH 3/3] net: ipa: Enable checksum for IPA_ENDPOINT_AP_MODEM_{RX,TX} " Luca Weiss
@ 2025-02-28 22:52 ` Jakub Kicinski
2025-03-02 18:52 ` Alex Elder
2025-03-05 0:30 ` patchwork-bot+netdevbpf
4 siblings, 1 reply; 10+ messages in thread
From: Jakub Kicinski @ 2025-02-28 22:52 UTC (permalink / raw)
To: Alex Elder
Cc: Luca Weiss, Andrew Lunn, David S. Miller, Eric Dumazet,
Paolo Abeni, phone-devel, netdev, linux-kernel
On Thu, 27 Feb 2025 11:33:39 +0100 Luca Weiss wrote:
> couldn't be tested much back then due to missing features in tqftpserv
> which caused the modem to not enable correctly.
>
> Especially the last commit is important since it makes mobile data
> actually functional on SoCs with IPA v4.7 like SM6350 - used on the
> Fairphone 4. Before that, you'd get an IP address on the interface but
> then e.g. ping never got any response back.
Hi Alex, would you be able to review this?
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: [PATCH 0/3] Fixes for IPA v4.7
2025-02-28 22:52 ` [PATCH 0/3] Fixes for IPA v4.7 Jakub Kicinski
@ 2025-03-02 18:52 ` Alex Elder
0 siblings, 0 replies; 10+ messages in thread
From: Alex Elder @ 2025-03-02 18:52 UTC (permalink / raw)
To: Jakub Kicinski, Alex Elder
Cc: Luca Weiss, Andrew Lunn, David S. Miller, Eric Dumazet,
Paolo Abeni, phone-devel, netdev, linux-kernel
On 2/28/25 4:52 PM, Jakub Kicinski wrote:
> On Thu, 27 Feb 2025 11:33:39 +0100 Luca Weiss wrote:
>> couldn't be tested much back then due to missing features in tqftpserv
>> which caused the modem to not enable correctly.
>>
>> Especially the last commit is important since it makes mobile data
>> actually functional on SoCs with IPA v4.7 like SM6350 - used on the
>> Fairphone 4. Before that, you'd get an IP address on the interface but
>> then e.g. ping never got any response back.
>
> Hi Alex, would you be able to review this?
Yes I will. Sorry, I've been sick this week. I'm
feeling better now.
-Alex
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH 0/3] Fixes for IPA v4.7
2025-02-27 10:33 [PATCH 0/3] Fixes for IPA v4.7 Luca Weiss
` (3 preceding siblings ...)
2025-02-28 22:52 ` [PATCH 0/3] Fixes for IPA v4.7 Jakub Kicinski
@ 2025-03-05 0:30 ` patchwork-bot+netdevbpf
4 siblings, 0 replies; 10+ messages in thread
From: patchwork-bot+netdevbpf @ 2025-03-05 0:30 UTC (permalink / raw)
To: Luca Weiss
Cc: elder, andrew+netdev, davem, edumazet, kuba, pabeni,
~postmarketos/upstreaming, phone-devel, netdev, linux-kernel
Hello:
This series was applied to netdev/net.git (main)
by Jakub Kicinski <kuba@kernel.org>:
On Thu, 27 Feb 2025 11:33:39 +0100 you wrote:
> During bringup of IPA v4.7 unfortunately some bits were missed, and it
> couldn't be tested much back then due to missing features in tqftpserv
> which caused the modem to not enable correctly.
>
> Especially the last commit is important since it makes mobile data
> actually functional on SoCs with IPA v4.7 like SM6350 - used on the
> Fairphone 4. Before that, you'd get an IP address on the interface but
> then e.g. ping never got any response back.
>
> [...]
Here is the summary with links:
- [1/3] net: ipa: Fix v4.7 resource group names
https://git.kernel.org/netdev/net/c/5eb3dc1396aa
- [2/3] net: ipa: Fix QSB data for v4.7
https://git.kernel.org/netdev/net/c/6a2843aaf551
- [3/3] net: ipa: Enable checksum for IPA_ENDPOINT_AP_MODEM_{RX,TX} for v4.7
https://git.kernel.org/netdev/net/c/934e69669e32
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] 10+ messages in thread