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.

How to get the SPI character device node in 8127 IPNC RDK 3.0?

Hi All,

      I work on 8127 IPNC RDK 3.0.

      And I want get the  the SPI character device node in filesystem like as ''/dev/spidevX.X".

     In the Kernel config menu, I enable the "SPI support" and the "User mode SPI device driver support " option.

    When the system startup, the kernel print the message "PM: Adding info for spi:spi1.0".

    And in /proc/devices, I find the ''153 spi".  

    All is looks right.

   But there is no “spidevX.X” in /dev.

   And I mknod manually like below, it return "spi0: No such device or address" when read or write.

          brw-r--r-- 1 root root 153, 0 Apr 2 01:20 spi0
          brw-r--r-- 1 root root 153, 1 Apr 2 01:21 spi1

  

 Could someone help me?  

Thanks!

    

  • Hi xue,

                 have u tried building SPI along with kernel or u tried building it as module? (i am referring to TI81XX_PSP_McSPI_Driver_Guide.pdf)

  • Hi Ravikiran,

          Thanks for you reply.

          I build SPI along with kernel.

         

          

    I want to read/write data dierctly by a SPI interface‘s device node,  Should I must modify the arch/arm/mach-omap2/board-ipnc.c?

    Thank you.

    Best Regards,

    Xue

  • Hi xue,

                   I think board-ti8148ipnc.c need to be updated.

    May be some experts in the group ll answer your query.  M new to SPI.

  • Hi Ravikiran,

                  Thanks your help. The problem is resolved.

                  The spi device uses the  "spidev" driver,  then the the /dev/spidevX.X emerge.

                  Like blow in board-ti8148ipnc.c:

                           struct spi_board_info __initdata ti8148_spi_slave_info[] = {
                           {
                           .modalias = "spidev",
                           .irq = -1,
                           .max_speed_hz = 100000,
                           .bus_num = 1,
                           .chip_select = 0,
                           .mode = SPI_MODE_1,
                           },
                           };


    Best Regards,

    Xue