From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 50CD819F424 for ; Wed, 26 Feb 2025 01:57:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740535051; cv=none; b=DCURA6bR2KxBz4AE76v0LKRtiiHQim1ovRXRVcv/TmERnCohgs2q1PdWH/pY79Fq5WFBjNdvqAiyxp8PUzQhXgh0272fLJ1dkQyu28Xceqh4uNJYInRwBzxV+x/PAGrAYKG2PZE44TvL7ifduV33ZGsu8JQ5/mne83RQplfpWnA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1740535051; c=relaxed/simple; bh=SBLVkpR2xrMoE14/xT6GsZx0pGsWq0WdEQA87Ej0g9E=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=hVHKz4Vn+tRafMqP7Nb1z9eo/JPugMFC+uAsrIGrqdPac2u9+b3kfM5QncbrJI0VLMgHoAGPwmngqeTGYPKF+oNssIomZXjlMuhszgFHkHLlDAOMS7N050NDukLLl4Jv9jHX9N1qGR1ADX96zz7sryfy6SqNhTfGhRG5qiQMcSY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=RhqE/0JN; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="RhqE/0JN" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0552DC4CEE7; Wed, 26 Feb 2025 01:57:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1740535051; bh=SBLVkpR2xrMoE14/xT6GsZx0pGsWq0WdEQA87Ej0g9E=; h=From:To:Cc:Subject:Date:Reply-to:From; b=RhqE/0JNTFpyRms0u7Ohap+H4Xvd68TPWNffkHOgTSFEOzB0DZ3bfpyfyXIjK30+J yeSQUylCiFtDi415E7fJQTzAINhTw4AoX015yRQRleBBeQzRDmeMoulW64oyXX8nU/ diW8VLuecFnXKk/SuDT2Oe8UtK2nxgOwnYZfwvdc= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2021-47655: media: venus: vdec: fixed possible memory leak issue Date: Wed, 26 Feb 2025 02:54:06 +0100 Message-ID: <2025022650-CVE-2021-47655-0491@gregkh> X-Mailer: git-send-email 2.48.1 Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Reply-to: , X-Developer-Signature: v=1; a=openpgp-sha256; l=2494; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=SBLVkpR2xrMoE14/xT6GsZx0pGsWq0WdEQA87Ej0g9E=; b=owGbwMvMwCRo6H6F97bub03G02pJDOn7SvSmGR5jkGzhMH/jlZo4mS1qkcD2K/Ms02+487/ac zSEJ6q1I5aFQZCJQVZMkeXLNp6j+ysOKXoZ2p6GmcPKBDKEgYtTACZyXJphwfWnVhHXrGwKLMKO Pj7RcCHbx3WzLcOC47Zy56a77fYLUWPbskwmNeVlq4UoAA== X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit Description =========== In the Linux kernel, the following vulnerability has been resolved: media: venus: vdec: fixed possible memory leak issue The venus_helper_alloc_dpb_bufs() implementation allows an early return on an error path when checking the id from ida_alloc_min() which would not release the earlier buffer allocation. Move the direct kfree() from the error checking of dma_alloc_attrs() to the common fail path to ensure that allocations are released on all error paths in this function. Addresses-Coverity: 1494120 ("Resource leak") The Linux kernel CVE team has assigned CVE-2021-47655 to this issue. Affected and fixed versions =========================== Issue introduced in 5.16 with commit 40d87aafee29fb01ce1e1868502fb2059a6a7f34 and fixed in 5.16.19 with commit 55bccafc246b2e64763a155ec454470c07a54a6e Issue introduced in 5.16 with commit 40d87aafee29fb01ce1e1868502fb2059a6a7f34 and fixed in 5.17.2 with commit 5f89d05ba93df9c2cdfe493843f93288e55e99eb Issue introduced in 5.16 with commit 40d87aafee29fb01ce1e1868502fb2059a6a7f34 and fixed in 5.18 with commit 8403fdd775858a7bf04868d43daea0acbe49ddfc Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community. Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at https://cve.org/CVERecord/?id=CVE-2021-47655 will be updated if fixes are backported, please check that for the most up to date information about this issue. Affected files ============== The file(s) affected by this issue are: drivers/media/platform/qcom/venus/helpers.c Mitigation ========== The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits: https://git.kernel.org/stable/c/5cedfe8aaf1875a5305897107b7f298db4260019 https://git.kernel.org/stable/c/55bccafc246b2e64763a155ec454470c07a54a6e https://git.kernel.org/stable/c/5f89d05ba93df9c2cdfe493843f93288e55e99eb https://git.kernel.org/stable/c/8403fdd775858a7bf04868d43daea0acbe49ddfc