Back to home page

OSCL-LXR

 
 

    


0001 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
0002 %YAML 1.2
0003 ---
0004 $id: http://devicetree.org/schemas/spi/rockchip-sfc.yaml#
0005 $schema: http://devicetree.org/meta-schemas/core.yaml#
0006 
0007 title: Rockchip Serial Flash Controller (SFC)
0008 
0009 maintainers:
0010   - Heiko Stuebner <heiko@sntech.de>
0011   - Chris Morgan <macromorgan@hotmail.com>
0012 
0013 allOf:
0014   - $ref: spi-controller.yaml#
0015 
0016 properties:
0017   compatible:
0018     const: rockchip,sfc
0019     description:
0020       The rockchip sfc controller is a standalone IP with version register,
0021       and the driver can handle all the feature difference inside the IP
0022       depending on the version register.
0023 
0024   reg:
0025     maxItems: 1
0026 
0027   interrupts:
0028     maxItems: 1
0029 
0030   clocks:
0031     items:
0032       - description: Bus Clock
0033       - description: Module Clock
0034 
0035   clock-names:
0036     items:
0037       - const: clk_sfc
0038       - const: hclk_sfc
0039 
0040   power-domains:
0041     maxItems: 1
0042 
0043   rockchip,sfc-no-dma:
0044     description: Disable DMA and utilize FIFO mode only
0045     type: boolean
0046 
0047 patternProperties:
0048   "^flash@[0-3]$":
0049     type: object
0050     properties:
0051       reg:
0052         minimum: 0
0053         maximum: 3
0054 
0055 required:
0056   - compatible
0057   - reg
0058   - interrupts
0059   - clocks
0060   - clock-names
0061 
0062 unevaluatedProperties: false
0063 
0064 examples:
0065   - |
0066     #include <dt-bindings/clock/px30-cru.h>
0067     #include <dt-bindings/interrupt-controller/arm-gic.h>
0068     #include <dt-bindings/power/px30-power.h>
0069 
0070     sfc: spi@ff3a0000 {
0071         compatible = "rockchip,sfc";
0072         reg = <0xff3a0000 0x4000>;
0073         interrupts = <GIC_SPI 56 IRQ_TYPE_LEVEL_HIGH>;
0074         clocks = <&cru SCLK_SFC>, <&cru HCLK_SFC>;
0075         clock-names = "clk_sfc", "hclk_sfc";
0076         pinctrl-0 = <&sfc_clk &sfc_cs &sfc_bus2>;
0077         pinctrl-names = "default";
0078         power-domains = <&power PX30_PD_MMC_NAND>;
0079         #address-cells = <1>;
0080         #size-cells = <0>;
0081 
0082         flash@0 {
0083             compatible = "jedec,spi-nor";
0084             reg = <0>;
0085             spi-max-frequency = <108000000>;
0086             spi-rx-bus-width = <2>;
0087             spi-tx-bus-width = <2>;
0088         };
0089     };
0090 
0091 ...