From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f66.google.com (mail-wm0-f66.google.com [74.125.82.66]) by dpdk.org (Postfix) with ESMTP id 3C0531B7A9 for ; Tue, 15 May 2018 15:49:42 +0200 (CEST) Received: by mail-wm0-f66.google.com with SMTP id a8-v6so1149896wmg.5 for ; Tue, 15 May 2018 06:49:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=krXX+hlFoqmJhTGnBueutpdqBt2ZUEPdDUW733Sru1Y=; b=R1uWrhQyexHatcaLdyr1R6yyMfNy1BF+j4o/dgvyTOK2oMtbu3CtPAQvZFHS3Q/HJ3 e3e/Q/hL1p4+B/Np7OnDv28eIw/wgyjQYeZdsZT8RXLNTDLGr8AF3r4ILICbYJcSP6Hp 7Ja0PLaTF9Rsok/fi/h3c7MeKLTEphUCoexeenPYHi/TBarhI1Nj0R7+smLQACnLDT36 vHEbibqxZDyxGwEaW21kXb6Eq+30uKPTprclIxQxkwi6VdZXHEW+d9+bfR5O/CoJw2vK z3wjl8N7GrBrAB1DwmNnRPBqH/64I5jkmdluhnmIOUMBpo4Kasg2z1IBRUWfKEuTRztO ahag== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=krXX+hlFoqmJhTGnBueutpdqBt2ZUEPdDUW733Sru1Y=; b=Tg1lSvpZf64VdltR7qGY4UCFbMZRGhURnOawjFGETmRt7vQxE1FswStDQLLEVverpx McMaWGVapaSb7EeFZx4b/OPTmSdMjMh64xZBDhEa3FeyMBZbGDzBUG0JGTrM6pywKLSm RpMBUNyV74kI+ThHZjaaiEXBTjXDjEbglgkveO3GtRlPeIMhorObmxQgPX/VaMYx89jO VzwqY29Cgd9zxb0ZZMVmKUhzYhP18DBVp7S1qCLQ4DiZ0RNVD3llieU2a9P9l3uBJvPo 7hnoJJQ1OlvhFqaJHiu8/edsgGS/kh1NAgiNsOX21om+kbZxnAbgTM4Ybt22DAJgHzBO GlVQ== X-Gm-Message-State: ALKqPwdloSeS31D0YWX67hnkz6kHdrhVJ+po9hVivcCj8vqBLpV4msJt 7nun5Uj9fjy8oViIeHQjMnk= X-Google-Smtp-Source: AB8JxZqjQWbB0aXfUfCI8CGQAgfnpQ0BhT+Di6PlgKB++Irdxjha32ItZBEa5lr+0+s9dyT8JhQAsg== X-Received: by 2002:a1c:5d4f:: with SMTP id r76-v6mr8528726wmb.93.1526392181949; Tue, 15 May 2018 06:49:41 -0700 (PDT) Received: from localhost (slip139-92-244-193.lon.uk.prserv.net. [139.92.244.193]) by smtp.gmail.com with ESMTPSA id q194-v6sm742636wmd.26.2018.05.15.06.49.40 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 15 May 2018 06:49:41 -0700 (PDT) From: luca.boccassi@gmail.com To: Yongseok Koh Cc: Xueming Li , dpdk stable Date: Tue, 15 May 2018 14:47:23 +0100 Message-Id: <20180515134731.9337-72-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.14.2 In-Reply-To: <20180515134731.9337-1-luca.boccassi@gmail.com> References: <20180503110612.12146-2-luca.boccassi@gmail.com> <20180515134731.9337-1-luca.boccassi@gmail.com> Subject: [dpdk-stable] patch 'net/mlx5: fix inlining segmented TSO packet' has been queued to stable release 18.02.2 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 15 May 2018 13:49:42 -0000 Hi, FYI, your patch has been queued to stable release 18.02.2 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 05/16/18. So please shout if anyone has objections. Thanks. Luca Boccassi --- >>From 9fd363e3c37aafb7e45367049c381e711f880479 Mon Sep 17 00:00:00 2001 From: Yongseok Koh Date: Fri, 11 May 2018 10:39:13 -0700 Subject: [PATCH] net/mlx5: fix inlining segmented TSO packet [ upstream commit 5f44cfd011478bcf00430c53f276ddf9b795d443 ] When a multi-segmented packet is inlined, data can be further inlined even after the first segment. In case of TSO packet, extra inline data after TSO header should be carried by an inline DSEG which has 4B inline header recording the length of the inline data. If more than one segment is inlined, the length doesn't count from the second segment. This will cause a fault in HW and CQE will have an error, which is ignored by PMD. Fixes: f895536be4fa ("net/mlx5: enable inlining data from multiple segments") Signed-off-by: Xueming Li Signed-off-by: Yongseok Koh --- drivers/net/mlx5/mlx5_rxtx.c | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/drivers/net/mlx5/mlx5_rxtx.c b/drivers/net/mlx5/mlx5_rxtx.c index 11dd1b84e..b99fc9038 100644 --- a/drivers/net/mlx5/mlx5_rxtx.c +++ b/drivers/net/mlx5/mlx5_rxtx.c @@ -507,7 +507,8 @@ pkt_inline: if (unlikely(max_wqe < n)) break; max_wqe -= n; - if (tso && !inl) { + if (tso) { + assert(inl == 0); inl = rte_cpu_to_be_32(copy_b | MLX5_INLINE_SEG); rte_memcpy((void *)raw, @@ -542,8 +543,17 @@ pkt_inline: } else if (!segs_n) { goto next_pkt; } else { - raw += copy_b; - inline_room -= copy_b; + /* + * Further inline the next segment only for + * non-TSO packets. + */ + if (!tso) { + raw += copy_b; + inline_room -= copy_b; + } else { + inline_room = 0; + } + /* Move to the next segment. */ --segs_n; buf = buf->next; assert(buf); -- 2.14.2