Sram bindings
Single-page view · as markdown
Allwinner A10 System Control
Peios Kernel / Hardware and drivers / Device-tree binding reference / Sram bindings
Schema identifier ($id): "http://devicetree.org/schemas/sram/allwinner,sun4i-a10-system-control.yaml#"
Schema dialect ($schema): "http://devicetree.org/meta-schemas/core.yaml#"
Maintainers (maintainers): "Chen-Yu Tsai <wens@csie.org>", "Maxime Ripard <mripard@kernel.org>"
The SRAM controller found on most Allwinner devices is represented by a regular node for the SRAM controller itself, with sub-nodes representing the SRAM handled by the SRAM controller.
Properties and child nodes (properties) #
#address-cells — required here #
Exact value (const): 1
#size-cells — required here #
Exact value (const): 1
compatible — required here #
Exactly one of these rules must match (oneOf) #
Rule 1
Allowed values (
enum):"allwinner,sun4i-a10-sram-controller","allwinner,sun50i-a64-sram-controller"Deprecated (
deprecated):true
Rule 2
Allowed values (
enum):"allwinner,sun4i-a10-system-control","allwinner,sun5i-a13-system-control","allwinner,sun8i-a23-system-control","allwinner,sun8i-h3-system-control","allwinner,sun20i-d1-system-control","allwinner,sun50i-a64-system-control","allwinner,sun50i-h5-system-control","allwinner,sun50i-h616-system-control"
Rule 3
Array item rules (
items)Item 1
Allowed values (
enum):"allwinner,suniv-f1c100s-system-control","allwinner,sun7i-a20-system-control","allwinner,sun8i-r40-system-control"Item 2
Exact value (
const):"allwinner,sun4i-a10-system-control"
Rule 4
Array item rules (
items)Item 1
Exact value (
const):"allwinner,sun8i-v3s-system-control"Item 2
Exact value (
const):"allwinner,sun8i-h3-system-control"
Rule 5
Array item rules (
items)Item 1
Allowed values (
enum):"allwinner,sun50i-a100-system-control","allwinner,sun50i-h6-system-control","allwinner,sun55i-a523-system-control"Item 2
Exact value (
const):"allwinner,sun50i-a64-system-control"
reg — required here #
Maximum number of items (maxItems): 1
ranges — not listed as required here #
true — No constraints added by this property rule.
Properties matching a name pattern (patternProperties) #
^regulators@[0-9a-f]+$ — name matches this regular expression #
Shared schema rule ($ref): /schemas/regulator/allwinner,sun20i-d1-system-ldos.yaml#
^sram@[a-f0-9]+ — name matches this regular expression #
Shared schema rule ($ref): /schemas/sram/sram.yaml#
Properties not evaluated by applicable rules (unevaluatedProperties) #
false
Not allowed by this rule.
Properties matching a name pattern (patternProperties) #
^sram-section?@[a-f0-9]+$ — 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.
Properties and child nodes (properties)
reg — not listed as required here
true — No constraints added by this property rule.
compatible — not listed as required here
Exactly one of these rules must match (oneOf)
Rule 1
Exact value (
const):"allwinner,sun4i-a10-sram-a3-a4"
Rule 2
Exact value (
const):"allwinner,sun4i-a10-sram-c1"
Rule 3
Exact value (
const):"allwinner,sun4i-a10-sram-d"
Rule 4
Exact value (
const):"allwinner,sun50i-a64-sram-c"
Rule 5
Array item rules (
items)Item 1
Allowed values (
enum):"allwinner,sun5i-a13-sram-a3-a4","allwinner,sun7i-a20-sram-a3-a4"Item 2
Exact value (
const):"allwinner,sun4i-a10-sram-a3-a4"
Rule 6
Array item rules (
items)Item 1
Allowed values (
enum):"allwinner,sun5i-a13-sram-c1","allwinner,sun7i-a20-sram-c1","allwinner,sun8i-a23-sram-c1","allwinner,sun8i-h3-sram-c1","allwinner,sun8i-r40-sram-c1","allwinner,sun50i-a64-sram-c1","allwinner,sun50i-h5-sram-c1","allwinner,sun50i-h6-sram-c1"Item 2
Exact value (
const):"allwinner,sun4i-a10-sram-c1"
Rule 7
Array item rules (
items)Item 1
Allowed values (
enum):"allwinner,suniv-f1c100s-sram-d","allwinner,sun5i-a13-sram-d","allwinner,sun7i-a20-sram-d"Item 2
Exact value (
const):"allwinner,sun4i-a10-sram-d"
Rule 8
Array item rules (
items)Item 1
Exact value (
const):"allwinner,sun50i-h6-sram-c"Item 2
Exact value (
const):"allwinner,sun50i-a64-sram-c"
Required in this object (required): "#address-cells", "#size-cells", "compatible", "reg"
Properties not matched by properties or patternProperties in this schema (additionalProperties) #
false
Not allowed by this rule.
Examples (examples) #
system-control@1c00000 {
compatible = "allwinner,sun4i-a10-system-control";
reg = <0x01c00000 0x30>;
#address-cells = <1>;
#size-cells = <1>;
ranges;
sram_a: sram@0 {
compatible = "mmio-sram";
reg = <0x00000000 0xc000>;
#address-cells = <1>;
#size-cells = <1>;
ranges = <0 0x00000000 0xc000>;
emac_sram: sram-section@8000 {
compatible = "allwinner,sun4i-a10-sram-a3-a4";
reg = <0x8000 0x4000>;
};
};
};
syscon@3000000 {
compatible = "allwinner,sun20i-d1-system-control";
reg = <0x3000000 0x1000>;
ranges;
#address-cells = <1>;
#size-cells = <1>;
regulators@3000150 {
compatible = "allwinner,sun20i-d1-system-ldos";
reg = <0x3000150 0x4>;
reg_ldoa: ldoa {
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;
};
reg_ldob: ldob {
regulator-name = "vcc-dram";
regulator-min-microvolt = <1500000>;
regulator-max-microvolt = <1500000>;
};
};
};
Source notes #
Annotations retained from the schema source
Line 1: SPDX-License-Identifier: GPL-2.0+
Qualcomm IMEM memory region
Peios Kernel / Hardware and drivers / Device-tree binding reference / Sram bindings
Schema identifier ($id): "http://devicetree.org/schemas/sram/qcom,imem.yaml#"
Schema dialect ($schema): "http://devicetree.org/meta-schemas/core.yaml#"
Maintainers (maintainers): "Bjorn Andersson <bjorn.andersson@linaro.org>"
Qualcomm IMEM is dedicated memory region for various debug features and DMA transactions.
Properties and child nodes (properties) #
compatible — required here #
Array item rules (items) #
Item 1
Allowed values (
enum):"qcom,apq8064-imem","qcom,ipq5424-imem","qcom,msm8226-imem","qcom,msm8974-imem","qcom,msm8976-imem","qcom,qcs404-imem","qcom,qcs615-imem","qcom,qcs8300-imem","qcom,qdu1000-imem","qcom,sa8775p-imem","qcom,sar2130p-imem","qcom,sc7180-imem","qcom,sc7280-imem","qcom,sc8280xp-imem","qcom,sdm630-imem","qcom,sdm845-imem","qcom,sdx55-imem","qcom,sdx65-imem","qcom,sdx75-imem","qcom,sm6115-imem","qcom,sm6125-imem","qcom,sm6350-imem","qcom,sm6375-imem","qcom,sm7150-imem","qcom,sm8150-imem","qcom,sm8250-imem","qcom,sm8350-imem","qcom,sm8450-imem","qcom,sm8550-imem","qcom,sm8650-imem","qcom,sm8750-imem","qcom,x1e80100-imem"
Item 2
Exact value (
const):"syscon"
Item 3
Exact value (
const):"simple-mfd"
reg — required here #
Maximum number of items (maxItems): 1
ranges — not listed as required here #
true — No constraints added by this property rule.
#address-cells — not listed as required here #
Exact value (const): 1
#size-cells — not listed as required here #
Exact value (const): 1
reboot-mode — not listed as required here #
Shared schema rule ($ref): /schemas/power/reset/syscon-reboot-mode.yaml#
Properties matching a name pattern (patternProperties) #
^pil-reloc@[0-9a-f]+$ — name matches this regular expression #
Shared schema rule ($ref): /schemas/remoteproc/qcom,pil-info.yaml#
Peripheral image loader relocation region
Required in this object (required): "compatible", "reg"
Properties not matched by properties or patternProperties in this schema (additionalProperties) #
false
Not allowed by this rule.
Examples (examples) #
soc {
#address-cells = <2>;
#size-cells = <2>;
sram@146bf000 {
compatible = "qcom,sdm845-imem", "syscon", "simple-mfd";
reg = <0 0x146bf000 0 0x1000>;
ranges = <0 0 0x146bf000 0x1000>;
#address-cells = <1>;
#size-cells = <1>;
pil-reloc@94c {
compatible = "qcom,pil-reloc-info";
reg = <0x94c 0xc8>;
};
};
};
Source notes #
Annotations retained from the schema source
Line 1: SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
On Chip Memory (OCMEM) that is present on some Qualcomm Snapdragon SoCs.
Peios Kernel / Hardware and drivers / Device-tree binding reference / Sram bindings
Schema identifier ($id): "http://devicetree.org/schemas/sram/qcom,ocmem.yaml#"
Schema dialect ($schema): "http://devicetree.org/meta-schemas/core.yaml#"
Maintainers (maintainers): "Brian Masney <masneyb@onstation.org>"
The On Chip Memory (OCMEM) is typically used by the GPU, camera/video, and audio components on some Snapdragon SoCs.
Properties and child nodes (properties) #
compatible — required here #
Allowed values (enum): "qcom,msm8226-ocmem", "qcom,msm8974-ocmem"
reg — required here #
Array item rules (items) #
Item 1
Control registers
Item 2
OCMEM address range
reg-names — required here #
Array item rules (items) #
Item 1
Exact value (
const):"ctrl"
Item 2
Exact value (
const):"mem"
clocks — required here #
Minimum number of items (minItems): 1
Array item rules (items) #
Item 1
Core clock
Item 2
Interface clock
clock-names — required here #
Minimum number of items (minItems): 1
Array item rules (items) #
Item 1
Exact value (
const):"core"
Item 2
Exact value (
const):"iface"
#address-cells — required here #
Exact value (const): 1
#size-cells — required here #
Exact value (const): 1
ranges — required here #
Maximum number of items (maxItems): 1
Required in this object (required): "compatible", "reg", "reg-names", "clocks", "clock-names", "#address-cells", "#size-cells", "ranges"
Properties not matched by properties or patternProperties in this schema (additionalProperties) #
false
Not allowed by this rule.
All of these rules must match (allOf) #
Rule 1 #
Condition (
if) #Properties and child nodes (
properties)
compatible— not listed as required hereRule for matching array elements (
contains)When the condition matches (
then) #Properties and child nodes (
properties)
clocks— not listed as required hereMinimum number of items (
minItems):2
clock-names— not listed as required hereMinimum number of items (
minItems):2When the condition does not match (
else) #Properties and child nodes (
properties)
clocks— not listed as required hereMinimum number of items (
minItems):1
clock-names— not listed as required hereMinimum number of items (
minItems):1
Properties matching a name pattern (patternProperties) #
-sram@[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.
A region of reserved memory.
Properties and child nodes (properties) #
reg — required here
Maximum number of items (maxItems): 1
Required in this object (required): "reg"
Examples (examples) #
#include <dt-bindings/clock/qcom,rpmcc.h>
#include <dt-bindings/clock/qcom,mmcc-msm8974.h>
sram@fdd00000 {
compatible = "qcom,msm8974-ocmem";
reg = <0xfdd00000 0x2000>,
<0xfec00000 0x180000>;
reg-names = "ctrl",
"mem";
clocks = <&rpmcc RPM_SMD_OCMEMGX_CLK>,
<&mmcc OCMEMCX_OCMEMNOC_CLK>;
clock-names = "core",
"iface";
#address-cells = <1>;
#size-cells = <1>;
ranges = <0 0xfec00000 0x100000>;
gmu-sram@0 {
reg = <0x0 0x100000>;
};
};
Source notes #
Annotations retained from the schema source
Line 1: SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
Line 19: v1.1.0
Line 20: v1.4.0
Generic on-chip SRAM
Peios Kernel / Hardware and drivers / Device-tree binding reference / Sram bindings
Schema identifier ($id): "http://devicetree.org/schemas/sram/sram.yaml#"
Schema dialect ($schema): "http://devicetree.org/meta-schemas/core.yaml#"
Maintainers (maintainers): "Rob Herring <robh@kernel.org>"
Simple IO memory regions to be managed by the genalloc API.
Each child of the sram node specifies a region of reserved memory. Each child node should use a 'reg' property to specify a specific range of reserved memory.
Following the generic-names recommended practice, node names should reflect the purpose of the node. Unit address (@<address>) should be appended to the name.
Properties and child nodes (properties) #
$nodename — not listed as required here #
String pattern (pattern): "^sram(@.*)?"
compatible — required here #
Rule for matching array elements (contains) #
Allowed values (
enum):"mmio-sram","amlogic,meson-gxbb-sram","arm,juno-sram-ns","atmel,sama5d2-securam","nvidia,tegra186-sysram","nvidia,tegra194-sysram","nvidia,tegra234-sysram","qcom,kaanapali-imem","qcom,rpm-msg-ram","rockchip,rk3288-pmu-sram"
reg — required here #
Maximum number of items (maxItems): 1
clocks — not listed as required here #
Maximum number of items (maxItems): 1
A list of phandle and clock specifier pair that controls the single SRAM clock.
#address-cells — not listed as required here #
Exact value (const): 1
#size-cells — not listed as required here #
Exact value (const): 1
ranges — not listed as required here #
Maximum number of items (maxItems): 1
Should translate from local addresses within the sram to bus addresses.
no-memory-wc — not listed as required here #
The flag indicating, that SRAM memory region has not to be remapped as write combining. WC is used by default.
Value type (type): "boolean"
Properties matching a name pattern (patternProperties) #
^([a-z0-9]*-)?sram(-section)?@[a-f0-9]+$ — name matches this regular expression #
Value type (type): "object"
Each child of the sram node specifies a region of reserved memory.
Properties and child nodes (properties) #
compatible — not listed as required here
Should contain a vendor specific string in the form <vendor>,[<device>-]<usage>
Rule for matching array elements (contains)
Allowed values (
enum):"allwinner,sun4i-a10-sram-a3-a4","allwinner,sun4i-a10-sram-c1","allwinner,sun4i-a10-sram-d","allwinner,sun9i-a80-smp-sram","allwinner,sun50i-a64-sram-c","amlogic,meson8-ao-arc-sram","amlogic,meson8b-ao-arc-sram","amlogic,meson8-smp-sram","amlogic,meson8b-smp-sram","amlogic,meson-gxbb-scp-shmem","amlogic,meson-axg-scp-shmem","arm,juno-scp-shmem","arm,scmi-shmem","arm,scp-shmem","qcom,pil-reloc-info","renesas,smp-sram","rockchip,rk3066-smp-sram","samsung,exynos4210-sysram","samsung,exynos4210-sysram-ns","socionext,milbeaut-smp-sram","stericsson,u8500-esram"
reg — required here
IO mem address range, relative to the SRAM range.
Maximum number of items (maxItems): 1
reg-io-width — not listed as required here
The size (in bytes) of the IO accesses that should be performed on the SRAM.
Allowed values (enum): 1, 2, 4, 8
pool — not listed as required here
Indicates that the particular reserved SRAM area is addressable and in use by another device or devices.
Value type (type): "boolean"
export — not listed as required here
Indicates that the reserved SRAM area may be accessed outside of the kernel, e.g. by bootloader or userspace.
Value type (type): "boolean"
protect-exec — not listed as required here
Same as 'pool' above but with the additional constraint that code will be run from the region and that the memory is maintained as read-only, executable during code execution. NOTE: This region must be page aligned on start and end in order to properly allow manipulation of the page attributes.
Value type (type): "boolean"
label — not listed as required here
The name for the reserved partition, if omitted, the label is taken from the node name excluding the unit address.
Required in this object (required): "reg"
Properties not matched by properties or patternProperties in this schema (additionalProperties) #
false
Not allowed by this rule.
Required in this object (required): "compatible", "reg"
Condition (if) #
This rule must not match (
not) #Properties and child nodes (
properties) #
compatible— not listed as required hereRule for matching array elements (
contains)Allowed values (
enum):"qcom,rpm-msg-ram","rockchip,rk3288-pmu-sram"
When the condition matches (then) #
Required in this object (
required):"#address-cells","#size-cells","ranges"
Properties not matched by properties or patternProperties in this schema (additionalProperties) #
false
Not allowed by this rule.
Examples (examples) #
sram@5c000000 {
compatible = "mmio-sram";
reg = <0x5c000000 0x40000>; /* 256 KiB SRAM at address 0x5c000000 */
#address-cells = <1>;
#size-cells = <1>;
ranges = <0 0x5c000000 0x40000>;
smp-sram@100 {
reg = <0x100 0x50>;
};
device-sram@1000 {
reg = <0x1000 0x1000>;
pool;
};
exported-sram@20000 {
reg = <0x20000 0x20000>;
export;
};
};
// Samsung SMP-capable Exynos SoCs use part of the SYSRAM for the bringup
// of the secondary cores. Once the core gets powered up it executes the
// code that is residing at some specific location of the SYSRAM.
//
// Therefore reserved section sub-nodes have to be added to the mmio-sram
// declaration. These nodes are of two types depending upon secure or
// non-secure execution environment.
sram@2020000 {
compatible = "mmio-sram";
reg = <0x02020000 0x54000>;
#address-cells = <1>;
#size-cells = <1>;
ranges = <0 0x02020000 0x54000>;
smp-sram@0 {
compatible = "samsung,exynos4210-sysram";
reg = <0x0 0x1000>;
};
smp-sram@53000 {
compatible = "samsung,exynos4210-sysram-ns";
reg = <0x53000 0x1000>;
};
};
// Amlogic's SMP-capable SoCs use part of the sram for the bringup of the cores.
// Once the core gets powered up it executes the code that is residing at a
// specific location.
//
// Therefore a reserved section sub-node has to be added to the mmio-sram
// declaration.
sram@d9000000 {
compatible = "mmio-sram";
reg = <0xd9000000 0x20000>;
#address-cells = <1>;
#size-cells = <1>;
ranges = <0 0xd9000000 0x20000>;
smp-sram@1ff80 {
compatible = "amlogic,meson8b-smp-sram";
reg = <0x1ff80 0x8>;
};
};
sram@e63c0000 {
compatible = "mmio-sram";
reg = <0xe63c0000 0x1000>;
#address-cells = <1>;
#size-cells = <1>;
ranges = <0 0xe63c0000 0x1000>;
smp-sram@0 {
compatible = "renesas,smp-sram";
reg = <0 0x10>;
};
};
sram@10080000 {
compatible = "mmio-sram";
reg = <0x10080000 0x10000>;
#address-cells = <1>;
#size-cells = <1>;
ranges;
smp-sram@10080000 {
compatible = "rockchip,rk3066-smp-sram";
reg = <0x10080000 0x50>;
};
};
// Rockchip's rk3288 SoC uses the sram of pmu to store the function of
// resume from maskrom(the 1st level loader). This is a common use of
// the "pmu-sram" because it keeps power even in low power states
// in the system.
sram@ff720000 {
compatible = "rockchip,rk3288-pmu-sram", "mmio-sram";
reg = <0xff720000 0x1000>;
};
// Allwinner's A80 SoC uses part of the secure sram for hotplugging of the
// primary core (cpu0). Once the core gets powered up it checks if a magic
// value is set at a specific location. If it is then the BROM will jump
// to the software entry address, instead of executing a standard boot.
//
// Also there are no "secure-only" properties. The implementation should
// check if this SRAM is usable first.
sram@20000 {
// 256 KiB secure SRAM at 0x20000
compatible = "mmio-sram";
reg = <0x00020000 0x40000>;
#address-cells = <1>;
#size-cells = <1>;
ranges = <0 0x00020000 0x40000>;
smp-sram@1000 {
// This is checked by BROM to determine if
// cpu0 should jump to SMP entry vector
compatible = "allwinner,sun9i-a80-smp-sram";
reg = <0x1000 0x8>;
};
};
sram@0 {
compatible = "mmio-sram";
reg = <0x0 0x10000>;
#address-cells = <1>;
#size-cells = <1>;
ranges = <0 0x0 0x10000>;
smp-sram@f100 {
compatible = "socionext,milbeaut-smp-sram";
reg = <0xf100 0x20>;
};
};
Source notes #
Annotations retained from the schema source
Line 1: SPDX-License-Identifier: GPL-2.0