AnsweredAssumed Answered

SPI Burst Transfer in linux imx6

Question asked by Kunal Kotecha on Feb 13, 2017
Latest reply on Feb 14, 2017 by igorpadykov

Hello all,

 

I am using imx6ull on a custom board with linux 4.1.15 and currently working on SPI peripheral. I am using IMX6ULL as a Master and DTS for the same is as below :

&ecspi2 {
status = "okay";
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_ecspi2>;
fsl,spi-num-chipselects = <1>;
cs-gpios = <&gpio1 29 0>;
   spidev1: spi@1 {
      reg = <0>;
      compatible = "spidev";
      spi-max-frequency = <250000>;
      status = "okay";
   };

};

We used spidev.c as driver for interfacing and did 1 change in it as below:

static const struct of_device_id spidev_dt_ids[] = {
      { .compatible = "rohm,dh2228fv" },
      { .compatible = "spidev" },
      {},
};
and found the device node as /dev/spidev1.0.

It is working properly and able to see pulses of all the pins properly. But We want to transfer more than 1 byte at a time. So in Burst transfer, we are not getting continuous clock pulse and chip select. Hence, at every byte, CS deactivates and then activates again. I tried by cs_change = 0, but still facing issue. Please help me out of it to disable toggling of CS at every byte transfer? 

Outcomes