Freescale SEC 4

Schema identifier ($id): "http://devicetree.org/schemas/crypto/fsl,sec-v4.0.yaml#"

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

Maintainers (maintainers): "\"Horia Geantă\" <horia.geanta@nxp.com>", "Pankaj Gupta <pankaj.gupta@nxp.com>", "Gaurav Jain <gaurav.jain@nxp.com>"

NOTE: the SEC 4 is also known as Freescale's Cryptographic Accelerator Accelerator and Assurance Module (CAAM).

SEC 4 h/w can process requests from 2 types of sources. 1. DPAA Queue Interface (HW interface between Queue Manager & SEC 4). 2. Job Rings (HW interface between cores & SEC 4 registers).

High Speed Data Path Configuration:

HW interface between QM & SEC 4 and also BM & SEC 4, on DPAA-enabled parts such as the P4080. The number of simultaneous dequeues the QI can make is equal to the number of Descriptor Controller (DECO) engines in a particular SEC version. E.g., the SEC 4.0 in the P4080 has 5 DECOs and can thus dequeue from 5 subportals simultaneously.

Job Ring Data Path Configuration:

Each JR is located on a separate 4k page, they may (or may not) be made visible in the memory partition devoted to a particular core. The P4080 has 4 JRs, so up to 4 JRs can be configured; and all 4 JRs process requests in parallel.

Properties and child nodes (properties) #

compatible — required here #

Exactly one of these rules must match (oneOf) #

Rule 1

Array item rules (items)

Item 1

Allowed values (enum): "fsl,sec-v5.4", "fsl,sec-v6.0"

Item 2

Exact value (const): "fsl,sec-v5.0"

Item 3

Exact value (const): "fsl,sec-v4.0"

Rule 2

Array item rules (items)

Item 1

Allowed values (enum): "fsl,imx6ul-caam", "fsl,imx8qm-caam", "fsl,imx8qxp-caam", "fsl,sec-v5.0"

Item 2

Exact value (const): "fsl,sec-v4.0"

Rule 3

Exact value (const): "fsl,sec-v4.0"

reg — required here #

Maximum number of items (maxItems): 1

ranges — required here #

Maximum number of items (maxItems): 1

#address-cells — not listed as required here #

Allowed values (enum): 1, 2

#size-cells — not listed as required here #

Allowed values (enum): 1, 2

clocks — not listed as required here #

Minimum number of items (minItems): 1

Maximum number of items (maxItems): 4

clock-names — not listed as required here #

Minimum number of items (minItems): 1

Maximum number of items (maxItems): 4

Array item rules (items) #

Allowed values (enum): "mem", "aclk", "ipg", "emi_slow"

dma-coherent — not listed as required here #

true — No constraints added by this property rule.

interrupts — not listed as required here #

Maximum number of items (maxItems): 1

power-domains — not listed as required here #

Maximum number of items (maxItems): 1

fsl,sec-era — not listed as required here #

Defines the 'ERA' of the SEC device.

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

Properties matching a name pattern (patternProperties) #

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

Value type (type): "object"

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

false

Not allowed by this rule.

Job Ring (JR) Node. Defines data processing interface to SEC 4 across the peripheral bus for purposes of processing cryptographic descriptors. The specified address range can be made visible to one (or more) cores. The interrupt defined for this node is controlled within the address range of this node.

Properties and child nodes (properties) #

compatible — not listed as required here

Exactly one of these rules must match (oneOf)

Rule 1

Array item rules (items)

Item 1

Exact value (const): "fsl,sec-v6.0-job-ring"

Item 2

Exact value (const): "fsl,sec-v5.2-job-ring"

Item 3

Exact value (const): "fsl,sec-v5.0-job-ring"

Item 4

Exact value (const): "fsl,sec-v4.4-job-ring"

Item 5

Exact value (const): "fsl,sec-v4.0-job-ring"

Rule 2

Array item rules (items)

Item 1

Exact value (const): "fsl,sec-v5.4-job-ring"

Item 2

Exact value (const): "fsl,sec-v5.0-job-ring"

Item 3

Exact value (const): "fsl,sec-v4.0-job-ring"

Rule 3

Array item rules (items)

Item 1

Allowed values (enum): "fsl,imx8qm-job-ring", "fsl,imx8qxp-job-ring", "fsl,sec-v5.0-job-ring"

Item 2

Exact value (const): "fsl,sec-v4.0-job-ring"

Rule 4

Exact value (const): "fsl,sec-v4.0-job-ring"

reg — not listed as required here

Maximum number of items (maxItems): 1

interrupts — not listed as required here

Maximum number of items (maxItems): 1

power-domains — not listed as required here

Maximum number of items (maxItems): 1

fsl,liodn — not listed as required here

Specifies the LIODN to be used in conjunction with the ppid-to-liodn table that specifies the PPID to LIODN mapping. Needed if the PAMU is used. Value is a 12 bit value where value is a LIODN ID for this JR. This property is normally set by boot firmware.

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

Array item rules (items)

Item 1

Maximum value (maximum): 4095

All of these rules must match (allOf) #

Rule 1

Condition (if)

Properties and child nodes (properties)

compatible — not listed as required here

Rule for matching array elements (contains)

Allowed values (enum): "fsl,imx8qm-job-ring", "fsl,imx8qxp-job-ring"

When the condition matches (then)

Required in this object (required): "power-domains"

When the condition does not match (else)

Properties and child nodes (properties)

