msm: ipa3: set HOLB on eth-tx when getting disconnect

Seeing IPA HW-stall with eth cable plug-out due to
eth-client was not able to drain out the pkts, made
the change to enable holb drops on eth-tx pipes when
getting eth_client_disconn_pipes from eth-driver.

Change-Id: Ifc795435e011f78f426c8db0e1d3ca3e0e74e806
Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
Šī revīzija ir iekļauta:
Skylar Chang
2021-05-21 05:12:55 -07:00
revīziju iesūtīja Gerrit - the friendly Code Review server
vecāks f115ffef7a
revīzija 505dfdefed
2 mainīti faili ar 18 papildinājumiem un 2 dzēšanām

Parādīt failu

@@ -682,6 +682,7 @@ static int ipa_eth_client_disconn_pipes_internal(struct ipa_eth_client *client)
{ {
int rc; int rc;
struct ipa_eth_client_pipe_info *pipe; struct ipa_eth_client_pipe_info *pipe;
struct ipa_ep_cfg_holb holb;
/* validate user input */ /* validate user input */
if (!client) { if (!client) {
@@ -702,6 +703,21 @@ static int ipa_eth_client_disconn_pipes_internal(struct ipa_eth_client *client)
client->client_type, client->inst_id, client->client_type, client->inst_id,
client->traffic_type); client->traffic_type);
mutex_lock(&ipa_eth_ctx->lock); mutex_lock(&ipa_eth_ctx->lock);
/* set holb on tx pipes first */
list_for_each_entry(pipe, &client->pipe_list,
link) {
if (pipe->dir == IPA_ETH_PIPE_DIR_TX)
{
IPA_ETH_DBG("Set holb on pipe = %d, pipe->dir = %d \n",
ipa_get_ep_mapping(ipa_eth_get_ipa_client_type_from_pipe(pipe)),
pipe->dir);
holb.en = 1;
holb.tmr_val = 0;
ipa3_cfg_ep_holb(ipa_get_ep_mapping(ipa_eth_get_ipa_client_type_from_pipe(pipe)), &holb);
}
}
list_for_each_entry(pipe, &client->pipe_list, list_for_each_entry(pipe, &client->pipe_list,
link) { link) {
rc = ipa_eth_client_disconnect_pipe(pipe); rc = ipa_eth_client_disconnect_pipe(pipe);

Parādīt failu

@@ -455,7 +455,7 @@ int ipahal_nat_is_entry_zeroed(enum ipahal_nat_type nat_type, void *entry,
"requested NAT type %d is invalid\n", nat_type)) "requested NAT type %d is invalid\n", nat_type))
return -EINVAL; return -EINVAL;
IPAHAL_DBG("Determine whether the entry is zeroed for NAT type=%s\n", IPAHAL_DBG_LOW("Determine whether the entry is zeroed for NAT type=%s\n",
ipahal_nat_type_str(nat_type)); ipahal_nat_type_str(nat_type));
nat_ptr = nat_ptr =
@@ -463,7 +463,7 @@ int ipahal_nat_is_entry_zeroed(enum ipahal_nat_type nat_type, void *entry,
*entry_zeroed = nat_ptr->is_entry_zeroed(entry); *entry_zeroed = nat_ptr->is_entry_zeroed(entry);
IPAHAL_DBG("The entry is %szeroed\n", (*entry_zeroed) ? "" : "not "); IPAHAL_DBG_LOW("The entry is %szeroed\n", (*entry_zeroed) ? "" : "not ");
return 0; return 0;
} }