162306a36Sopenharmony_ci* NXP SPI Flash Interface (SPIFI) 262306a36Sopenharmony_ci 362306a36Sopenharmony_ciNXP SPIFI is a specialized SPI interface for serial Flash devices. 462306a36Sopenharmony_ciIt supports one Flash device with 1-, 2- and 4-bits width in SPI 562306a36Sopenharmony_cimode 0 or 3. The controller operates in either command or memory 662306a36Sopenharmony_cimode. In memory mode the Flash is accessible from the CPU as 762306a36Sopenharmony_cinormal memory. 862306a36Sopenharmony_ci 962306a36Sopenharmony_ciRequired properties: 1062306a36Sopenharmony_ci - compatible : Should be "nxp,lpc1773-spifi" 1162306a36Sopenharmony_ci - reg : the first contains the register location and length, 1262306a36Sopenharmony_ci the second contains the memory mapping address and length 1362306a36Sopenharmony_ci - reg-names: Should contain the reg names "spifi" and "flash" 1462306a36Sopenharmony_ci - interrupts : Should contain the interrupt for the device 1562306a36Sopenharmony_ci - clocks : The clocks needed by the SPIFI controller 1662306a36Sopenharmony_ci - clock-names : Should contain the clock names "spifi" and "reg" 1762306a36Sopenharmony_ci 1862306a36Sopenharmony_ciOptional properties: 1962306a36Sopenharmony_ci - resets : phandle + reset specifier 2062306a36Sopenharmony_ci 2162306a36Sopenharmony_ciThe SPI Flash must be a child of the SPIFI node and must have a 2262306a36Sopenharmony_cicompatible property as specified in bindings/mtd/jedec,spi-nor.txt 2362306a36Sopenharmony_ci 2462306a36Sopenharmony_ciOptionally it can also contain the following properties. 2562306a36Sopenharmony_ci - spi-cpol : Controller only supports mode 0 and 3 so either 2662306a36Sopenharmony_ci both spi-cpol and spi-cpha should be present or 2762306a36Sopenharmony_ci none of them 2862306a36Sopenharmony_ci - spi-cpha : See above 2962306a36Sopenharmony_ci - spi-rx-bus-width : Used to select how many pins that are used 3062306a36Sopenharmony_ci for input on the controller 3162306a36Sopenharmony_ci 3262306a36Sopenharmony_ciSee bindings/spi/spi-bus.txt for more information. 3362306a36Sopenharmony_ci 3462306a36Sopenharmony_ciExample: 3562306a36Sopenharmony_cispifi: spifi@40003000 { 3662306a36Sopenharmony_ci compatible = "nxp,lpc1773-spifi"; 3762306a36Sopenharmony_ci reg = <0x40003000 0x1000>, <0x14000000 0x4000000>; 3862306a36Sopenharmony_ci reg-names = "spifi", "flash"; 3962306a36Sopenharmony_ci interrupts = <30>; 4062306a36Sopenharmony_ci clocks = <&ccu1 CLK_SPIFI>, <&ccu1 CLK_CPU_SPIFI>; 4162306a36Sopenharmony_ci clock-names = "spifi", "reg"; 4262306a36Sopenharmony_ci resets = <&rgu 53>; 4362306a36Sopenharmony_ci 4462306a36Sopenharmony_ci flash@0 { 4562306a36Sopenharmony_ci compatible = "jedec,spi-nor"; 4662306a36Sopenharmony_ci spi-cpol; 4762306a36Sopenharmony_ci spi-cpha; 4862306a36Sopenharmony_ci spi-rx-bus-width = <4>; 4962306a36Sopenharmony_ci #address-cells = <1>; 5062306a36Sopenharmony_ci #size-cells = <1>; 5162306a36Sopenharmony_ci 5262306a36Sopenharmony_ci partition@0 { 5362306a36Sopenharmony_ci label = "data"; 5462306a36Sopenharmony_ci reg = <0 0x200000>; 5562306a36Sopenharmony_ci }; 5662306a36Sopenharmony_ci }; 5762306a36Sopenharmony_ci}; 5862306a36Sopenharmony_ci 59