All of lore.kernel.org
 help / color / mirror / Atom feed
From: Subbaraya Sundeep <sbhatta@marvell.com>
To: Alok Tiwari <alok.a.tiwari@oracle.com>
Cc: <sd@queasysnail.net>, <bbhushan2@marvell.com>,
	<pabeni@redhat.com>, <kuba@kernel.org>, <edumazet@google.com>,
	<davem@davemloft.net>, <andrew+netdev@lunn.ch>,
	<jerinj@marvell.com>, <hkelam@marvell.com>, <gakula@marvell.com>,
	<lcherian@marvell.com>, <sgoutham@marvell.com>,
	<george.cherian@marvell.com>, <netdev@vger.kernel.org>,
	<alok.a.tiwarilinux@gmail.com>
Subject: Re: [PATCH net-next] octeontx2: cn10k: fix RX flowid TCAM mask handling
Date: Mon, 19 Jan 2026 16:38:11 +0530	[thread overview]
Message-ID: <20260119110811.GA1492101@kernel-ep2> (raw)
In-Reply-To: <20260116164724.2733511-1-alok.a.tiwari@oracle.com>

On 2026-01-16 at 22:17:12, Alok Tiwari (alok.a.tiwari@oracle.com) wrote:
> The RX flowid programming initializes the TCAM mask to all ones, but
> then overwrites it when clearing the MAC DA mask bits. This results
> in losing the intended initialization and may affect other match fields.
> 
> Update the code to clear the MAC DA bits using an AND operation, making
> the handling of mask[0] consistent with mask[1], where the field-specific
> bits are cleared after initializing the mask to ~0ULL.
> 
> Signed-off-by: Alok Tiwari <alok.a.tiwari@oracle.com>
This has no impact in functionality and it is better to be consistent with
mask[1]. Thanks for the change.

Reviewed-by: Subbaraya Sundeep <sbhatta@marvell.com>

> ---
>  drivers/net/ethernet/marvell/octeontx2/nic/cn10k_macsec.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/ethernet/marvell/octeontx2/nic/cn10k_macsec.c b/drivers/net/ethernet/marvell/octeontx2/nic/cn10k_macsec.c
> index 4c7e0f345cb5..060c715ebad0 100644
> --- a/drivers/net/ethernet/marvell/octeontx2/nic/cn10k_macsec.c
> +++ b/drivers/net/ethernet/marvell/octeontx2/nic/cn10k_macsec.c
> @@ -328,7 +328,7 @@ static int cn10k_mcs_write_rx_flowid(struct otx2_nic *pfvf,
>  
>  	req->data[0] = FIELD_PREP(MCS_TCAM0_MAC_DA_MASK, mac_da);
>  	req->mask[0] = ~0ULL;
> -	req->mask[0] = ~MCS_TCAM0_MAC_DA_MASK;
> +	req->mask[0] &= ~MCS_TCAM0_MAC_DA_MASK;
>  
>  	req->data[1] = FIELD_PREP(MCS_TCAM1_ETYPE_MASK, ETH_P_MACSEC);
>  	req->mask[1] = ~0ULL;
> -- 
> 2.50.1
> 

  reply	other threads:[~2026-01-19 11:08 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-01-16 16:47 [PATCH net-next] octeontx2: cn10k: fix RX flowid TCAM mask handling Alok Tiwari
2026-01-19 11:08 ` Subbaraya Sundeep [this message]
2026-01-19 18:12 ` Jakub Kicinski
2026-01-19 18:20 ` patchwork-bot+netdevbpf

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260119110811.GA1492101@kernel-ep2 \
    --to=sbhatta@marvell.com \
    --cc=alok.a.tiwari@oracle.com \
    --cc=alok.a.tiwarilinux@gmail.com \
    --cc=andrew+netdev@lunn.ch \
    --cc=bbhushan2@marvell.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=gakula@marvell.com \
    --cc=george.cherian@marvell.com \
    --cc=hkelam@marvell.com \
    --cc=jerinj@marvell.com \
    --cc=kuba@kernel.org \
    --cc=lcherian@marvell.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=sd@queasysnail.net \
    --cc=sgoutham@marvell.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.