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

Commit 4c96b1dd authored by qctecmdr Service's avatar qctecmdr Service Committed by Gerrit - the friendly Code Review server
Browse files

Merge "memshare: Add snapshot of memshare driver"

parents 35d3c928 bc570dc3
Loading
Loading
Loading
Loading
+65 −0
Original line number Diff line number Diff line
* Memory Share Driver (MEMSHARE)

The Memshare driver implements a Kernel QMI service on the
LA-APSS, which is responsible for providing contiguous physical
memory to MPSS for use cases when the modem requires additional
memory (e.g. GPS).

Required properties for Memshare

-Root Node-

- compatible:	Must be "qcom,memshare"

Required properties for child nodes:

- compatible:	Must be "qcom,memshare-peripheral"

- qcom,peripheral-size:	Indicates the size (in bytes) required for that child.

- qcom,client-id:	Indicates the client id of the child node.

- label:	Indicates the peripheral information for the node. Should be one of
  the following:
  - modem	/* Represent Modem Peripheral */
  - adsp	/* Represent ADSP Peripheral */
  - wcnss	/* Represent WCNSS Peripheral */

Optional properties for child nodes:

- qcom,allocate-boot-time:	Indicates whether clients needs boot time memory allocation.

- qcom,allocate-on-request:	Indicates memory allocation happens only upon client request

Note: qcom,allocate-boot-time and qcom,allocate-on-request are mutually exclusive rite now.

- qcom,guard-band:	Indicates addition of a guard band memory allocation in addition to the client's memory region.

Example 1:

qcom,memshare {
	compatible = "qcom,memshare";

	qcom,client_1 {
		compatible = "qcom,memshare-peripheral";
		qcom,peripheral-size = <0x200000>;
		qcom,client-id = <0>;
		qcom,allocate-boot-time;
		label = "modem";
	};
};

Example 2:

qcom,memshare {
	compatible = "qcom,memshare";

	qcom,client_3 {
		compatible = "qcom,memshare-peripheral";
		qcom,peripheral-size = <0x500000>;
		qcom,client-id = <1>;
		qcom,allocate-on-request;
		qcom,guard-band;
		label = "modem";
	};
};
 No newline at end of file
+2 −0
Original line number Diff line number Diff line
@@ -644,6 +644,8 @@ config MSM_JTAGV8
	  memory penalty.
endmenu

source "drivers/soc/qcom/memshare/Kconfig"

config QMP_DEBUGFS_CLIENT
	bool "Debugfs Client to communicate with AOP using QMP protocol"
	depends on DEBUG_FS
+1 −0
Original line number Diff line number Diff line
@@ -41,6 +41,7 @@ obj-$(CONFIG_MSM_SERVICE_NOTIFIER) += service-notifier.o
obj-$(CONFIG_MSM_SERVICE_LOCATOR) += service-locator.o
obj-$(CONFIG_MSM_SYSMON_GLINK_COMM) += sysmon-glink.o sysmon-qmi.o
obj-$(CONFIG_MSM_PIL_SSR_GENERIC) += subsys-pil-tz.o
obj-$(CONFIG_MEM_SHARE_QMI_SERVICE)		+= memshare/
obj-$(CONFIG_MSM_PIL)   +=      peripheral-loader.o
obj-$(CONFIG_MSM_CDSP_LOADER) += qdsp6v2/
obj-$(CONFIG_MSM_JTAGV8) += jtagv8.o jtagv8-etm.o
+13 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: GPL-2.0-only
#
# Shared Heap for external processors
#
config MEM_SHARE_QMI_SERVICE
       depends on QCOM_QMI_HELPERS
       bool "Shared Heap for external processors"
       help
		Memory Share Kernel QTI Messaging Interface Service
		receives requests from Modem Processor Sub System
		for heap alloc/free from Application Processor
		Sub System and send a response back to client with
		proper handle/address.
+2 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: GPL-2.0-only
obj-$(CONFIG_MEM_SHARE_QMI_SERVICE) := heap_mem_ext_v01.o msm_memshare.o
Loading