From: DENG Qingfang Date: Sat, 17 Apr 2021 07:29:04 +0000 (+0800) Subject: net: ethernet: mediatek: fix a typo bug in flow offloading X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=6ecaf81d4ac6365f9284f9d68d74f7c209e74f98;p=linux.git net: ethernet: mediatek: fix a typo bug in flow offloading Issue was traffic problems after a while with increased ping times if flow offload is active. It turns out that key_offset with cookie is needed in rhashtable_params but was re-assigned to head_offset. Fix the assignment. Fixes: 502e84e2382d ("net: ethernet: mtk_eth_soc: add flow offloading support") Signed-off-by: DENG Qingfang Tested-by: Frank Wunderlich Signed-off-by: David S. Miller --- diff --git a/drivers/net/ethernet/mediatek/mtk_ppe_offload.c b/drivers/net/ethernet/mediatek/mtk_ppe_offload.c index 4975106fbc424..f47f319f3ae08 100644 --- a/drivers/net/ethernet/mediatek/mtk_ppe_offload.c +++ b/drivers/net/ethernet/mediatek/mtk_ppe_offload.c @@ -43,7 +43,7 @@ struct mtk_flow_entry { static const struct rhashtable_params mtk_flow_ht_params = { .head_offset = offsetof(struct mtk_flow_entry, node), - .head_offset = offsetof(struct mtk_flow_entry, cookie), + .key_offset = offsetof(struct mtk_flow_entry, cookie), .key_len = sizeof(unsigned long), .automatic_shrinking = true, };