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

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

Merge "msm: ipa: Add SPS_BAM_MGR_DEVICE_REMOTE in bam options"

parents 05d830e1 39f785c1
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -37,6 +37,8 @@ memory allocation over a PCIe bridge
- qcom,msm-bus,vectors-KBps:    Arrays of unsigned integers representing:
                                master-id, slave-id, arbitrated bandwidth
                                in KBps, instantaneous bandwidth in KBps
- qcom,ipa-bam-remote-mode:     Boolean context flag to determine if ipa bam
                                is in remote mode.

IPA pipe sub nodes (A2 static pipes configurations):

+13 −3
Original line number Diff line number Diff line
@@ -2582,9 +2582,8 @@ static int ipa_setup_bam_cfg(const struct ipa_plat_drv_res *res)
		retval = -EPERM;
		goto fail;
	}

	if (ipa_ctx->ipa_hw_type < IPA_HW_v2_5)
		ipa_write_reg(ipa_bam_mmio, IPA_BAM_CNFG_BITS_OFST, reg_val);

fail:
	iounmap(ipa_bam_mmio);

@@ -2961,6 +2960,7 @@ static int ipa_init(const struct ipa_plat_drv_res *resource_p,
	ipa_ctx->ipa_hw_type = resource_p->ipa_hw_type;
	ipa_ctx->ipa_hw_mode = resource_p->ipa_hw_mode;
	ipa_ctx->use_ipa_teth_bridge = resource_p->use_ipa_teth_bridge;
	ipa_ctx->ipa_bam_remote_mode = resource_p->ipa_bam_remote_mode;

	/* default aggregation parameters */
	ipa_ctx->aggregation_type = IPA_MBIM_16;
@@ -3082,6 +3082,8 @@ static int ipa_init(const struct ipa_plat_drv_res *resource_p,
	if (ipa_ctx->ipa_hw_mode != IPA_HW_MODE_VIRTUAL)
		bam_props.options |= SPS_BAM_OPT_IRQ_WAKEUP;
	bam_props.options |= SPS_BAM_RES_CONFIRM;
	if (ipa_ctx->ipa_bam_remote_mode == true)
		bam_props.manage |= SPS_BAM_MGR_DEVICE_REMOTE;
	bam_props.ee = resource_p->ee;
	bam_props.callback = sps_event_cb;

@@ -3455,6 +3457,7 @@ static int get_ipa_dts_configuration(struct platform_device *pdev,
	ipa_drv_res->ipa_pipe_mem_size = IPA_PIPE_MEM_SIZE;
	ipa_drv_res->ipa_hw_type = 0;
	ipa_drv_res->ipa_hw_mode = 0;
	ipa_drv_res->ipa_bam_remote_mode = false;

	/* Get IPA HW Version */
	result = of_property_read_u32(pdev->dev.of_node, "qcom,ipa-hw-ver",
@@ -3481,6 +3484,13 @@ static int get_ipa_dts_configuration(struct platform_device *pdev,
		ipa_drv_res->use_ipa_teth_bridge
		? "True" : "False");

	ipa_drv_res->ipa_bam_remote_mode =
			of_property_read_bool(pdev->dev.of_node,
			"qcom,ipa-bam-remote-mode");
	IPADBG(": ipa bam remote mode = %s\n",
			ipa_drv_res->ipa_bam_remote_mode
			? "True" : "False");

	/* Get IPA wrapper address */
	resource = platform_get_resource_byname(pdev, IORESOURCE_MEM,
			"ipa-base");
+2 −0
Original line number Diff line number Diff line
@@ -1088,6 +1088,7 @@ struct ipa_context {
	enum ipa_hw_type ipa_hw_type;
	enum ipa_hw_mode ipa_hw_mode;
	bool use_ipa_teth_bridge;
	bool ipa_bam_remote_mode;
	/* featurize if memory footprint becomes a concern */
	struct ipa_stats stats;
	void *smem_pipe_mem;
@@ -1150,6 +1151,7 @@ struct ipa_plat_drv_res {
	enum ipa_hw_type ipa_hw_type;
	enum ipa_hw_mode ipa_hw_mode;
	u32 ee;
	bool ipa_bam_remote_mode;
};

struct ipa_mem_partition {