From nobody Mon Sep 30 05:08:13 2024 X-Original-To: dev-commits-src-branches@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 4XH8Gj6gwSz5XlLX; Mon, 30 Sep 2024 05:08:13 +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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4XH8Gj4Lxtz4Wws; Mon, 30 Sep 2024 05:08:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1727672893; 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=jf/fIULFnefiq24g9JWO6dyMajOIN4JcntMjzzzHD7o=; b=ERB620v+jy5E7TetKUt+FGcTNRBCcdR2qm3CKrgyq1mRyDyE3bnMH+XsX6Aje8qwKW9B2a fXZSkTtxHRI9F+ke+7ci+3+wQWRtgA3IQiCYpELJ34PBP5sS6StXZ7czv3CHzsI3Fn/tg1 2mhe4RaKsY1OS31470ZBJADkqex2oij/LXyxGqNnyKtz0yUieZSv87UFxICFkUPn6i4k/r ccqQlECycaGvY2CYeW2gTvaIq7UsQDV0cakzmrPKs7dOoHD+Fh8PM9Tyhge8/PYH2Ozjf3 Aaa2t6BvnadAntF/i8G7tc80Fvv/Zi0adDEq2e46R1VDGANPb9jTn+HX+0uWhw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1727672893; 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=jf/fIULFnefiq24g9JWO6dyMajOIN4JcntMjzzzHD7o=; b=wtn/9RYYRCqvUqmJzNRAft4F9CUIdKmuG6of/WBTpfh7+mqAnrqLYwbT8NcrA5ZsJTR6vn uKQW4EO1Bz7BsKqZOFwFQ/pEtBCOjNh6Zd5dofsIq9xbMkblKnl2PMB6qUnG/Sd0y+DlC0 jgDHdJF7tmSloDTpbBljherzwfRFSVtSkHT18ikKgWZS0mNg5r2LwStTf7XaX03Z6WF4H1 MC4D4fuaY7dhTo1ER7sbR9ign0KC4DX0WSgqrTYLvjg/LPihuDq3GQmcXASGQXgnj5sQvB eGRsTfqJycpOJi+/hsLTsu2dUHB+s07379SrY7cVil/gq8mmJh0eNqF8g7KY1w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1727672893; a=rsa-sha256; cv=none; b=pKDggnCciS2Kc8rZ9DQkwJhY1I7bxQpgPhMvXc48MVbXY1mK+3Lc4CUbBC1TMgEiOvNEVB fpU8A8gCGzlr+DkvhBAACIYLha1Z5wd9ZVnUfeZguihkkdAPnvPoSIRcohTogCcRTq8riu UUmdlZKovG9uTFw7Pl8THf/bR1I1rIQkTWxtuEkFAwIpVI6MMIv5FoYOe9EHJh1uMhVjbB tdjWtyqrXALeIltYSXU9dLvZxgagnaMgsqjOlQDDmYpCKXk7LKKGg8dYbdnWZ9OfMBJgZz PbxpvEuBk2azD5rSbPh8a7XH2YRomBZ7T3sGxGQnNM29RRb9BemUVSOkITeWUw== 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 4XH8Gj3zH6zg86; Mon, 30 Sep 2024 05:08:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 48U58Dpe024608; Mon, 30 Sep 2024 05:08:13 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 48U58DSL024605; Mon, 30 Sep 2024 05:08:13 GMT (envelope-from git) Date: Mon, 30 Sep 2024 05:08:13 GMT Message-Id: <202409300508.48U58DSL024605@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Zhenlei Huang Subject: git: 9113fe381f1e - stable/13 - al_eth: Stop checking for failures from malloc/buf_ring_alloc(M_WAITOK) List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 9113fe381f1ea848d960315a3d3abdf9b770da07 Auto-Submitted: auto-generated The branch stable/13 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=9113fe381f1ea848d960315a3d3abdf9b770da07 commit 9113fe381f1ea848d960315a3d3abdf9b770da07 Author: Zhenlei Huang AuthorDate: 2024-09-03 10:25:23 +0000 Commit: Zhenlei Huang CommitDate: 2024-09-30 05:05:32 +0000 al_eth: Stop checking for failures from malloc/buf_ring_alloc(M_WAITOK) MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D45852 (cherry picked from commit 00ae9c1be02e2db6ede1abd5b787bb9a3fbd76b0) (cherry picked from commit 74887e322101cbc9e531e3acd08a6eb10dd2169e) --- sys/dev/al_eth/al_eth.c | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/sys/dev/al_eth/al_eth.c b/sys/dev/al_eth/al_eth.c index eb6525a566dd..409769b5ee5f 100644 --- a/sys/dev/al_eth/al_eth.c +++ b/sys/dev/al_eth/al_eth.c @@ -2009,14 +2009,6 @@ al_eth_enable_msix(struct al_eth_adapter *adapter) adapter->msix_entries = malloc(msix_vecs*sizeof(*adapter->msix_entries), M_IFAL, M_ZERO | M_WAITOK); - - if (adapter->msix_entries == NULL) { - device_printf_dbg(adapter->dev, "failed to allocate" - " msix_entries %d\n", msix_vecs); - rc = ENOMEM; - goto exit; - } - /* management vector (GROUP_A) @2*/ adapter->msix_entries[AL_ETH_MGMT_IRQ_IDX].entry = 2; adapter->msix_entries[AL_ETH_MGMT_IRQ_IDX].vector = 0; @@ -2304,9 +2296,6 @@ al_eth_setup_tx_resources(struct al_eth_adapter *adapter, int qid) size = sizeof(struct al_eth_tx_buffer) * tx_ring->sw_count; tx_ring->tx_buffer_info = malloc(size, M_IFAL, M_ZERO | M_WAITOK); - if (tx_ring->tx_buffer_info == NULL) - return (ENOMEM); - tx_ring->descs_size = tx_ring->hw_count * sizeof(union al_udma_desc); q_params->size = tx_ring->hw_count; @@ -2329,10 +2318,6 @@ al_eth_setup_tx_resources(struct al_eth_adapter *adapter, int qid) mtx_init(&tx_ring->br_mtx, "AlRingMtx", NULL, MTX_DEF); tx_ring->br = buf_ring_alloc(AL_BR_SIZE, M_DEVBUF, M_WAITOK, &tx_ring->br_mtx); - if (tx_ring->br == NULL) { - device_printf(dev, "Critical Failure setting up buf ring\n"); - return (ENOMEM); - } /* Allocate taskqueues */ TASK_INIT(&tx_ring->enqueue_task, 0, al_eth_start_xmit, tx_ring); @@ -2481,9 +2466,6 @@ al_eth_setup_rx_resources(struct al_eth_adapter *adapter, unsigned int qid) size += 1; rx_ring->rx_buffer_info = malloc(size, M_IFAL, M_ZERO | M_WAITOK); - if (rx_ring->rx_buffer_info == NULL) - return (ENOMEM); - rx_ring->descs_size = rx_ring->hw_count * sizeof(union al_udma_desc); q_params->size = rx_ring->hw_count;