From patchwork Tue Jul 7 09:22:17 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hemant Agrawal X-Patchwork-Id: 234956 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp735764ilg; Tue, 7 Jul 2020 02:27:27 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxJmuakZwHGNi5XI6AWBBkFDE/PwmzPifmYFld+blh22bO4F1nsMNpEev+XOSHz6IelBEN2 X-Received: by 2002:aa7:d4ca:: with SMTP id t10mr60372828edr.244.1594114046878; Tue, 07 Jul 2020 02:27:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1594114046; cv=none; d=google.com; s=arc-20160816; b=E8/Dg/TMGmCSGEdbzTyKsyCASSd1mpPcWxD/rEhF7rCGgDJhGN4jGmligg1mJrXwaG DY5MP3WatPiBcK9JoZOuJ3b8lK3FsOvG1A/H4gyPRgW4lVLK8noYsrZd+NdEQxgg1amK fGY9x2js0TJmYkc0VLoyQOwuTWGViTxJhe/wh583gXF6O/W3hm8FvXgpyPH069UaOS5N yQIuCK4831PSsoS1SmxEao4WmvM6DYrCqq5KJLKzrrvL0ho2VglN23kw1zi3YC8/D29F D53+O9vIURoOmcewQ+ghAOea7Ptn7OxzjTPFdEuiQhTNJ1aj3HGagJEYK06sKe+qwhuw f6GQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject:references:in-reply-to :message-id:date:cc:to:from; bh=w14Z71Q3irEPpMi6ftRvemLlzkmPReiEHFUZTubg7ec=; b=mw155oofCiG5VwnznUPBdfhrh4s/CoRn22g3kzlD4NuEP8Q36uOiDc2ZgquecwluoQ fP5Z6tRO6WqI8VcCYBmilO3qlgi6QHoHiNatT/MOiNoaTWbhRAN+ShNNdrbvg4ghzfYu FYB/cshglDgGM4EkAmoYqy0goRmfKp1EngHv26r+mrBqveTCKwyf6m8x2WIX5BUe7ObH zlAANco1lrO/XaxU1YtNPWV5wOpi+d+jX2hEl88PQozJ5/wnhw89Asi+zxMf8VvUEZ2L uN6nXpv4Cn2wqbA0LKfSlTj7UzBpK5VHoFdHv3KwTiApTfilXV4Yu6iH4npWkcdvljgS d8PA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) smtp.mailfrom=dev-bounces@dpdk.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from dpdk.org (dpdk.org. [92.243.14.124]) by mx.google.com with ESMTP id b11si9647627edy.539.2020.07.07.02.27.26; Tue, 07 Jul 2020 02:27:26 -0700 (PDT) Received-SPF: pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) client-ip=92.243.14.124; Authentication-Results: mx.google.com; spf=pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) smtp.mailfrom=dev-bounces@dpdk.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 0A6411DC7E; Tue, 7 Jul 2020 11:27:03 +0200 (CEST) Received: from inva020.nxp.com (inva020.nxp.com [92.121.34.13]) by dpdk.org (Postfix) with ESMTP id 329A81DC0C; Tue, 7 Jul 2020 11:26:59 +0200 (CEST) Received: from inva020.nxp.com (localhost [127.0.0.1]) by inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id EE8DF1A0A57; Tue, 7 Jul 2020 11:26:58 +0200 (CEST) Received: from invc005.ap-rdc01.nxp.com (invc005.ap-rdc01.nxp.com [165.114.16.14]) by inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id DB95C1A0A30; Tue, 7 Jul 2020 11:26:56 +0200 (CEST) Received: from bf-netperf1.ap.freescale.net (bf-netperf1.ap.freescale.net [10.232.133.63]) by invc005.ap-rdc01.nxp.com (Postfix) with ESMTP id C028F402F7; Tue, 7 Jul 2020 17:26:53 +0800 (SGT) From: Hemant Agrawal To: dev@dpdk.org Cc: ferruh.yigit@intel.com, stable@dpdk.org, Nipun Gupta Date: Tue, 7 Jul 2020 14:52:17 +0530 Message-Id: <20200707092244.12791-3-hemant.agrawal@nxp.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200707092244.12791-1-hemant.agrawal@nxp.com> References: <20200527132326.1382-1-hemant.agrawal@nxp.com> <20200707092244.12791-1-hemant.agrawal@nxp.com> X-Virus-Scanned: ClamAV using ClamSMTP Subject: [dpdk-dev] [PATCH v2 02/29] net/dpaa: fix fd offset data type X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" From: Nipun Gupta On DPAA fd offset is 9 bits, but we are using uint8_t in the SG case. This patch fixes the same. Fixes: 8cffdcbe85aa ("net/dpaa: support scattered Rx") Cc: stable@dpdk.org Signed-off-by: Nipun Gupta Acked-by: Akhil Goyal --- drivers/net/dpaa/dpaa_rxtx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.17.1 diff --git a/drivers/net/dpaa/dpaa_rxtx.c b/drivers/net/dpaa/dpaa_rxtx.c index 5dba1db8b..3aeecb7d2 100644 --- a/drivers/net/dpaa/dpaa_rxtx.c +++ b/drivers/net/dpaa/dpaa_rxtx.c @@ -305,7 +305,7 @@ dpaa_eth_sg_to_mbuf(const struct qm_fd *fd, uint32_t ifid) struct qm_sg_entry *sgt, *sg_temp; void *vaddr, *sg_vaddr; int i = 0; - uint8_t fd_offset = fd->offset; + uint16_t fd_offset = fd->offset; vaddr = DPAA_MEMPOOL_PTOV(bp_info, qm_fd_addr(fd)); if (!vaddr) {