The SD/SDIO/eMMC host controller for Loongson-2K family SoCs
Schema identifier ($id): "http://devicetree.org/schemas/mmc/loongson,ls2k0500-mmc.yaml#"
Schema dialect ($schema): "http://devicetree.org/meta-schemas/core.yaml#"
The MMC host controller on the Loongson-2K0500/2K1000 (using an externally shared apbdma controller) provides the SD and SDIO device interfaces. The two MMC host controllers on the Loongson-2K2000 are similar, except that they use internal exclusive DMA. one controller provides the eMMC interface and the other provides the SD/SDIO interface.
Maintainers (maintainers): "Binbin Zhou <zhoubinbin@loongson.cn>"
All of these rules must match (allOf) #
Rule 1 #
Shared schema rule (
$ref):mmc-controller.yaml#
Properties and child nodes (properties) #
compatible — required here #
Allowed values (enum): "loongson,ls2k0500-mmc", "loongson,ls2k1000-mmc", "loongson,ls2k2000-mmc"
reg — required here #
Minimum number of items (minItems): 1
Array item rules (items) #
Item 1
Loongson-2K MMC controller registers.
Item 2
APB DMA config register for Loongson-2K MMC controller.
interrupts — required here #
Maximum number of items (maxItems): 1
clocks — required here #
Maximum number of items (maxItems): 1
dmas — not listed as required here #
Maximum number of items (maxItems): 1
dma-names — not listed as required here #
Exact value (const): "rx-tx"
Required in this object (required): "compatible", "reg", "interrupts", "clocks"
Properties not evaluated by applicable rules (unevaluatedProperties) #
false
Not allowed by this rule.
Condition (if) #
Properties and child nodes (
properties) #
compatible— not listed as required here #Rule for matching array elements (
contains)Allowed values (
enum):"loongson,ls2k0500-mmc","loongson,ls2k1000-mmc"
When the condition matches (then) #
Properties and child nodes (
properties) #
reg— not listed as required here #Minimum number of items (
minItems):2
When the condition does not match (else) #
Properties and child nodes (
properties) #
reg— not listed as required here #Maximum number of items (
maxItems):1
Examples (examples) #
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/clock/loongson,ls2k-clk.h>
mmc@1fe2c000 {
compatible = "loongson,ls2k1000-mmc";
reg = <0x1fe2c000 0x68>,
<0x1fe00438 0x8>;
interrupt-parent = <&liointc0>;
interrupts = <31 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&clk LOONGSON2_APB_CLK>;
dmas = <&apbdma1 0>;
dma-names = "rx-tx";
bus-width = <4>;
cd-gpios = <&gpio0 22 GPIO_ACTIVE_LOW>;
};
#include <dt-bindings/interrupt-controller/irq.h>
#include <dt-bindings/clock/loongson,ls2k-clk.h>
mmc@79990000 {
compatible = "loongson,ls2k2000-mmc";
reg = <0x79990000 0x1000>;
interrupt-parent = <&pic>;
interrupts = <51 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&clk LOONGSON2_EMMC_CLK>;
bus-width = <8>;
non-removable;
cap-mmc-highspeed;
mmc-hs200-1_8v;
no-sd;
no-sdio;
};
Source notes #
Annotations retained from the schema source
Line 1: SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)