From patchwork Fri Aug 30 14:00:23 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sriharsha Basavapatna X-Patchwork-Id: 143480 X-Patchwork-Delegate: ajit.khaparde@broadcom.com Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id B0708458A8; Fri, 30 Aug 2024 15:53:29 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 9D06E42EA5; Fri, 30 Aug 2024 15:53:29 +0200 (CEST) Received: from mail-pl1-f195.google.com (mail-pl1-f195.google.com [209.85.214.195]) by mails.dpdk.org (Postfix) with ESMTP id 09D5442EAA for ; Fri, 30 Aug 2024 15:53:29 +0200 (CEST) Received: by mail-pl1-f195.google.com with SMTP id d9443c01a7336-202146e9538so15248085ad.3 for ; Fri, 30 Aug 2024 06:53:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; t=1725026008; x=1725630808; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=YUYqp4JGRgYFYOVOCz3o0y9T5HKSyLNtLcXP0qqEkGk=; b=LN177XTJLW8LWXJkDOm1V8++JE15LXomPokdIQ3+eEcghHMbRwBXzqA/WlFfIUR+WT CL4YnEdJqThi8EU24AUtOabI/XhH/xoHEib3uGHeQUASjdkx67CGs0xCWgi2RFi5y046 JvS0dAKLq+r8ofN5Aa4OqMsRlVZprhGNgblUw= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1725026008; x=1725630808; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=YUYqp4JGRgYFYOVOCz3o0y9T5HKSyLNtLcXP0qqEkGk=; b=CNwnz2RXTGDhS5WFhhHzs2Ir4gfG6GLPrOVNEKcyaeyPblX47LQXpOW2rSsvAiXfTp DZdAgUIhP0V6EMDJ/wKgWU0KdqdrtyDEjgg8LR5iRmrwdMrtS2DEJ4gN93dNx0G25/i3 73AHEC6u5lHFEm9Esh6W50feya5GZcQtp0zncYVFIpzq6kEudnZR89W044kQZSoUDHnP 1tIfa9jluUZa5Vo+LOP5Ka22H2h4JbI5uGp70QNKLkdZzpfrDJ0mRWezZx87Iijb/yFT ODvQTElZbp3Y5EvSVCTJZfTxO9vAJQH/WU1uwRYQyvAJXDMNe7E+PjJgi+4puHcQ0FGZ ieaw== X-Gm-Message-State: AOJu0Ywg26/EoT2nwBwNvC10rEN9dpzXSXFkflQVhqw2WVHZwQ/bLDra b0XWCddih/YQiQPwbUcBjuRkcKMsnjAJpvrrTCRHWXjuOBq2MKfbMeLIMzzEy/WrqsMsrONgvSw Ec55knUXALuECyBc/hH1gx97dRK8jrn3uEYXYfTE3GKow3Hifh5n+ucmF/dess9HF8hJXVLNTYn e9NwZXJ+3RXv0akS1iecrc/y3wwKA0+zGDQ3Tb1xUoaA0d/Ns= X-Google-Smtp-Source: AGHT+IFzDtQ2ikDNrM0CkcYQjQBNIRGkVzQM6+TGavW6IEgTjy6+hJVpC/gx13qlBof2mQPHbIHevw== X-Received: by 2002:a17:903:124c:b0:1fa:2e45:bcb8 with SMTP id d9443c01a7336-2050c2062efmr72133105ad.2.1725026007026; Fri, 30 Aug 2024 06:53:27 -0700 (PDT) Received: from dhcp-10-123-154-23.dhcp.broadcom.net ([192.19.234.250]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-205155658dfsm27067145ad.297.2024.08.30.06.53.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 30 Aug 2024 06:53:26 -0700 (PDT) From: Sriharsha Basavapatna To: dev@dpdk.org Cc: Jay Ding , Michael Baucom , Farah Smith , Sriharsha Basavapatna Subject: [PATCH 21/47] net/bnxt: tf_ulp: add action read and clear support Date: Fri, 30 Aug 2024 19:30:23 +0530 Message-Id: <20240830140049.1715230-22-sriharsha.basavapatna@broadcom.com> X-Mailer: git-send-email 2.39.0.189.g4dbebc36b0 In-Reply-To: <20240830140049.1715230-1-sriharsha.basavapatna@broadcom.com> References: <20240830140049.1715230-1-sriharsha.basavapatna@broadcom.com> MIME-Version: 1.0 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 From: Jay Ding Implement action read and clear support. Change flow query count to reset the count after read in ULP. Update cli cmds accordingly. Fixed bnxt_mpc_xmit() to pad the mpc message to be multiple of 16 bytes. Signed-off-by: Jay Ding Reviewed-by: Michael Baucom Reviewed-by: Farah Smith Signed-off-by: Sriharsha Basavapatna --- drivers/net/bnxt/tf_ulp/ulp_fc_mgr_tfc.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/net/bnxt/tf_ulp/ulp_fc_mgr_tfc.c b/drivers/net/bnxt/tf_ulp/ulp_fc_mgr_tfc.c index f1bbce797d..2be37b59c2 100644 --- a/drivers/net/bnxt/tf_ulp/ulp_fc_mgr_tfc.c +++ b/drivers/net/bnxt/tf_ulp/ulp_fc_mgr_tfc.c @@ -83,6 +83,10 @@ ulp_fc_tfc_flow_stat_get(struct bnxt_ulp_context *ctxt, cmm_info.rsubtype = CFA_RSUBTYPE_CMM_ACT; cmm_info.act_handle = handle; cmm_info.dir = (enum cfa_dir)direction; + cmm_clr.clr = true; + cmm_clr.offset_in_byte = 0; + cmm_clr.sz_in_byte = sizeof(data64[ULP_FC_TFC_PKT_CNT_OFFS]) + + sizeof(data64[ULP_FC_TFC_BYTE_CNT_OFFS]); rc = tfc_act_get(tfcp, NULL, &cmm_info, &cmm_clr, data, &word_size); if (rc) { BNXT_DRV_DBG(ERR,