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.

SPI0 transfer BIT ERROR with AM1808/OMAPL138

Other Parts Discussed in Thread: AM1808, OMAPL138, DA8XX

Hi dears:

        I was used AM1808/OMAPL138 spi0 to connect FRAM;  I was successed register SPI0 in my deriver ; but when I attempted to transfer data and I  encountered " SPI BIT error in SPIFLG register; 

here's for my code snippet 

static struct spi_board_info __initdata da850_spi0_board_info[] = {

{
.modalias = "fm25cl64",
.platform_data = &spi_fram_data,
.mode = SPI_MODE_0,
.max_speed_hz = 30000000, /* max sample rate at 3V */
.bus_num = 0,
.chip_select = 2,
},
};

ret = da8xx_pinmux_setup(da850_spi0_pins);
if (ret)
pr_warning("da850_evm_init: spi0 mux setup failed: %d\n", ret);

da850_init_spi0(BIT(3), da850_spi0_board_info,ARRAY_SIZE(da850_spi0_board_info));

static struct davinci_spi_platform_data da850_spi0_pdata = {
.version = SPI_VERSION_2,
.num_chipselect = 3,
.wdelay = 0,
.odd_parity = 0,
.parity_enable = 0,
.wait_enable = 0,
.timer_disable = 0,
.clk_internal = 1,
.cs_hold = 1,
.intr_level = 0,
.poll_mode = 1,
//.use_dma = 1,
.use_dma = 0,
.c2tdelay = 8,
.t2cdelay = 8,
};

static struct resource da850_spi0_resources[] = {
[0] = {
.start = 0x01C41000,
.end = 0x01C41000 + 0xfff,
.flags = IORESOURCE_MEM,
},
[1] = {
.start = IRQ_DA8XX_SPINT0,
.end = IRQ_DA8XX_SPINT0,
.flags = IORESOURCE_IRQ,
},

[2] = {
.start = EDMA_CTLR_CHAN(0, 14),
.end = EDMA_CTLR_CHAN(0, 14),
.flags = IORESOURCE_DMA,
},
[3] = {
.start = EDMA_CTLR_CHAN(0, 15),
.end = EDMA_CTLR_CHAN(0, 15),
.flags = IORESOURCE_DMA,
},
[4] = {
.start = 1,
.end = 1,
.flags = IORESOURCE_DMA,
},
};


static struct platform_device da850_spi0_device = {
.name = "spi_davinci",
.id = 0,
.resource = da850_spi0_resources,
.num_resources = ARRAY_SIZE(da850_spi0_resources),
.dev = {
.platform_data = &da850_spi0_pdata,
},
};
void __init da850_init_spi0(unsigned chipselect_mask,
struct spi_board_info *info, unsigned len)
{
spi_register_board_info(info, len);
platform_device_register(&da850_spi0_device);
}

what's wrong with it? 

regards 

 jio