本帖最后由 一只耳朵怪 于 2018-6-21 11:09 编辑
各位好,公司有款产品用到了
ti的am335x系列处理器,在移植Linux时,查看了官方的SDK里的这个文件:
- arch/ARM/boot/dts/am335x-evm.dts,其中关于nandflash的一段如下(时序部分更改过):
- &gpmc [ status = "okay"; pinctrl-names = "default"; pinctrl-0 = <&nandflash_pins_s0>; ranges = <0 0 0x08000000 0x10000000>; /* CS0: 256MB for NAND */ nand@0,0 [ compatible = "ti,omap2-nand"; reg = <0 0 4>; /* CS0, offset 0, IO size 4 */ interrupt-parent = <&gpmc>; interrupts = <0 IRQ_TYPE_NONE>, /* fifoevent */ <1 IRQ_TYPE_NONE>; /* termcount */ rb-gpios = <&gpmc 1 GPIO_ACTIVE_HIGH>; /* gpmc_wait0 */ ti,nand-ecc-opt = "bch8"; ti,elm-id = <&elm>; nand-bus-width = <16>; gpmc,device-width = <1>; gpmc,sync-clk-ps = <0>; gpmc,cs-on-ns = <0>; gpmc,cs-rd-off-ns = <6>; gpmc,cs-wr-off-ns = <6>; gpmc,adv-on-ns = <0>; gpmc,adv-rd-off-ns = <8>; gpmc,adv-wr-off-ns = <8>; gpmc,we-on-ns = <1>; gpmc,we-off-ns = <3>; gpmc,oe-on-ns = <1>; gpmc,oe-off-ns = <3>; gpmc,access-ns = <5>; gpmc,rd-cycle-ns = <6>; gpmc,wr-cycle-ns = <5>; gpmc,bus-turnaround-ns = <0>; gpmc,cycle2cycle-delay-ns = <4>; gpmc,clk-activation-ns = <0>; gpmc,wr-access-ns = <5>; gpmc,wr-data-mux-bus-ns = <0>; /* MTD partition table */ /* All SPL-* partitions are sized to minimal length * which can be independently programmable. For * which can be independently programmable. For * NAND flash this is equal to size of erase-block */ #address-cells = <1>; #size-cells = <1>; partition@0 [ label = "NAND.SPL"; reg = <0x00000000 0x000020000>; ]; partition@1 [ label = "NAND.SPL.backup1"; reg = <0x00020000 0x00020000>; ]; partition@2 [ label = "NAND.SPL.backup2"; reg = <0x00040000 0x00020000>; ]; partition@3 [ label = "NAND.SPL.backup3"; reg = <0x00060000 0x00020000>; ]; partition@4 [ label = "NAND.u-boot-spl-os"; reg = <0x00080000 0x00040000>; ]; partition@5 [ label = "NAND.u-boot"; reg = <0x000C0000 0x00100000>; ]; partition@6 [ label = "NAND.u-boot-env"; reg = <0x001C0000 0x00020000>; ]; partition@7 [ label = "NAND.u-boot-env.backup1"; reg = <0x001E0000 0x00020000>; ]; partition@8 [ label = "NAND.kernel"; reg = <0x00200000 0x00800000>; ]; partition@9 [ label = "NAND.file-system"; reg = <0x00A00000 0x0F600000>; ]; ];];
- 请问,其中的 reg = <0 0 4>; /* CS0, offset 0, IO size 4 */,
这句话中的 “ IO size 4”是什么意思?百思不得其解。。。。
望各位赐教 !!!