Skip to contentSkip to conversation

ibmvnic: skip send_request_unmap for timeout reset

PATCH Applied Lijun Pan 2 participants 2 messages Feb 13, 2021 – Feb 15, 2021

Subsystems (4)
lore
Share & tools
lore

Lijun Pan

author
#0 lore raw

PATCH 1/1 ibmvnic: skip send_request_unmap for timeout reset

Timeout reset will trigger the VIOS to unmap it automatically, similarly as FAILVOER and MOBILITY events. If we unmap it in the linux side, we will see errors like "30000003: Error 4 in REQUEST_UNMAP_RSP".
So, don't call send_request_unmap for timeout reset.

Fixes ed651a10875f ("ibmvnic: Updated reset handling")
---
 drivers/net/ethernet/ibm/ibmvnic.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
drivers/net/ethernet/ibm/ibmvnic.c +6 -1
index 621be6d2da97..c8b0d99608d5 100644
@@ -247,8 +247,13 @@ static void free_long_term_buff(struct ibmvnic_adapter *adapter,
 	if (!ltb->buff)
 		return;
 
+	/* VIOS automatically unmaps the long term buffer at remote
+	 * end for the following resets:
+	 * FAILOVER, MOBILITY, TIMEOUT.
+	 */
 	if (adapter->reset_reason != VNIC_RESET_FAILOVER &&
-	    adapter->reset_reason != VNIC_RESET_MOBILITY)
+	    adapter->reset_reason != VNIC_RESET_MOBILITY &&
+	    adapter->reset_reason != VNIC_RESET_TIMEOUT)
 		send_request_unmap(adapter, ltb->map_id);
 	dma_free_coherent(dev, ltb->size, ltb->buff, ltb->addr);
 }
Signature · 1 line
2.23.0
#1 lore raw
This patch was applied to netdev/net.git (refs/heads/master):

Hello:

This patch was applied to netdev/net.git (refs/heads/master):

Quoted 10 lines · On Fri, 12 Feb 2021 20:49:00 -0600 you wrote:

Timeout reset will trigger the VIOS to unmap it automatically, similarly as FAILVOER and MOBILITY events. If we unmap it in the linux side, we will see errors like "30000003: Error 4 in REQUEST_UNMAP_RSP".
So, don't call send_request_unmap for timeout reset.

Fixes ed651a10875f ("ibmvnic: Updated reset handling")

[...]

Here is the summary with links:
- [net] ibmvnic: skip send_request_unmap for timeout reset

    https://git.kernel.org/netdev/net/c/7d3a7b9ea59d

You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html