Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4f22bf6c authored by Dilip Kota's avatar Dilip Kota Committed by Vipin Deep Kaur
Browse files

platform: msm: qcom-geni-se: Configure context bank device node



Configure the context bank device node default
value to geni device node to use geni device node
for dma memory allocation in the case of context bank
node is disabled. Iommu map and attach is not done if
iommu-dma bypass is set.

Change-Id: I1a1c17320de6b768b58bc73ee075659f3e90058d
Signed-off-by: default avatarDilip Kota <dkota@codeaurora.org>
parent fb1de31a
Loading
Loading
Loading
Loading
+10 −1
Original line number Diff line number Diff line
@@ -862,6 +862,8 @@ int geni_se_resources_init(struct se_geni_rsc *rsc,
			   unsigned long ab, unsigned long ib)
{
	struct geni_se_device *geni_se_dev;
	int ret = 0;
	const char *mode = NULL;

	if (unlikely(!rsc || !rsc->wrapper_dev))
		return -EINVAL;
@@ -887,7 +889,13 @@ int geni_se_resources_init(struct se_geni_rsc *rsc,
	rsc->ib = ib;
	INIT_LIST_HEAD(&rsc->ab_list);
	INIT_LIST_HEAD(&rsc->ib_list);

	ret = of_property_read_string(geni_se_dev->dev->of_node,
					"qcom,iommu-dma", &mode);

	if ((ret == 0) && (strcmp(mode, "disabled") == 0))
		geni_se_iommu_map_and_attach(geni_se_dev);

	return 0;
}
EXPORT_SYMBOL(geni_se_resources_init);
@@ -1464,6 +1472,7 @@ static int geni_se_probe(struct platform_device *pdev)
	}

	geni_se_dev->dev = dev;
	geni_se_dev->cb_dev = dev;
	ret = of_property_read_u32(dev->of_node, "qcom,bus-mas-id",
				   &geni_se_dev->bus_mas_id);
	if (ret) {