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 241082E5412 for ; Tue, 7 Oct 2025 15:24:36 +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=1759850676; cv=none; b=p1b+O0HSttERVwDhLDrbPhWTGnIeo/4RTfGtQmFLKcwrkZHjDODSN1TtTCEsv0YIyoySKdG68xyThnITOfBaIIISK6TpvJuAQBU30WX7ZBJ0NAuH2ro+W9AYmNiCCid5alSB8FPr9vETosjBUVIVBc1oJ7D86oSJ2e80CdXEIHQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1759850676; c=relaxed/simple; bh=uIFt3OSg4eXvDAUb3afekDaT710riloGIC9S8kZPCM4=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=GvH0sKmRh7e4aApqmStT0A6BIiwPczR2iuAfxJEFaSiTvddD9Fxaht+QBv7h3RzHAVSNd4Ewb8qmUVSa5ChNqOkX6kBLtxS07ZzIcVflF49d6hbvBffvbaR3lM+5vP/yW3EkAEU8ouLXKbPcrJP8ilJQgwpbGXfzZIlizQvc1y0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=K3ke7XvR; 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="K3ke7XvR" Received: by smtp.kernel.org (Postfix) with ESMTPSA id A6901C4CEF1; Tue, 7 Oct 2025 15:24:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1759850676; bh=uIFt3OSg4eXvDAUb3afekDaT710riloGIC9S8kZPCM4=; h=From:To:Cc:Subject:Date:Reply-to:From; b=K3ke7XvR9N8ABL9XYZFoSG0VPXw5kXaeshIhLFnYoqP0VGPewGeyOLBwPHKu95fB3 Psgq1MjYiZVRwoIqc9OgHDoPwq5cwzgbxEihcIjvZH7TNc4q1L1qEuk8r29IgrvcHr 0ffLz0/l1lLsSq4d6+GWnTGMJTc65ZWae0kcuHB4= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2022-50540: dmaengine: qcom-adm: fix wrong sizeof config in slave_config Date: Tue, 7 Oct 2025 17:20:58 +0200 Message-ID: <2025100755-CVE-2022-50540-46a8@gregkh> X-Mailer: git-send-email 2.51.0 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=2339; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=NEvvqKdWM+D38BhpI92ujkwV/qCRBXdX1k1NayJY7q8=; b=owGbwMvMwCRo6H6F97bub03G02pJDBlP9a/bqWTnTb4Vtm5DGHeL7zlP1oNzgydY9hvKHTEK7 IsJXTWpI5aFQZCJQVZMkeXLNp6j+ysOKXoZ2p6GmcPKBDKEgYtTACYy04Vhfn3uoeu30hJaP8e2 PjikJf8n+opEJ8OCGdov9n5oVbn4dc6vWL4p7a22U3dzAQA= X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: dmaengine: qcom-adm: fix wrong sizeof config in slave_config Fix broken slave_config function that uncorrectly compare the peripheral_size with the size of the config pointer instead of the size of the config struct. This cause the crci value to be ignored and cause a kernel panic on any slave that use adm driver. To fix this, compare to the size of the struct and NOT the size of the pointer. The Linux kernel CVE team has assigned CVE-2022-50540 to this issue. Affected and fixed versions =========================== Issue introduced in 5.17 with commit 03de6b273805b3c552ff158f8688555937375926 and fixed in 5.19.17 with commit f1dd45a6585a1689e1e8906b3f9e302b9d40c715 Issue introduced in 5.17 with commit 03de6b273805b3c552ff158f8688555937375926 and fixed in 6.0.3 with commit 7490274b41a432824f7df5071ace3df2ab59caa7 Issue introduced in 5.17 with commit 03de6b273805b3c552ff158f8688555937375926 and fixed in 6.1 with commit 7c8765308371be30f50c1b5b97618b731514b207 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-2022-50540 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/dma/qcom/qcom_adm.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/f1dd45a6585a1689e1e8906b3f9e302b9d40c715 https://git.kernel.org/stable/c/7490274b41a432824f7df5071ace3df2ab59caa7 https://git.kernel.org/stable/c/7c8765308371be30f50c1b5b97618b731514b207