From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 594D4A04AE; Tue, 5 May 2020 05:42:40 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 8E85D1D534; Tue, 5 May 2020 05:42:39 +0200 (CEST) Received: from mail-ot1-f65.google.com (mail-ot1-f65.google.com [209.85.210.65]) by dpdk.org (Postfix) with ESMTP id 9AE3A1BEC4 for ; Tue, 5 May 2020 05:42:37 +0200 (CEST) Received: by mail-ot1-f65.google.com with SMTP id 72so555441otu.1 for ; Mon, 04 May 2020 20:42:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Og3cBvRMUAUc1ZzyeAjcCGzjjmhDgBAf6oWioic/U2I=; b=KB3M13abwtgCP0CLp5yzplGCH+joInQS1LEQxH7SfULsflgYQfx73628L3lhh4x4eH n/SYJ84Yv3LaRESrlywxYyJYl5s5gf/hsaG1BZulyeen0NsUUh6r8FIpZJiRAQ9Qb8Uw 2ST2P52mLCZdfLIGOSBNT2+qyPzzFG67xKDAQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Og3cBvRMUAUc1ZzyeAjcCGzjjmhDgBAf6oWioic/U2I=; b=ECC/YR416NishRzn6OnAdmI0mZYqy0daf1NcVy+AUcb983L4XJACZbEfHPoPaG/5Tu bVnXYu/erVFITsaRIB/R074BFh2b2wzUZgBbfan1czDzYuDmht1vuYbz8Nt5JYDao1RI MtDbpDM073jleJbwf59HyZWirEgTKTp6bASl6+grfaxP62Q0T3npozMQFmPXPTb8v0ld m+OlcPXtJVGbdcA/gQWZ5FndzC/pBcoVbLTg4lSPis8NppbsiXEuP03b5lM+WbSwOHqu AhfTV1nwYlyXI9oW6xDV9IcY4JFI04U6uzzxNmRbBhuIDYSjj7SSl9elM3pQsCp9WYuA N6Ng== X-Gm-Message-State: AGi0PuZTGm1I681a9v5kQL2WzRh2NYVNqamyB0Z8qyt8V+5shUQ0uK0K 4UEF1kk7QH1wk2XkSupYRR8X331gYl/UkKtmYQI8pw== X-Google-Smtp-Source: APiQypId2XmL/JTnDogjb/0dF636SM7uCqvfF1mnsVp/QIQt/CavxKwEFJOYGjqqTTpprynxfsmFdbN2ckdmEMr7pzA= X-Received: by 2002:a05:6830:1613:: with SMTP id g19mr626670otr.95.1588650156622; Mon, 04 May 2020 20:42:36 -0700 (PDT) MIME-Version: 1.0 References: <1588253872-19024-1-git-send-email-yuanlinsi01@baidu.com> <9171fcaf-8ffb-47e7-621e-9f4066cf8e1d@intel.com> In-Reply-To: <9171fcaf-8ffb-47e7-621e-9f4066cf8e1d@intel.com> From: Ajit Khaparde Date: Mon, 4 May 2020 20:42:20 -0700 Message-ID: To: Ferruh Yigit Cc: Yuan Linsi , Somnath Kotur , Lance Richardson , dpdk-dev Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-dev] [PATCH] net/bnxt: fix a possible stack smashing 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" On Thu, Apr 30, 2020 at 4:55 PM Ferruh Yigit wrote: > On 4/30/2020 2:37 PM, Yuan Linsi wrote: > > From: yuanlinsi01 > > > > We see a stack smashing as a result of defensive code missing. Once the > > nb_pkts is less than RTE_BNXT_DESCS_PER_LOOP, it will be modified to > > zero after doing a floor align, and we can not exit the following > > receiving packets loop. And the buffers will be overwrite, then the > > stack frame was ruined. > > > > Fix the problem by adding defensive code, once the nb_pkts is zero, just > > directly return with no packets. > > > > Fixes: bc4a000f2 ("net/bnxt: implement SSE vector mode") > > Cc: stable@dpdk.org > > > > Signed-off-by: yuanlinsi01 > > Signed-off-by: rongdongsheng > > Hi Yuan, > > For the sign-off tag, we need "Name Surname " syntax, > for you I can see from mail thread that it is: > "Signed-off-by: Linsi Yuan " > > Can you please share the same for the other sign-off, 'rongdongsheng'? > Yuan, Can you please send the proper first-name, last-name for rongdongsheng? Thanks