diff options
author | Yong Wu <yong.wu@mediatek.com> | 2023-04-11 12:31:34 +0300 |
---|---|---|
committer | Joerg Roedel <jroedel@suse.de> | 2023-04-13 12:59:24 +0300 |
commit | b2a6876d215b3e980d8ac89ccc704667ad266205 (patch) | |
tree | 3ab5fce6372f0147ddc0a47ae29e8c63c622059f /tools/perf/scripts/python/stackcollapse.py | |
parent | ae6693453ac665015929d2b05104d5a2951375af (diff) | |
download | linux-b2a6876d215b3e980d8ac89ccc704667ad266205.tar.xz |
iommu/mediatek: Get regionid from larb/port id
After commit f1ad5338a4d5 ("of: Fix "dma-ranges" handling for bus
controllers"), the dma-ranges is not allowed for dts leaf node.
but we still would like to separate to different masters
into different iova regions.
Thus we have to separate it by the HW larbid and portid. For example,
larb1/2 are in region2 and larb3 is in region3. The problem is that
some ports inside a larb are in region4 while some ports inside this
larb are in region5. Therefore I define a "iova_region_larb_msk" to help
record the information for each a port. Take a example for a larb:
[1] = ~0: means all ports in this larb are in region1;
[2] = BIT(3) | BIT(4): means port3/4 in this larb are region2;
[3] = ~(BIT(3) | BIT(4)): means all the other ports except port3/4
in this larb are region3.
This method also avoids the users forget/abuse the iova regions.
Signed-off-by: Yong Wu <yong.wu@mediatek.com>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Link: https://lore.kernel.org/r/20230411093144.2690-5-yong.wu@mediatek.com
Signed-off-by: Joerg Roedel <jroedel@suse.de>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions