Qualcomm Shared Memory State Machine

Schema identifier ($id): "http://devicetree.org/schemas/soc/qcom/qcom,smsm.yaml#"

Schema dialect ($schema): "http://devicetree.org/meta-schemas/core.yaml#"

Maintainers (maintainers): "Andy Gross <agross@kernel.org>", "Bjorn Andersson <bjorn.andersson@linaro.org>", "Krzysztof Kozlowski <krzk@kernel.org>"

The Shared Memory State Machine facilitates broadcasting of single bit state information between the processors in a Qualcomm SoC. Each processor is assigned 32 bits of state that can be modified. A processor can through a matrix of bitmaps signal subscription of notifications upon changes to a certain bit owned by a certain remote processor.

Properties and child nodes (properties) #

compatible — required here #

Exact value (const): "qcom,smsm"

#address-cells — required here #

Exact value (const): 1

qcom,local-host — not listed as required here #

Shared schema rule ($ref): /schemas/types.yaml#/definitions/uint32

Default value (default): 0

Identifier of the local processor in the list of hosts, or in other words specifier of the column in the subscription matrix representing the local processor.

mboxes — not listed as required here #

Minimum number of items (minItems): 1

Maximum number of items (maxItems): 5

Reference to the mailbox representing the outgoing doorbell in APCS for this client. Each entry represents the N:th remote processor by index (0-indexed).

#size-cells — required here #

Exact value (const): 0

Properties matching a name pattern (patternProperties) #

^qcom,ipc-[1-4]$ — name matches this regular expression #

Shared schema rule ($ref): /schemas/types.yaml#/definitions/phandle-array

Array item rules (items) #

Item 1

Array item rules (items)

Item 1

phandle to a syscon node representing the APCS registers

Item 2

u32 representing offset to the register within the syscon

Item 3

u32 representing the ipc bit within the register

Three entries specifying the outgoing ipc bit used for signaling the N:th remote processor.

Deprecated (deprecated): true

@[0-9a-f]$ — name matches this regular expression #

Value type (type): "object"

Each processor's state bits are described by a subnode of the SMSM device node. Nodes can either be flagged as an interrupt-controller to denote a remote processor's state bits or the local processors bits. The node names are not important.

Properties and child nodes (properties) #

reg — required here

Maximum number of items (maxItems): 1

interrupt-controller — not listed as required here

Marks the entry as a interrupt-controller and the state bits to belong to a remote processor.

#interrupt-cells — not listed as required here

Exact value (const): 2

interrupts — not listed as required here

Maximum number of items (maxItems): 1

One entry specifying remote IRQ used by the remote processor to signal changes of its state bits.

#qcom,smem-state-cells — not listed as required here

Shared schema rule ($ref): /schemas/types.yaml#/definitions/uint32

Exact value (const): 1

Required for local entry. Denotes bit number.

Required in this object (required): "reg"

Exactly one of these rules must match (oneOf) #

Rule 1

Required in this object (required): "#qcom,smem-state-cells"

Rule 2

Required in this object (required): "interrupt-controller", "#interrupt-cells", "interrupts"

Properties not matched by properties or patternProperties in this schema (additionalProperties) #

false

Not allowed by this rule.

Required in this object (required): "compatible", "#address-cells", "#size-cells"

Exactly one of these rules must match (oneOf) #

Rule 1 #

Required in this object (required): "mboxes"

Rule 2 #

At least one of these rules must match (anyOf) #

Rule 1

Required in this object (required): "qcom,ipc-1"

Rule 2

Required in this object (required): "qcom,ipc-2"

Rule 3

Required in this object (required): "qcom,ipc-3"

Rule 4

Required in this object (required): "qcom,ipc-4"

Properties not matched by properties or patternProperties in this schema (additionalProperties) #

false

Not allowed by this rule.

Examples (examples) #

#include <dt-bindings/interrupt-controller/arm-gic.h>

shared-memory {
    compatible = "qcom,smsm";
    #address-cells = <1>;
    #size-cells = <0>;
    mboxes = <0>, <0>, <0>, <&apcs 19>;

    apps_smsm: apps@0 {
        reg = <0>;
        #qcom,smem-state-cells = <1>;
    };

    wcnss_smsm: wcnss@7 {
        reg = <7>;
        interrupts = <GIC_SPI 144 IRQ_TYPE_EDGE_RISING>;
        interrupt-controller;
        #interrupt-cells = <2>;
    };
};

Source notes #

Annotations retained from the schema source

Line 1: SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause

Line 126: The following example shows the SMEM setup for controlling properties of

Line 127: the wireless processor, defined from the 8974 apps processor's

Line 128: point-of-view. It encompasses one outbound entry and the outgoing interrupt

Line 129: for the wireless processor.

Edit this page