]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
soc: qcom: add pd-mapper implementation
authorDmitry Baryshkov <dmitry.baryshkov@linaro.org>
Fri, 21 Jun 2024 22:03:43 +0000 (01:03 +0300)
committerBjorn Andersson <andersson@kernel.org>
Mon, 24 Jun 2024 22:32:07 +0000 (17:32 -0500)
commit1ebcde047c547134e894508468ead0b7bd3b967d
treed82607d312d5b558032060979f0bb4ad984e2f6b
parent0ac5c7d933de6570e0efa62bb5ef9e440311a6fe
soc: qcom: add pd-mapper implementation

Existing userspace protection domain mapper implementation has several
issue. It doesn't play well with CONFIG_EXTRA_FIRMWARE, it doesn't
reread JSON files if firmware location is changed (or if firmware was
not available at the time pd-mapper was started but the corresponding
directory is mounted later), etc.

Provide in-kernel service implementing protection domain mapping
required to work with several services, which are provided by the DSP
firmware.

This module is loaded automatically by the remoteproc drivers when
necessary via the symbol dependency. It uses a root node to match a
protection domains map for a particular board. It is not possible to
implement it as a 'driver' as there is no corresponding device.

Tested-by: Steev Klimaszewski <steev@kali.org>
Tested-by: Alexey Minnekhanov <alexeymin@postmarketos.org>
Reviewed-by: Chris Lew <quic_clew@quicinc.com>
Tested-by: Neil Armstrong <neil.armstrong@linaro.org> # on SM8550-QRD
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Link: https://lore.kernel.org/r/20240622-qcom-pd-mapper-v9-4-a84ee3591c8e@linaro.org
[bjorn: include linux/slab.h]
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
drivers/soc/qcom/Kconfig
drivers/soc/qcom/Makefile
drivers/soc/qcom/pdr_internal.h
drivers/soc/qcom/qcom_pd_mapper.c [new file with mode: 0644]
drivers/soc/qcom/qcom_pdr_msg.c