From nobody Sun Aug 14 15:04:08 2022 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 4M5LKP25nQz4ZJcQ; Sun, 14 Aug 2022 15:04:09 +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 4M5LKP1F7Mz3c3L; Sun, 14 Aug 2022 15:04:09 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1660489449; 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=ZSQitwwHfOOu4mg8EzAN2kU/aW4EOCQPNn/lxlbdPNo=; b=egIlbE7Wvwm94rrKgoGaM7B96BLGCeDU3S6rYtmoJ3RGbDeioCmJa8zSYXxQ5eciYk5Rv4 FgkUHG1wIAmhFRjTDP2huSq3zydf1EWptR2YTcoKC1vi+PxUlIigknxgDcxlutFnl0wXGd QWAhWX/MZhmU1wnohQTi8Ax5OJN5uNmv7uLtW+OIE1eAvS30szyUcHkt30yATAbP+oHTwA Gjqfui8O3z8Dmkw0qIBN7TEALh3JJH4exf5Mi9n3tPS3FHr3JWe1dSFvwYq45TqytTdQJ/ DSsrORTh4yQMfgKrI+di7YmDmMUE6FcNEEoe/PYkJ+V5jTyi/+cyzxDmfmZheQ== 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 4M5LKP08MgztkF; Sun, 14 Aug 2022 15:04:09 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 27EF480A077016; Sun, 14 Aug 2022 15:04:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 27EF48Bl077015; Sun, 14 Aug 2022 15:04:08 GMT (envelope-from git) Date: Sun, 14 Aug 2022 15:04:08 GMT Message-Id: <202208141504.27EF48Bl077015@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Chuck Tuffli Subject: git: 7376c08cc67e - main - bhyve nvme: Fix uninitialized pointer 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: chuck X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 7376c08cc67e65ee660d51873129e34745ef5dd4 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1660489449; 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=ZSQitwwHfOOu4mg8EzAN2kU/aW4EOCQPNn/lxlbdPNo=; b=eWQaKHuvdv2gTpcp6YedVdgpPPOgXfY5aJKHiREvtIrAc5wAF3edvy6bv1AeJ8Z42vu20b pAJLEMgxdkPu0JhxKQ7rGCUi3IO/kHzw8L0pffboLdcrhNzrAF+2NvORh68PGTEl8St2Yt 1CvqjaL24dj6MEWYaWJC+rL12eqyvzjchqJ+rxI00vu8hXIidsOycb4F3SPu3+qreOhDLE HOalSurxuQmzq91gSPStJIYlaARrOh9QgyLcB1lFRrYKOrD8Uv55/+PMmnpoLn+FguFIdI uvnKBTtviVJlFFe95kOZnnTwZq6Fe8Rgs59o8gw2BUQQfx4mmWDXCzSrDeXsMA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1660489449; a=rsa-sha256; cv=none; b=nuQEBxbTiqr7+gy7Uc+TUgzKqsoP6jolKNICnjlMnEmHTCmh6Xpp0kB9sPd5G+St8rm3n2 9/Yfaubj/m/IOgotDoHYOTqC3So4JswmN77PVYOFVra4T+CxUCMv5OCoPhgQq1zHLPvwxV I5F5MKLdNoePj8fUZBgrQNoUeK0QS1hlNk7vKnQUh2NJwzGmw5BfpdOWtXY4ktwdtNgljA EkyOKm8ApyuRYZuEUjFkBgBwzcr5QhupV331/EmvASWCLXP/b3k4DV4xFlyW8wKkCrgZhX wawc7lsrkbVOOe3DTLrwnhTRpuFN3H7vTZRWxKvST7+5JbZzzaLxqDP/Sul3Kg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by chuck: URL: https://cgit.FreeBSD.org/src/commit/?id=7376c08cc67e65ee660d51873129e34745ef5dd4 commit 7376c08cc67e65ee660d51873129e34745ef5dd4 Author: Chuck Tuffli AuthorDate: 2022-06-09 20:05:46 +0000 Commit: Chuck Tuffli CommitDate: 2022-08-14 14:53:22 +0000 bhyve nvme: Fix uninitialized pointer The Dataset Management code could free an uninitialized pointer if the device doesn't support the Dataset Management command. PR: 264548 Reported by: Robert Morris --- usr.sbin/bhyve/pci_nvme.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr.sbin/bhyve/pci_nvme.c b/usr.sbin/bhyve/pci_nvme.c index 46a8104be9f6..92d4ce286940 100644 --- a/usr.sbin/bhyve/pci_nvme.c +++ b/usr.sbin/bhyve/pci_nvme.c @@ -2597,7 +2597,7 @@ nvme_opc_dataset_mgmt(struct pci_nvme_softc *sc, struct pci_nvme_ioreq *req, uint16_t *status) { - struct nvme_dsm_range *range; + struct nvme_dsm_range *range = NULL; uint32_t nr, r, non_zero, dr; int err; bool pending = false;