From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from fg-out-1718.google.com (fg-out-1718.google.com [72.14.220.155]) by ozlabs.org (Postfix) with ESMTP id 043D5DDDE6 for ; Thu, 30 Oct 2008 00:43:34 +1100 (EST) Received: by fg-out-1718.google.com with SMTP id d23so39633fga.39 for ; Wed, 29 Oct 2008 06:43:32 -0700 (PDT) Message-ID: Date: Wed, 29 Oct 2008 14:43:32 +0100 From: "Henk Stegeman" To: linuxppc-dev@ozlabs.org Subject: Chipselect in SPI binding with mpc5200-psc-spi MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_3744_27396951.1225287812684" List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , ------=_Part_3744_27396951.1225287812684 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline .. .. In my dts I have my chipselect defined as follows: gpt4: timer@640 { // General Purpose Timer GPT4 in GPIO mode for SMC4000IO chip select. compatible = "fsl,mpc5200b-gpt-gpio","fsl,mpc5200-gpt-gpio"; cell-index = <4>; reg = <0x640 0x10>; interrupts = <1 13 0>; interrupt-parent = <&mpc5200_pic>; gpio-controller; #gpio-cells = <2>; }; I found the gpio in # cat /sys/class/gpio/gpiochip215/label /soc5200@f0000000/timer@640 The spi controller is defined like this: spi@2400 { device_type = "spi"; #address-cells = <1>; #size-cells = <0>; compatible = "fsl,mpc5200-psc-spi","fsl,mpc5200b-psc-spi"; cell-index = <2>; reg = <2400 100>; interrupts = <2 3 0>; interrupt-parent = <&mpc5200_pic>; gpios = <&gpt4 0 0>; io-controller@0 { compatible = "microkey,smc4000io"; spi-max-frequency = <1000000>; reg = <0>; }; }; At bootup linux (2.6.27) reports: mpc52xx-psc-spi f0000960.spi: probe called without platform data, no (de)activate_cs function will be called. Is my assumption wrong that the gpios property is the way to map chipselects to the spi driver? Thanks in advance. Henk. ------=_Part_3744_27396951.1225287812684 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline ..
..
In my dts

I have my chipselect defined as follows:

        gpt4: timer@640 {    // General Purpose Timer GPT4 in GPIO mode for SMC4000IO chip select.
            compatible = "fsl,mpc5200b-gpt-gpio","fsl,mpc5200-gpt-gpio";
            cell-index = <4>;
            reg = <0x640 0x10>;
            interrupts = <1 13 0>;
            interrupt-parent = <&mpc5200_pic>;
            gpio-controller;
            #gpio-cells = <2>;
        };

I found the gpio in
# cat /sys/class/gpio/gpiochip215/label
/soc5200@f0000000/timer@640

The spi controller is defined like this:

        spi@2400 {
            device_type = "spi";
            #address-cells = <1>;
            #size-cells = <0>;
            compatible = "fsl,mpc5200-psc-spi","fsl,mpc5200b-psc-spi";
            cell-index = <2>;
            reg = <2400 100>;
            interrupts = <2 3 0>;
            interrupt-parent = <&mpc5200_pic>;
            gpios = <&gpt4 0 0>;

            io-controller@0 {
                compatible = "microkey,smc4000io";
                spi-max-frequency = <1000000>;
                reg = <0>;
            };
        };

At bootup linux (2.6.27) reports:

mpc52xx-psc-spi f0000960.spi: probe called without platform data, no (de)activate_cs function will be called.

Is my assumption wrong that the gpios property is the way to map chipselects to the spi driver?

Thanks in advance.
Henk.


------=_Part_3744_27396951.1225287812684--