Tool/software: Linux
Hello,everybody! Recently, i tried to use a 256K*16bits SRAM,here is the devicetree settings:
&gpmc {
/*
* When enabling GPMC, disable eMMC and set
* SelEMMCorNAND to output-low
*/
status = "okay";
pinctrl-names = "default", "sleep";
pinctrl-0 = <&nand_flash_x8_default &sram_x16_default>;
pinctrl-1 = <&nand_flash_x8_sleep>;
#address-cells = <2>;
#size-cells = <1>;
ranges = <0 0 0x08000000 0x01000000>, /* CS0 nand. Min partition = 16MB */
<1 0 0x01000000 0x01000000>; /* CS1 sram. Min partition = 16MB */
#if 1
nand@0,0 {
compatible = "ti,omap2-nand";
reg = <0 0 4>; /* device IO registers */
interrupt-parent = <&gpmc>;
interrupts = <0 IRQ_TYPE_NONE>, /* fifoevent */
<1 IRQ_TYPE_NONE>; /* termcount */
rb-gpios = <&gpmc 0 GPIO_ACTIVE_HIGH>; /* gpmc_wait0 */
ti,nand-ecc-opt = "bch16";
ti,elm-id = <&elm>;
nand-bus-width = <8>;
gpmc,device-width = <1>;
gpmc,sync-clk-ps = <0>;
gpmc,cs-on-ns = <0>;
gpmc,cs-rd-off-ns = <40>;
gpmc,cs-wr-off-ns = <40>;
gpmc,adv-on-ns = <0>;
gpmc,adv-rd-off-ns = <25>;
gpmc,adv-wr-off-ns = <25>;
gpmc,we-on-ns = <0>;
gpmc,we-off-ns = <20>;
gpmc,oe-on-ns = <3>;
gpmc,oe-off-ns = <30>;
gpmc,access-ns = <30>;
gpmc,rd-cycle-ns = <40>;
gpmc,wr-cycle-ns = <40>;
gpmc,bus-turnaround-ns = <0>;
gpmc,cycle2cycle-delay-ns = <0>;
gpmc,clk-activation-ns = <0>;
gpmc,wr-access-ns = <40>;
gpmc,wr-data-mux-bus-ns = <0>;
/* MTD partition table */
/* All SPL-* partitions are sized to minimal length
* 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 0x00040000>;
};
partition@1 {
label = "NAND.SPL.backup1";
reg = <0x00040000 0x00040000>;
};
partition@2 {
label = "NAND.SPL.backup2";
reg = <0x00080000 0x00040000>;
};
partition@3 {
label = "NAND.SPL.backup3";
reg = <0x000c0000 0x00040000>;
};
partition@4 {
label = "NAND.u-boot-spl-os";
reg = <0x00100000 0x00080000>;
};
partition@5 {
label = "NAND.u-boot";
reg = <0x00180000 0x00100000>;
};
partition@6 {
label = "NAND.u-boot-env";
reg = <0x00280000 0x00040000>;
};
partition@7 {
label = "NAND.u-boot-env.backup1";
reg = <0x002c0000 0x00040000>;
};
partition@8 {
label = "NAND.kernel";
reg = <0x00300000 0x00700000>;
};
partition@9 {
label = "NAND.file-system";
reg = <0x00a00000 0x1f600000>;
};
};
#endif
sram{
reg = <1 0 0x01000000>; /*CSn1*/
bank-width = <2>;
gpmc,cs-on-ns = <0>;
gpmc,cs-rd-off-ns = <56>;/*Tca+Tas*/
gpmc,cs-wr-off-ns = <55>;
gpmc,adv-on-ns = <0>; /*Tas*/
gpmc,adv-rd-off-ns = <110>;
gpmc,adv-wr-off-ns = <110>;
gpmc,we-on-ns = <0>;
gpmc,we-off-ns = <55>;
gpmc,oe-on-ns = <40>;
gpmc,oe-off-ns = <0>;
gpmc,access-ns = <50>;
gpmc,rd-cycle-ns = <110>;
gpmc,wr-cycle-ns = <110>;
};
};
The sram is connected to the cs1.According to the setting,it should be found in the /proc/iomem,but i found nothing.Is there something i configed wrong?