]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
soc: qcom: mdt_loader: Actually use the e_phoff
authorBjorn Andersson <bjorn.andersson@oss.qualcomm.com>
Wed, 11 Jun 2025 02:58:30 +0000 (21:58 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 28 Aug 2025 14:28:19 +0000 (16:28 +0200)
commitc2c252d2c1800c20ef76568c9b0add1d3f1efc01
treecfc2453b1c1f31fb9c403e9a79530da4fcc68df6
parent7589729947aa3aa6fa6d91afde949479ea469bce
soc: qcom: mdt_loader: Actually use the e_phoff

[ Upstream commit 47e339cac89143709e84a3b71ba8bd9b2fdd2368 ]

Rather than relying/assuming that the tools generating the firmware
places the program headers immediately following the ELF header, use
e_phoff as intended to find the program headers.

Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Signed-off-by: Bjorn Andersson <bjorn.andersson@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20250610-mdt-loader-validation-and-fixes-v2-3-f7073e9ab899@oss.qualcomm.com
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/soc/qcom/mdt_loader.c