From nobody Thu Jan 11 05:34:37 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4T9YJY68bYz56VhY; Thu, 11 Jan 2024 05:34:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4T9YJY3lCHz485x; Thu, 11 Jan 2024 05:34:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1704951277; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=LRhHrInUTDLChiS64WsDRBo7g64h3uwiZIOXpDtkons=; b=p0CbvBO1s56PDOHvn6CxCGoiPCMCWBk11Q86mATZAcvb8BfBLstdUe8SM+YJ+aobNyA/TW ju4SYCKe7xgsTknI5VtMdqwmPOn0vdm0nGoTrl8jD3rYqYS4+8tB2f8UjafN/XQO7oTaZo djd3Irzu8LGPTzwpQaPWN4P0F5cvM3JzEK/k4NWPOM7FWZ8nr1hP8KeNPeqHDcxfsS8MKC GPmrXp9cA2XJ4Hm37wDA9u0C1EPt11eRuw/5ADSY8amO4CslNy655YfKgwiX5E9hrK3S2V HlUgOq/IalbnM+Ev/5Eg00ZB0312WOWEnmX5jaXIWiK4hU9SGvtghvEDoVpqUw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1704951277; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=LRhHrInUTDLChiS64WsDRBo7g64h3uwiZIOXpDtkons=; b=a53qFko7L406HKo11pNZsU2377RUfQQQfhgH3cW9eC8kxGdSbt/za+zMqzpkm/Ww9cR2fH rArvs/wZfVJ1NU0esclwj1xAUcD41sZ32PPk/i9yrcOh8KYJrsV3bV33lmQTF/Pq5KmFF8 aM9P135QyKPMQFaAdxpqp3VKWmApkWhKgzqjwSUN0t3N1RvXzvz7EcI9XqyQDzZM2Ykxqi xHtr1aKe8s7bict9z4obSAwHe8Mt2pTO6k6/zxhLhl9Id1HDPN/f0PRCRXb9YWnGA2z1Gz gQFJqRrIf98VSztbp7sqcjUmkBw2TDZQJNqc4Al1HSxlBrMZVE2fzKjdq0gC3A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1704951277; a=rsa-sha256; cv=none; b=py8r0d2txctNL6a94y2v0g60ajT6tiO8ACLak6piL1nxT/L/y1E+a7duYS8X6VJuVTTxLq Oh4iBVdbU0rkFk6t01dB7cg22OUYXAlW/awmzWoHd96kHkYY2LI37Ul/Ui/z3enN9iRY5e Spz09zrE5l2q3LM7mTJaY74I+3Q9aMshpKNaKaH3TFx54TNlJZsj7/7S3yFaLm+1N04tPm fIISjWuzctyHkT3Mc2qHB2BJos0TSfmNHCnglQNRo2tJ/oVBTGYdkB7kPKHjPOFgGY13UO GmjwAPR6B+yeRZWdLJ5jVvOi+lcF1+c7H8QX7WOuoPG0iNSNFWGB6+gH56tNsw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4T9YJY2Mwdz15W4; Thu, 11 Jan 2024 05:34:37 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 40B5YbCb010253; Thu, 11 Jan 2024 05:34:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 40B5YblG010250; Thu, 11 Jan 2024 05:34:37 GMT (envelope-from git) Date: Thu, 11 Jan 2024 05:34:37 GMT Message-Id: <202401110534.40B5YblG010250@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Navdeep Parhar Subject: git: 2cca64fbe579 - stable/13 - cxgbe(4): Use the correct size for the CIM LA on the T6. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: np X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 2cca64fbe579dea06103cc954e28c1148d366744 Auto-Submitted: auto-generated The branch stable/13 has been updated by np: URL: https://cgit.FreeBSD.org/src/commit/?id=2cca64fbe579dea06103cc954e28c1148d366744 commit 2cca64fbe579dea06103cc954e28c1148d366744 Author: Navdeep Parhar AuthorDate: 2024-01-09 21:22:16 +0000 Commit: Navdeep Parhar CommitDate: 2024-01-11 05:09:16 +0000 cxgbe(4): Use the correct size for the CIM LA on the T6. The logic analyzer in the T6 CIM block has a different capture size than previous chips. Sponsored by: Chelsio Communications (cherry picked from commit 9ea86c8f67a65ca00f79f3cd83aa977b38589f39) --- sys/dev/cxgbe/common/common.h | 1 + sys/dev/cxgbe/common/t4_hw.c | 7 +++++-- sys/dev/cxgbe/common/t4_hw.h | 3 ++- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/sys/dev/cxgbe/common/common.h b/sys/dev/cxgbe/common/common.h index cd1e648f8e59..0861e3df4bee 100644 --- a/sys/dev/cxgbe/common/common.h +++ b/sys/dev/cxgbe/common/common.h @@ -313,6 +313,7 @@ struct chip_params { u32 sge_fl_db; u16 mps_tcam_size; u16 rss_nentries; + u16 cim_la_size; }; /* VF-only parameters. */ diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index 41063d5c7d76..c18243e4b681 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -9303,6 +9303,7 @@ const struct chip_params *t4_get_chip_params(int chipid) .sge_fl_db = F_DBPRIO, .mps_tcam_size = NUM_MPS_CLS_SRAM_L_INSTANCES, .rss_nentries = RSS_NENTRIES, + .cim_la_size = CIMLA_SIZE, }, { /* T5 */ @@ -9317,6 +9318,7 @@ const struct chip_params *t4_get_chip_params(int chipid) .sge_fl_db = F_DBPRIO | F_DBTYPE, .mps_tcam_size = NUM_MPS_T5_CLS_SRAM_L_INSTANCES, .rss_nentries = RSS_NENTRIES, + .cim_la_size = CIMLA_SIZE, }, { /* T6 */ @@ -9331,6 +9333,7 @@ const struct chip_params *t4_get_chip_params(int chipid) .sge_fl_db = 0, .mps_tcam_size = NUM_MPS_T5_CLS_SRAM_L_INSTANCES, .rss_nentries = T6_RSS_NENTRIES, + .cim_la_size = CIMLA_SIZE_T6, }, }; @@ -9386,11 +9389,11 @@ int t4_prep_adapter(struct adapter *adapter, u32 *buf) /* Cards with real ASICs have the chipid in the PCIe device id */ t4_os_pci_read_cfg2(adapter, PCI_DEVICE_ID, &device_id); if (device_id >> 12 == chip_id(adapter)) - adapter->params.cim_la_size = CIMLA_SIZE; + adapter->params.cim_la_size = adapter->chip_params->cim_la_size; else { /* FPGA */ adapter->params.fpga = 1; - adapter->params.cim_la_size = 2 * CIMLA_SIZE; + adapter->params.cim_la_size = 2 * adapter->chip_params->cim_la_size; } ret = get_vpd_params(adapter, &adapter->params.vpd, device_id, buf); diff --git a/sys/dev/cxgbe/common/t4_hw.h b/sys/dev/cxgbe/common/t4_hw.h index e943acb8dec9..79ec690cd5e6 100644 --- a/sys/dev/cxgbe/common/t4_hw.h +++ b/sys/dev/cxgbe/common/t4_hw.h @@ -66,7 +66,8 @@ enum { CIM_NUM_IBQ = 6, /* # of CIM IBQs */ CIM_NUM_OBQ = 6, /* # of CIM OBQs */ CIM_NUM_OBQ_T5 = 8, /* # of CIM OBQs for T5 adapter */ - CIMLA_SIZE = 2048, /* # of 32-bit words in CIM LA */ + CIMLA_SIZE = 256 * 8, /* 256 rows * ceil(235/32) 32-bit words */ + CIMLA_SIZE_T6 = 256 * 10, /* 256 rows * ceil(311/32) 32-bit words */ CIM_PIFLA_SIZE = 64, /* # of 192-bit words in CIM PIF LA */ CIM_MALA_SIZE = 64, /* # of 160-bit words in CIM MA LA */ CIM_IBQ_SIZE = 128, /* # of 128-bit words in a CIM IBQ */