This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux/AM3352: GPMC configuration

Part Number: AM3352


Tool/software: Linux

Hi,

SDK:linux3.2SDK

The customer connected a 8-bit parallel device with GPMC. Below is the configuration.

gpmc_cs_write_reg(cs,GPMC_CS_CONFIG1, 0x0);

gpmc_cs_configure(cs, GPMC_CONFIG_DEV_TYPE, GPMC_DEVICETYPE_NOR);
val = gpmc_cs_read_reg(cs,GPMC_CS_CONFIG1);

val |= GPMC_CONFIG1_READTYPE_SYNC;
val |= GPMC_CONFIG1_WRITETYPE_SYNC;
gpmc_cs_write_reg(cs, GPMC_CS_CONFIG1, val);
gpmc_cs_set_timings(cs, &uc_timing);
gpmc_cs_request(cs, SZ_16M, &mem_base_phys);

if (!request_mem_region(mem_base_phys,SZ_16M, "UC")) {
ret = -EBUSY;
goto ERR;
}

mmio = ioremap((mem_base_phys,SZ_16M);

offset = 0x800;
__raw_writeb(0XE2,mmio+offset);——>error:Segmentation fault

What may cause that error? Please help analyze.