Re: am335x: spi driver and two chip select

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Micka,

On Tue, Apr 12, 2016 at 3:42 PM, Micka <mickamusset@xxxxxxxxx> wrote:
> I've two MAX3107 connected to the spi 1 line. ( chip select 0 and 1 )
>
> The problem is that when the spi driver start the probe function of
> the driver, the chip select of the second max3107 is set to low .....
>
> During the first call of the probe function, the driver try to read a
> register on the first device, but because of the second chip select
> set to low, the two device answer at the same time .... I don't really
> understand why ?
>
> I've correctly configured the CS1 and CS0 to be set as an output with
> a pull up ....
>
>
> &spi1{
> #address-cells = <1>;
> #size-cells = <0>;
> pinctrl-names = "default";
> pinctrl-0 = <&bb_spi1_pins>;
> status = "okay";
> ti,pindir-d0-out-d1-in;

Guessing from the DT, you're using "ti,omap4-mcspi"?

AFAIU, spi_master.setup() should not modify registers immediately when
supporting more than a single CS signal, while omap2_mcspi_setup_transfer()
seems to do that.

Probably the second SPI slave is set up while performing a transfer to
the first SPI slave.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds
--
To unsubscribe from this list: send the line "unsubscribe linux-spi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux