From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 85B41A0093; Tue, 3 May 2022 08:10:26 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2CCD140691; Tue, 3 May 2022 08:10:26 +0200 (CEST) Received: from mail-io1-f49.google.com (mail-io1-f49.google.com [209.85.166.49]) by mails.dpdk.org (Postfix) with ESMTP id 58BB84068F; Tue, 3 May 2022 08:10:24 +0200 (CEST) Received: by mail-io1-f49.google.com with SMTP id e3so14314404ios.6; Mon, 02 May 2022 23:10:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=TjsnthZcmf9tFHypj90SOKAj/c7oZzwrGoxxqO/1zjI=; b=X4MfqvHaIniEbgA/x7Q4Ipv6bGdLzLRPv3c4EEggr8yoO5kBbETNf2odntROElRQwX zczSAmmEbssHtey/YVEikO481wFckTs1C7I4jHRCnAIx7czR5+eLdKxq6wHFiVKxI/T6 YJq/UvS8CUWWPyEaa/eEE49PfPRTPKre8grVfz6k3618HNeL5YVDygyNOgaXJ+G+3reJ 5YJ3/Ks6SrbaB8TjRa7sK6rahfbjdH6flu4J+/1PS6biIePLugV0yQ3V0v4cAj25gVnH m1QL9XFyFSHTpYMG8mHZFyd5gxobczejn7nOB6NleajmRckNV0a+jY2JQ31a5P1MQr2r XqIA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=TjsnthZcmf9tFHypj90SOKAj/c7oZzwrGoxxqO/1zjI=; b=ebou3bEexpsO4DoqOxWxutDhqaCkSBuUJgyIOnG4HsueciVoOdoF/AfESQXSi55HFG K2vRrKsMSfUhAQymBHWFzMg2sOwt5/71A1KR3z+IM/0cWwPmStMG5RyyZNXT6A5laN4N FqPeuitaPGuR9dgdmV2m7EGcREG1/MQ4zdMju09aeme1OJjQ5AlBqDKpajqs75tO633W Lv6Oiga6F3/BRFw6J3QpE/qSoTQP16hiFqdgOVZLZnqc2w2VKpfpyR86mLCFLbexGEk7 KrhNCQ6uY6imdgHm7EhVAy0DQ8tiRs6H374e3AaNUdaF6DdxKZFdm+dv7DaPcJ9Ppj8r +t5w== X-Gm-Message-State: AOAM532lZOyPK/MAfOrkYcQfazCGDFv5nrnkzPxRCKmMQVEMLiiBDBRH r62fWgJjZVvtE1dUQANzlCOOmIMJiFTgrE/UTOw= X-Google-Smtp-Source: ABdhPJwy+clYOdhGpu3FH8gflVmRhtY9Cy4cEYBeMdxWhs2LtPjsoEPh8PW7sBkgZsZQcDoqZWVC/geGDj8r1RCkwYg= X-Received: by 2002:a05:6638:150e:b0:32b:3a56:1681 with SMTP id b14-20020a056638150e00b0032b3a561681mr6246676jat.280.1651558223347; Mon, 02 May 2022 23:10:23 -0700 (PDT) MIME-Version: 1.0 References: <20220419063438.269086-1-psatheesh@marvell.com> In-Reply-To: <20220419063438.269086-1-psatheesh@marvell.com> From: Jerin Jacob Date: Tue, 3 May 2022 11:39:57 +0530 Message-ID: Subject: Re: [dpdk-dev] [PATCH] net/cnxk: fix error message setting on failure To: Satheesh Paul , Ferruh Yigit , Andrew Rybchenko Cc: Nithin Dabilpuram , Kiran Kumar K , Sunil Kumar Kori , Satha Rao , dpdk-dev , dpdk stable Content-Type: text/plain; charset="UTF-8" X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org On Tue, Apr 19, 2022 at 12:04 PM wrote: > > From: Satheesh Paul > > Set the error message with rte_flow_error_set() api > when flow parsing fails. > > Fixes: 8c009b4505e ("net/cnxk: support flow API") > Cc: stable@dpdk.org > > Signed-off-by: Satheesh Paul > Reviewed-by: Kiran Kumar Kokkilagadda Applied to dpdk-next-net-mrvl/for-next-net. Thanks > --- > drivers/net/cnxk/cnxk_flow.c | 9 ++++++++- > 1 file changed, 8 insertions(+), 1 deletion(-) > > diff --git a/drivers/net/cnxk/cnxk_flow.c b/drivers/net/cnxk/cnxk_flow.c > index 8763ca63d6..2b13352312 100644 > --- a/drivers/net/cnxk/cnxk_flow.c > +++ b/drivers/net/cnxk/cnxk_flow.c > @@ -297,7 +297,14 @@ cnxk_flow_validate(struct rte_eth_dev *eth_dev, > return rc; > } > > - return roc_npc_flow_parse(npc, &in_attr, in_pattern, in_actions, &flow); > + rc = roc_npc_flow_parse(npc, &in_attr, in_pattern, in_actions, &flow); > + > + if (rc) { > + rte_flow_error_set(error, 0, rc, NULL, > + "Flow validation failed"); > + return rc; > + } > + return 0; > } > > struct roc_npc_flow * > -- > 2.25.4 >