power-domains — not listed as required here

false — Not permitted by this property rule.

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

Value type (type): "object"

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

false

Not allowed by this rule.

Run Time Integrity Check (RTIC) Node. Defines a register space that contains up to 5 sets of addresses and their lengths (sizes) that will be checked at run time. After an initial hash result is calculated, these addresses are checked by HW to monitor any change. If any memory is modified, a Security Violation is triggered (see SNVS definition).

Properties and child nodes (properties) #

compatible — not listed as required here

Exactly one of these rules must match (oneOf)

Rule 1

Array item rules (items)

Item 1

Exact value (const): "fsl,sec-v5.4-rtic"

Item 2

Exact value (const): "fsl,sec-v5.0-rtic"

Item 3

Exact value (const): "fsl,sec-v4.0-rtic"

Rule 2

Exact value (const): "fsl,sec-v4.0-rtic"

reg — not listed as required here

Array item rules (items)

Item 1

RTIC control and status register space.

Item 2

RTIC recoverable error indication register space.

Minimum number of items (minItems): 1

ranges — not listed as required here

Maximum number of items (maxItems): 1

interrupts — not listed as required here

Maximum number of items (maxItems): 1

#address-cells — not listed as required here

Exact value (const): 1

#size-cells — not listed as required here

Exact value (const): 1

Properties matching a name pattern (patternProperties) #

^rtic-[a-z]@[0-9a-f]+$ — name matches this regular expression

Value type (type): "object"

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

false

Not allowed by this rule.

Run Time Integrity Check (RTIC) Memory Node defines individual RTIC memory regions that are used to perform run-time integrity check of memory areas that should not modified. The node defines a register that contains the memory address & length (combined) and a second register that contains the hash result in big endian format.

Properties and child nodes (properties)

compatible — not listed as required here

Exactly one of these rules must match (oneOf)

Rule 1

Array item rules (items)

Item 1

Exact value (const): "fsl,sec-v5.4-rtic-memory"

Item 2

Exact value (const): "fsl,sec-v5.0-rtic-memory"

Item 3

Exact value (const): "fsl,sec-v4.0-rtic-memory"

Rule 2

Exact value (const): "fsl,sec-v4.0-rtic-memory"

reg — not listed as required here

Array item rules (items)

Item 1

RTIC memory address

Item 2

RTIC hash result

fsl,liodn — not listed as required here

Specifies the LIODN to be used in conjunction with the ppid-to-liodn table that specifies the PPID to LIODN mapping. Needed if the PAMU is used. Value is a 12 bit value where value is a LIODN ID for this JR. This property is normally set by boot firmware.

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

Array item rules (items)

Item 1

Maximum value (maximum): 4095

fsl,rtic-region — not listed as required here

Specifies the HW address (36 bit address) for this region followed by the length of the HW partition to be checked; the address is represented as a 64 bit quantity followed by a 32 bit length.

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

Required in this object (required): "compatible", "reg", "ranges"

Condition (if) #

Properties and child nodes (properties) #

compatible — not listed as required here #

Rule for matching array elements (contains)

Allowed values (enum): "fsl,imx8qm-caam", "fsl,imx8qxp-caam"

When the condition matches (then) #

Required in this object (required): "power-domains"

When the condition does not match (else) #

Properties and child nodes (properties) #

power-domains — not listed as required here #

false — Not permitted by this property rule.

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

false

Not allowed by this rule.

Examples (examples) #

crypto@300000 {
    compatible = "fsl,sec-v4.0";
    #address-cells = <1>;
    #size-cells = <1>;
    reg = <0x300000 0x10000>;
    ranges = <0 0x300000 0x10000>;
    interrupts = <92 2>;

    jr@1000 {
        compatible = "fsl,sec-v4.0-job-ring";
        reg = <0x1000 0x1000>;
        interrupts = <88 2>;
    };

    jr@2000 {
        compatible = "fsl,sec-v4.0-job-ring";
        reg = <0x2000 0x1000>;
        interrupts = <89 2>;
    };

    jr@3000 {
        compatible = "fsl,sec-v4.0-job-ring";
        reg = <0x3000 0x1000>;
        interrupts = <90 2>;
    };

    jr@4000 {
        compatible = "fsl,sec-v4.0-job-ring";
        reg = <0x4000 0x1000>;
        interrupts = <91 2>;
    };

    rtic@6000 {
        compatible = "fsl,sec-v4.0-rtic";
        #address-cells = <1>;
        #size-cells = <1>;
        reg = <0x6000 0x100>;
        ranges = <0x0 0x6100 0xe00>;

        rtic-a@0 {
            compatible = "fsl,sec-v4.0-rtic-memory";
            reg = <0x00 0x20>, <0x100 0x80>;
        };

        rtic-b@20 {
            compatible = "fsl,sec-v4.0-rtic-memory";
            reg = <0x20 0x20>, <0x200 0x80>;
        };

        rtic-c@40 {
            compatible = "fsl,sec-v4.0-rtic-memory";
            reg = <0x40 0x20>, <0x300 0x80>;
        };

        rtic-d@60 {
            compatible = "fsl,sec-v4.0-rtic-memory";
            reg = <0x60 0x20>, <0x500 0x80>;
        };
    };
};

Source notes #

Annotations retained from the schema source

Line 1: SPDX-License-Identifier: GPL-2.0

Line 2: Copyright (C) 2008-2011 Freescale Semiconductor Inc.

Edit this page