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

Commit 41b647c6 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "usb_bam: Enable SPS_BAM_SMMU_EN with BAM device"

parents 7e407735 9b853f90
Loading
Loading
Loading
Loading
+10 −0
Original line number Diff line number Diff line
@@ -3101,6 +3101,7 @@ static int usb_bam_init(struct platform_device *pdev)
	struct usb_bam_ctx_type *ctx = dev_get_drvdata(&pdev->dev);
	enum usb_ctrl bam_type = ctx->usb_bam_data->bam_type;
	struct sps_bam_props props;
	struct device *dev;

	memset(&props, 0, sizeof(props));

@@ -3136,6 +3137,15 @@ static int usb_bam_init(struct platform_device *pdev)
		pr_debug("Register and enable HSUSB BAM\n");
		props.options |= SPS_BAM_OPT_ENABLE_AT_BOOT;
	}

	dev = &ctx->usb_bam_pdev->dev;
	if (dev && dev->parent && !device_property_present(dev->parent,
						"qcom,smmu-s1-bypass")) {
		pr_info("%s: setting SPS_BAM_SMMU_EN flag with (%s)\n",
						__func__, dev_name(dev));
		props.options |= SPS_BAM_SMMU_EN;
	}

	ret = sps_register_bam_device(&props, &ctx->h_bam);
	if (ret < 0) {
		log_event_err("%s: register bam error %d\n", __func__, ret);