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 E59BBA04C1; Wed, 20 Nov 2019 06:02:10 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 24E392E8F; Wed, 20 Nov 2019 06:02:10 +0100 (CET) Received: from mail-ot1-f67.google.com (mail-ot1-f67.google.com [209.85.210.67]) by dpdk.org (Postfix) with ESMTP id 0DF5B2C23 for ; Wed, 20 Nov 2019 06:02:08 +0100 (CET) Received: by mail-ot1-f67.google.com with SMTP id w24so19644220otk.6 for ; Tue, 19 Nov 2019 21:02:07 -0800 (PST) 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=7CzlTzhj8L2Mh5NpbiS2EH7opyYJOOKRGEDA9+MhWmM=; b=bbEJnRwcF1G6ZdBRtOZ4lVH4P0ICoiiDq/yKFO4dIugcpzXAjSQ1jOT8PIwmVrdHV6 748ywfMVG50TlsnF0A695vCwygu8xiCgydcysUwHyGIeSpkU7VP2uMGHCVHkrb2XLyXO MeuDFzU5Fh8N1ReIOPEsCCSlFIrO0vpGqf08E= 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=7CzlTzhj8L2Mh5NpbiS2EH7opyYJOOKRGEDA9+MhWmM=; b=k+qLfppqV/JjMJ8lqQhdcBkw34x38Dk5GPc0grBu+KN58dkGtPY0Ns7awTsCyMvzCH 2nAVBGootzeoc8tM/DEmy0bYqRgypX8E+L/jaOj3I77XSo6Y6WKB8C8ISXWOgUuglDok KdKsPk49HAzuZ9YsVhfJJXYxOPyu/3h2r88K63WH1Llx0rxpVlUNmDlgkFibeEyu3wxd ZDe8dDYK/j9pHNPAba3D9+2mSc+oXbDhdhAytm8JpXFuLidm7M3s4lODQL6mM+izsKwf 0Jw7WIaj8zve4+dvSpD2XSWBQHJ7fnkTLUd+OtlmLXZEiGv+ZMLgsL+n7qO1uLqlYjwl I8PA== X-Gm-Message-State: APjAAAVf+v2vgr85hJFVb25kuUu8lbtO0aUhC45hxUcdvrUI/P/pO/4b QLsW7oudguTvZAqu0jc1v+vXEFOBncRwDBzL6qiP1d+HoBY= X-Google-Smtp-Source: APXvYqzab3IFkLDygNdAwrgONCAvu2pMhCqQ/gjkzVZ0p6aVDRi6G3GhrPyj1YEvOqgKTTA07IFGgY4WNSMOIchogZk= X-Received: by 2002:a9d:7cd8:: with SMTP id r24mr451321otn.95.1574226126819; Tue, 19 Nov 2019 21:02:06 -0800 (PST) MIME-Version: 1.0 References: <20191120042907.1030-1-ajit.khaparde@broadcom.com> <20191120042907.1030-2-ajit.khaparde@broadcom.com> In-Reply-To: <20191120042907.1030-2-ajit.khaparde@broadcom.com> From: Ajit Khaparde Date: Tue, 19 Nov 2019 21:01:50 -0800 Message-ID: To: dpdk-dev Cc: Ferruh Yigit , Santoshkumar Karanappa Rastapur , Somnath Kotur Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-dev] [PATCH 2/2] net/bnxt: fix check for null spec and mask 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 Tue, Nov 19, 2019 at 8:29 PM Ajit Khaparde wrote: > bnxt_validate_and_parse_flow_type already has protocol specific NULL > checks for rte_flow_item spec and mask and take actions accordingly. > A check at the top of the loop is redundant and is preventing the > protocol specific checks from being executed. > > Fixes: b7e01f386059 ("net/bnxt: handle cleanup if flow creation fails") > > Signed-off-by: Ajit Khaparde > Reviewed-by: Santoshkumar Karanappa Rastapur < > santosh.rastapur@broadcom.com> > Reviewed-by: Somnath Kotur > Patch applied to dpdk-next-net-brcm. > --- > drivers/net/bnxt/bnxt_flow.c | 8 -------- > 1 file changed, 8 deletions(-) > > diff --git a/drivers/net/bnxt/bnxt_flow.c b/drivers/net/bnxt/bnxt_flow.c > index 5af571448..76e9584da 100644 > --- a/drivers/net/bnxt/bnxt_flow.c > +++ b/drivers/net/bnxt/bnxt_flow.c > @@ -177,14 +177,6 @@ bnxt_validate_and_parse_flow_type(struct bnxt *bp, > return -rte_errno; > } > > - if (!item->spec || !item->mask) { > - rte_flow_error_set(error, EINVAL, > - RTE_FLOW_ERROR_TYPE_ITEM, > - item, > - "spec/mask is NULL"); > - return -rte_errno; > - } > - > switch (item->type) { > case RTE_FLOW_ITEM_TYPE_ANY: > inner = > -- > 2.21.0 (Apple Git-122.2) > >