From: Bibek Kumar Patro <quic_bibekkum@quicinc.com>
To: Konrad Dybcio <konrad.dybcio@linaro.org>,
Rob Clark <robdclark@gmail.com>
Cc: <will@kernel.org>, <robin.murphy@arm.com>, <joro@8bytes.org>,
<jgg@ziepe.ca>, <jsnitsel@redhat.com>, <robh@kernel.org>,
<krzysztof.kozlowski@linaro.org>, <quic_c_gdjako@quicinc.com>,
<dmitry.baryshkov@linaro.org>, <iommu@lists.linux.dev>,
<linux-arm-msm@vger.kernel.org>,
<linux-arm-kernel@lists.infradead.org>,
<linux-kernel@vger.kernel.org>,
Rob Clark <robdclark@chromium.org>
Subject: Re: [PATCH v13 6/6] iommu/arm-smmu: add support for PRR bit setup
Date: Fri, 19 Jul 2024 18:29:49 +0530 [thread overview]
Message-ID: <7b757a6b-4ca9-4f8a-b8dd-571737805405@quicinc.com> (raw)
In-Reply-To: <61e04616-32f8-4574-9721-ea032d227bf2@linaro.org>
On 7/16/2024 5:44 PM, Konrad Dybcio wrote:
> On 15.07.2024 10:07 PM, Rob Clark wrote:
>> On Mon, Jul 15, 2024 at 4:00 AM Bibek Kumar Patro
>> <quic_bibekkum@quicinc.com> wrote:
>
> [...]
>
>>>>> As I checked gpu_prr_mem reserved mem section is not used for mobile
>>>>> targets hence not present for other DT only compute targets like
>>>>> x1e80100.dtsi has the same. PRR looks to be smmu version specific
>>>>> property.
>>>>
>>>> I only see it in gpu_prr_mem in x1e80100.dtsi, but not documented
>>>> anywhere. I'm only assuming based on the name that it is intended to
>>>> be for PRR (but not sure why it is larger than 0x1000). Are the
>>>> PRR_CFG_*ADDR regs programmed by the fw (and access blocked in EL1) on
>>>> this device?
>>>>
>>>
>>> As I checked, if the drm/gfx driver allocates the page for drm, then
>>> this reserved-memory region is not required.
>>>
>>> PRR_CFG_*ADDR regs have read and write access in EL1 only for this
>>> device, behavior is same as other devices as well. These are not
>>> programmed by fw.
>>
>> If there is any device which _doesn't_ have EL1 access to these regs,
>> I think going the reserved memory route seems more future proof?
>> Otherwise we later on have to deal with two different ways to do
>> things. But I'm not sure if there is any such device or risk.
>
> We can have our cake and eat it too, if we keep the check for a
> reserved memory node handle, but make it a dynamic allocation (see
> [1] for example), this way there's a way to opt into using this from
> the DT and there's no need for adding more properties
>
Coming to allocation methodology, here the client/user(drm/gpu
driver in this case) would be allocating the page and pass the address
to our SMMU interface which would just configure it in the PRR_CFG_*ADDR
register.
So I believe the choice of allocation method should be better left to
the client, rather than restricting them to a specific strategy. (?)
If dynamically allocated without a reserved pool, this region might only
be present in some targets and not others, which could make it look a
bit ugly [1].
Thanks & regards,
Bibek
[1]:https://lore.kernel.org/all/CAF6AEGvZWdN+CC9O3tq7kjYPq424U6__KgAnFNCV0bCqE8wPuQ@mail.gmail.com/#:~:text=That%0Aseems%20a%20bit%20ugly%20to%20me.
> Konrad
>
> [1] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/arch/arm64/boot/dts/qcom/msm8916.dtsi?h=v6.10#n109
next prev parent reply other threads:[~2024-07-19 13:00 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-06-28 14:04 [PATCH v13 0/6] iommu/arm-smmu: introduction of ACTLR implementation for Qualcomm SoCs Bibek Kumar Patro
2024-06-28 14:04 ` [PATCH v13 1/6] iommu/arm-smmu: re-enable context caching in smmu reset operation Bibek Kumar Patro
2024-06-28 14:04 ` [PATCH v13 2/6] iommu/arm-smmu: refactor qcom_smmu structure to include single pointer Bibek Kumar Patro
2024-06-28 14:04 ` [PATCH v13 3/6] iommu/arm-smmu: introduction of ACTLR for custom prefetcher settings Bibek Kumar Patro
2024-06-28 14:04 ` [PATCH v13 4/6] iommu/arm-smmu: add ACTLR data and support for SM8550 Bibek Kumar Patro
2024-07-01 18:34 ` Dmitry Baryshkov
2024-07-03 12:15 ` Bibek Kumar Patro
2024-07-03 13:02 ` Will Deacon
2024-07-04 9:12 ` Bibek Kumar Patro
2024-07-04 11:26 ` Dmitry Baryshkov
2024-07-04 11:23 ` Dmitry Baryshkov
2024-07-10 17:44 ` Bibek Kumar Patro
2024-06-28 14:04 ` [PATCH v13 5/6] iommu/arm-smmu: add ACTLR data and support for SC7280 Bibek Kumar Patro
2024-06-28 14:04 ` [PATCH v13 6/6] iommu/arm-smmu: add support for PRR bit setup Bibek Kumar Patro
2024-06-28 14:17 ` Rob Clark
2024-06-28 15:09 ` Bibek Kumar Patro
2024-06-28 15:44 ` Rob Clark
2024-07-01 11:00 ` Bibek Kumar Patro
2024-07-01 20:31 ` Rob Clark
2024-07-03 11:38 ` Bibek Kumar Patro
2024-07-04 14:46 ` Rob Clark
2024-07-04 15:58 ` Rob Clark
2024-07-09 19:42 ` Bibek Kumar Patro
2024-07-10 17:01 ` Rob Clark
2024-07-10 22:01 ` Konrad Dybcio
2024-07-15 11:01 ` Bibek Kumar Patro
2024-07-15 10:59 ` Bibek Kumar Patro
2024-07-15 20:07 ` Rob Clark
2024-07-16 12:14 ` Konrad Dybcio
2024-07-19 12:59 ` Bibek Kumar Patro [this message]
2024-07-17 10:27 ` Bibek Kumar Patro
2024-07-17 15:00 ` Rob Clark
2024-07-19 12:38 ` Bibek Kumar Patro
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7b757a6b-4ca9-4f8a-b8dd-571737805405@quicinc.com \
--to=quic_bibekkum@quicinc.com \
--cc=dmitry.baryshkov@linaro.org \
--cc=iommu@lists.linux.dev \
--cc=jgg@ziepe.ca \
--cc=joro@8bytes.org \
--cc=jsnitsel@redhat.com \
--cc=konrad.dybcio@linaro.org \
--cc=krzysztof.kozlowski@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=quic_c_gdjako@quicinc.com \
--cc=robdclark@chromium.org \
--cc=robdclark@gmail.com \
--cc=robh@kernel.org \
--cc=robin.murphy@arm.com \
--cc=will@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®