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 53716A052A for ; Mon, 25 Jan 2021 19:24:26 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 3DDA814119E; Mon, 25 Jan 2021 19:24:25 +0100 (CET) Received: from mail-io1-f44.google.com (mail-io1-f44.google.com [209.85.166.44]) by mails.dpdk.org (Postfix) with ESMTP id 4E7F414118D; Mon, 25 Jan 2021 19:24:23 +0100 (CET) Received: by mail-io1-f44.google.com with SMTP id y19so28518320iov.2; Mon, 25 Jan 2021 10:24:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=HKjKIbRCSrIO6EDDxTgSxm73M8ZcmXOU1zNlewpwrRU=; b=kE1Lp4NTk+vBol1NJtxdrAz3txhLYTcgnxGtEdJdI/NGadYFOYfTu2c5Oy4dwSLtux a1fIytbfIndrtKHBH9o08Q3i8/rOq/ipwxs3d7JhEaHHrrJ6C4hyQFXpQ9eJbTyCcMYG xjrU/o4LGe1s3r7oGoxCA+l7C4I5cFy9ECynB6XJvZeM9oQZ9stX4jDWRdoY/U15LQvs 16975ob6TwbyAZg4ecLQf2uxO54bzMgwpFzEjEbHqf2SBPNvExi7vE8CMkvtYyqfqZD0 1borXjP56xPDAmurjgWCIVffvm9N5BMfAVemyrNsW1bnO+dMDUFUMPyPqwoj02zzDXVq lwlg== 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=HKjKIbRCSrIO6EDDxTgSxm73M8ZcmXOU1zNlewpwrRU=; b=fv3I200lfgwztLez0DtOrR+LSp/AVm+kDw9MrUfsPZZXv+lReHdHznYedLeibLSviH As6SVS0/EurIlOrumSOvVU8/NFra2wC/URoCcUAJDINW3CzmSOF0+lMLBuDRJuwW/Gt1 pg1yYEZbK0f+wrVNxOVDp/zlmY5XUpR8aaYVVUal6NAARZP5GIVmuPB4sl4sHC3xM588 PlRRSD8YRYdnKqjjpAKF80EdbXh/ieEiICboY0rx+J4oi0+v/UfhXiBFbixDWdzYbftE fdBbU8xhv+/GRKe7LEUK4hI4awFMNXXhTo4ixQcoNS4H9FvLWx3QVrs5welezM0IlWiT QTlg== X-Gm-Message-State: AOAM5326UeuTSS/mgH3uCb8TxBDkHOSdxpbp3KMkpwHYhEj+y/cFjWJB QtjOpZiTfymTkKZh3igaeyu1R65KANGtLtAouYw= X-Google-Smtp-Source: ABdhPJy1kAhy4R5SGbcZi2C62wN1ouQboNviou8aMpMEFynAuj+gAdDqCVtxhfuxr1i/fc/FFbH0qurdDBduaxlepqk= X-Received: by 2002:a92:1508:: with SMTP id v8mr1441954ilk.162.1611599062592; Mon, 25 Jan 2021 10:24:22 -0800 (PST) MIME-Version: 1.0 References: <20210118105031.474-1-lironh@marvell.com> In-Reply-To: <20210118105031.474-1-lironh@marvell.com> From: Jerin Jacob Date: Mon, 25 Jan 2021 23:54:06 +0530 Message-ID: To: Liron Himi Cc: Jerin Jacob , dpdk-dev , dpdk stable , Kiran Kumar Kokkilagadda Content-Type: text/plain; charset="UTF-8" Subject: Re: [dpdk-stable] [dpdk-dev] [PATCH] net/octeontx2: move PF-func location for egress X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" On Mon, Jan 18, 2021 at 4:20 PM wrote: > > From: Liron Himi > > pf-func is 16bit but the current reserved location > used in tx action is 8bits. moved it to bits 63-48. > > Fixes: 32e6aaa97 ("net/octeontx2: support flow parse actions") > Cc: stable@dpdk.org > > Signed-off-by: Liron Himi > Reviewed-by: Kiran Kumar Kokkilagadda Applied to dpdk-next-net-mrvl/for-main. Thanks > --- > drivers/net/octeontx2/otx2_flow_parse.c | 5 ++++- > drivers/net/octeontx2/otx2_flow_utils.c | 2 +- > 2 files changed, 5 insertions(+), 2 deletions(-) > > diff --git a/drivers/net/octeontx2/otx2_flow_parse.c b/drivers/net/octeontx2/otx2_flow_parse.c > index 476195d63..e9b940f6c 100644 > --- a/drivers/net/octeontx2/otx2_flow_parse.c > +++ b/drivers/net/octeontx2/otx2_flow_parse.c > @@ -1090,7 +1090,10 @@ otx2_flow_parse_actions(struct rte_eth_dev *dev, > > set_pf_func: > /* Ideally AF must ensure that correct pf_func is set */ > - flow->npc_action |= (uint64_t)pf_func << 4; > + if (attr->egress) > + flow->npc_action |= (uint64_t)pf_func << 48; > + else > + flow->npc_action |= (uint64_t)pf_func << 4; > > return 0; > > diff --git a/drivers/net/octeontx2/otx2_flow_utils.c b/drivers/net/octeontx2/otx2_flow_utils.c > index 9a0a5f9fb..7ed86ba74 100644 > --- a/drivers/net/octeontx2/otx2_flow_utils.c > +++ b/drivers/net/octeontx2/otx2_flow_utils.c > @@ -944,7 +944,7 @@ otx2_flow_mcam_alloc_and_write(struct rte_flow *flow, struct otx2_mbox *mbox, > req->entry_data.kw[0] |= flow_info->channel; > req->entry_data.kw_mask[0] |= (BIT_ULL(12) - 1); > } else { > - uint16_t pf_func = (flow->npc_action >> 4) & 0xffff; > + uint16_t pf_func = (flow->npc_action >> 48) & 0xffff; > > pf_func = htons(pf_func); > req->entry_data.kw[0] |= ((uint64_t)pf_func << 32); > -- > 2.28.0 >