Received: by 2002:a25:d7c1:0:0:0:0:0 with SMTP id o184csp872074ybg; Fri, 18 Oct 2019 08:36:16 -0700 (PDT) X-Google-Smtp-Source: APXvYqzd1X8cpjYc960dkoKlfG1358f/nlNUIhwgl8JcHJ44uxmodxlzecubLv4BcWtfSI+9kDw8 X-Received: by 2002:a17:906:c35a:: with SMTP id ci26mr8884809ejb.99.1571412976326; Fri, 18 Oct 2019 08:36:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1571412976; cv=none; d=google.com; s=arc-20160816; b=E5NnrLJeTz70M7cXPLaMGCL8DuHtoFKDf6GWSjnZ9fJOdgplcFPBPG/twbjbcGFZmF 2n8XUZF8KKqT9t06goRg4sHd+dne21r1lj+Pu8I/R+4U9PJz2E1WeyPgyGWbEZtv/yHU g+uLgGnqkVBoOcQ/sSeMqte0u6nKyXwPwBElsDQ1/TlMaFGwFmsfPFbiRB4WB8OJlMQ+ HPtS+HKkjR3VCz5nRG11P/bl0+8N/buoe2tMdXAi7oe0NieiQJQVJa/Yd7cBNMgE9ojv bzkcTETKZUGVxXIpPiN1cmvQVM/UGHpVNEF2GlPU/dIt/7gdFclQ/qh5MVodNRTAN/kJ aujg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:message-id:date:subject:cc :to:from; bh=31N+W2KAFzhXDNwfPhosUJNj3sf94ljPEWVUys7WRJM=; b=pYRSncwiIppsnn+yvk94O5cBi7j8/rggtcajnHlN9dPgcs4wN6ffMLrBO0FlgX5NNP 7GDzCVbZtyc3VLsYRvKU4mnrmq2BSvZPyczYNr1orJjjlEeBlZTK3YEYXGtVdVLAibPB xi4ZJ9Z//6M8UpOkE/AryH+2Ua90bShBEKKMxa/0ckBiGtwr6oDlpih7z7CWVbTZN93h eP0B9Zq+39EXML9BTK/goJMnguC/NmyFKZFZQTos/SiJjXxjlc+RSh8M1h8+0mc0Uz/4 OvGy5A1RZ63wddt6KVAA4qiruBYlVyPHlMCyS6GlvYeKypMRWhGDjEGa0Qq244tgaaNu ZEhQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v3si4023918edc.404.2019.10.18.08.35.52; Fri, 18 Oct 2019 08:36:16 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2391974AbfJQLCK (ORCPT + 99 others); Thu, 17 Oct 2019 07:02:10 -0400 Received: from szxga04-in.huawei.com ([45.249.212.190]:4201 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1728464AbfJQLCJ (ORCPT ); Thu, 17 Oct 2019 07:02:09 -0400 Received: from DGGEMS403-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id E76A0E8CD5B2E1654BFD; Thu, 17 Oct 2019 19:02:06 +0800 (CST) Received: from localhost.localdomain (10.67.212.132) by DGGEMS403-HUB.china.huawei.com (10.3.19.203) with Microsoft SMTP Server id 14.3.439.0; Thu, 17 Oct 2019 19:02:00 +0800 From: Shaokun Zhang To: , , , CC: yuqi jin , Giuseppe Cavallaro , Alexandre Torgue , "Jose Abreu" , "David S. Miller" , "Maxime Coquelin" , Shaokun Zhang Subject: [PATCH] net: stmmac: Fix the problem of tso_xmit Date: Thu, 17 Oct 2019 18:59:10 +0800 Message-ID: <1571309950-43543-1-git-send-email-zhangshaokun@hisilicon.com> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.67.212.132] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: yuqi jin When the address width of DMA is greater than 32, the packet header occupies a BD descriptor. The starting address of the data should be added to the header length. Cc: Giuseppe Cavallaro Cc: Alexandre Torgue Cc: Jose Abreu Cc: "David S. Miller" Cc: Maxime Coquelin Signed-off-by: yuqi jin Signed-off-by: Shaokun Zhang --- drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c index c76a1336a451..3e02e64c5fa0 100644 --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c @@ -2995,6 +2995,7 @@ static netdev_tx_t stmmac_tso_xmit(struct sk_buff *skb, struct net_device *dev) } else { stmmac_set_desc_addr(priv, first, des); tmp_pay_len = pay_len; + des += proto_hdr_len; } stmmac_tso_allocator(priv, des, tmp_pay_len, (nfrags == 0), queue); -- 2.7.4