From nobody Mon Sep 30 05:08:35 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 4XH8H76vTGz5Xltp; Mon, 30 Sep 2024 05:08:35 +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 4XH8H74YgCz4Xcm; Mon, 30 Sep 2024 05:08:35 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1727672915; 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=e1iVWFIKBXFs+S2dzJmNd2nIcYoSM2J4AYrWiiXHMKw=; b=lLEWbJ97i5hFJACiLwJolg0BOqXvhbodBWnFwNDizRKgSqrsQeFE3z/1mFK7k6eaw95v0H EAjuBdw899DpNU7y0bBGwW1n+qmUYRnzPJJYPRFo63VeBzn4dir/K4Vy5cLHqkH3yxZmuc ZqtKdM+X+gqvwQ04ZdU3E+PT+bHkzZ7h9f+T0+vnhOFU+roxWYgikd8JMLNf1VuLh8gY0h 5708nCLabR0vHR3usTSB18omL0lhJHpFPXHJLhpYHJLTuHMfu5lbjUSLFQitAxVcktyFyB QUP7IC42rsIetbg8bv7O6J83X3VDWzuA1PWRVdD+Ynzw4U/+C4XNOxeG3/IJkw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1727672915; 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=e1iVWFIKBXFs+S2dzJmNd2nIcYoSM2J4AYrWiiXHMKw=; b=YhTUDpWN1/fVTlOahoINHKJSYnNO8S/LRHyq+XOzhmQjAXD/h2t/AL9gPybN1p/jXdherQ aKk8M87zY9g/zNl2z13/vPGF3FztBUOAjosmsCbWYLiC+Bbf9v2lzGZ9CV0MZ8xFCByZcL ZNV7A1OrYMgdVfrPHgw8PPG8yWZdBVjlu86nxVbC+C/uhG2sZufLry/njd20iQq2eMjChH rluJDowT0ODjFvc8/xCOLDRVczUzZvxsbyal3RgmvkZjQwVXy59/5eXO1kbP5jh+OGntyd Dze08VL0j5BMYCCtesnNELuQ2k+JqnZobgonnoIBu6xgiaVoug6Nh3bX7MrlJw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1727672915; a=rsa-sha256; cv=none; b=fDTIZIBvZR7EXORXqIA04Usi1G607nPylANgkb/QDWrl+rz9VrHv3790QGxyYrYyuzBl+u 87lo5JpS+tdCBFy9kKA3LuPaCHFxUgraJewTLdlOybyxCP1dNsQeBbG+wJJeSj4jVdhm09 EtMd5bXpLJGJKybsNmADcW5ZErcEn7hmNuvF9uJWf+jJMW6OOUuIIF9wQEFcO3S9xlr8ni DKdv/HW6bDc9aj2r9NpHqw7ObUAtpo6Fm3ssBy1t4alvLWj+2uC9kLcYcZ+5Bt7zooGXMn SIB4JeEqbRU4RVzYwRPbXcf5AyamnusgESPyPJqR9HKahMqn2wegJujMPZebkg== 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 4XH8H748Xszfr0; Mon, 30 Sep 2024 05:08:35 +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 48U58Z0u025563; Mon, 30 Sep 2024 05:08:35 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 48U58ZRf025560; Mon, 30 Sep 2024 05:08:35 GMT (envelope-from git) Date: Mon, 30 Sep 2024 05:08:35 GMT Message-Id: <202409300508.48U58ZRf025560@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: 68c96d15d3e2 - stable/13 - sume(4): Stop checking for failures from malloc(M_WAITOK) 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: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@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: 68c96d15d3e2107bd5b60825bae32ab3cd848593 Auto-Submitted: auto-generated The branch stable/13 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=68c96d15d3e2107bd5b60825bae32ab3cd848593 commit 68c96d15d3e2107bd5b60825bae32ab3cd848593 Author: Zhenlei Huang AuthorDate: 2024-09-03 10:25:33 +0000 Commit: Zhenlei Huang CommitDate: 2024-09-30 05:05:38 +0000 sume(4): Stop checking for failures from malloc(M_WAITOK) MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D45852 (cherry picked from commit 761339c5544a360df9d3bab70675fea246eb6a83) (cherry picked from commit 140a0c8f39816648719d9670fb641c657732439e) --- sys/dev/sume/if_sume.c | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/sys/dev/sume/if_sume.c b/sys/dev/sume/if_sume.c index 59e4dbc9d02e..0868a5b00e87 100644 --- a/sys/dev/sume/if_sume.c +++ b/sys/dev/sume/if_sume.c @@ -1203,16 +1203,11 @@ sume_probe_riffa_buffer(const struct sume_adapter *adapter, { struct riffa_chnl_dir **rp; bus_addr_t hw_addr; - int error, ch; + int ch; device_t dev = adapter->dev; - error = ENOMEM; *p = malloc(SUME_RIFFA_CHANNELS * sizeof(struct riffa_chnl_dir *), M_SUME, M_ZERO | M_WAITOK); - if (*p == NULL) { - device_printf(dev, "malloc(%s) failed.\n", dir); - return (error); - } rp = *p; /* Allocate the chnl_dir structs themselves. */ @@ -1220,11 +1215,6 @@ sume_probe_riffa_buffer(const struct sume_adapter *adapter, /* One direction. */ rp[ch] = malloc(sizeof(struct riffa_chnl_dir), M_SUME, M_ZERO | M_WAITOK); - if (rp[ch] == NULL) { - device_printf(dev, "malloc(%s[%d]) riffa_chnl_dir " - "failed.\n", dir, ch); - return (error); - } int err = bus_dma_tag_create(bus_get_dma_tag(dev), 4, 0,