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.

can't mount sd card on dm368

Other Parts Discussed in Thread: TVP7002, TVP5158, THS7353

Hi all!

Now we want to use the sd card on dm368.When insert the sd card the ikernal can detect the  card ,but when we try to mount it we failed.

The log as follow:

 [14845.900000] mmcblk0: mmc0:1234 SA04G 3813376KiB
[14845.900000]  mmcblk0:p1
 
#
# mount -t vfat /dev/mmcblk0 /mnt/mmc
mount: /dev/mmcblk0 is not a valid block device
# mount -t vfat /dev/mmcblk0p1 /mnt/mmc
mount: /dev/mmcblk0p1 is not a valid block device
 
the detailed log of the mmc driver:
# dmesg |grep mmc
<7>[10236.880000] davinci-mmc davinci-mmc.0:
<7>[10236.880000] mmc0: starting CMD6 arg 00fffff1 flags 00000035
<7>[10236.880000] davinci-mmc davinci-mmc.0: MMCSD : Data xfer (block read), DTO 0 cycles + 100000000 ns, 1 blocks of 64 bytes
<7>[10236.890000] mmc0: req done (CMD6): 0/0/0: 00000900 00000000 00000000 00000000
<7>[10236.890000] mmc0: starting CMD6 arg 80fffff1 flags 00000035
<7>[10236.890000] davinci-mmc davinci-mmc.0: MMCSD : Data xfer (block read), DTO 0 cycles + 100000000 ns, 1 blocks of 64 bytes
<7>[10236.890000] mmc0: req done (CMD6): 0/0/0: 00000900 00000000 00000000 00000000
<7>[10236.890000] mmc0: starting CMD7 arg 00000000 flags 00000000
<7>[10236.890000] mmc0: req done (CMD7): 0/0/0: 00000000 00000000 00000000 00000000
<7>[10236.890000] mmc0: selected 50.000MHz transfer rate
<7>[10236.890000] mmc0: clock 50000000Hz busmode 2 powermode 2 cs 0 Vdd 20 width 2
<7>[10236.890000] davinci-mmc davinci-mmc.0: clock 50000000Hz busmode 2 powermode 2                     Vdd 0.20
<7>[10236.890000] davinci-mmc davinci-mmc.0:
<6>[10236.900000] mmcblk0: mmc0:1234 SA04G 3813376KiB
<6>[10236.900000]  mmcblk0:<7>mmc0: starting CMD7 arg 12340000 flags 00000015
<7>[10236.910000] mmc0: req done (CMD7): 0/0/0: 00000700 00000000 00000000 00000000
<7>[10236.910000] mmc0: starting CMD55 arg 12340000 flags 00000015
<7>[10236.910000] mmc0: req done (CMD55): 0/0/0: 00000920 00000000 00000000 00000000
<7>[10236.910000] mmc0: starting CMD6 arg 00000002 flags 00000015
<7>[10236.910000] mmc0: req done (CMD6): 0/0/0: 00000920 00000000 00000000 00000000
<7>[10236.910000] mmc0: clock 50000000Hz busmode 2 powermode 2 cs 0 Vdd 20 width 2
<7>[10236.910000] davinci-mmc davinci-mmc.0: clock 50000000Hz busmode 2 powermode 2                     Vdd 0.20
<7>[10236.910000] davinci-mmc davinci-mmc.0:
<7>[10236.910000] mmc0: starting CMD18 arg 00000000 flags 00000035
<7>[10236.910000] davinci-mmc davinci-mmc.0: MMCSD : Data xfer (block read), DTO 0 cycles + 100000000 ns, 8 blocks of 512 bytes
<7>[10236.920000] mmc0: req done (CMD18): 0/0/0: 00000900 00000000 00000000 00000000
<7>[14842.610000] mmc0: starting CMD7 arg 00000000 flags 00000000
<7>[14842.610000] mmc0: req done (CMD7): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] mmc0: starting CMD13 arg 12340000 flags 00000015
<7>[14842.610000] mmc0: req done (CMD13): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] mmc0: req done (CMD13): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] mmc0: req done (CMD13): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] mmc0: req done (CMD13): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] mmc0: clock 312500Hz busmode 1 powermode 2 cs 0 Vdd 20 width 2
<7>[14842.610000] davinci-mmc davinci-mmc.0: clock 312500Hz busmode 1 powermode 2                       Vdd 0.20
<7>[14842.610000] davinci-mmc davinci-mmc.0:
<7>[14842.610000] mmc0: starting CMD8 arg 000001aa flags 00000075
<7>[14842.610000] mmc0: req done (CMD8): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] mmc0: starting CMD55 arg 00000000 flags 00000015
<7>[14842.610000] mmc0: req done (CMD55): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] mmc0: starting CMD55 arg 00000000 flags 00000015
<7>[14842.610000] mmc0: req done (CMD55): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] mmc0: starting CMD55 arg 00000000 flags 00000015
<7>[14842.610000] mmc0: req done (CMD55): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] mmc0: starting CMD55 arg 00000000 flags 00000015
<7>[14842.610000] mmc0: req done (CMD55): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] mmc0: starting CMD2 arg 00000000 flags 00000067
<7>[14842.610000] mmc0: req done (CMD2): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] mmc0: req done (CMD2): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] mmc0: req done (CMD2): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] mmc0: req done (CMD2): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] mmc0: clock 312500Hz busmode 2 powermode 2 cs 0 Vdd 20 width 2
<7>[14842.610000] davinci-mmc davinci-mmc.0: clock 312500Hz busmode 2 powermode 2                       Vdd 0.20
<7>[14842.610000] davinci-mmc davinci-mmc.0:
<7>[14842.610000] mmc0: starting CMD13 arg 12340000 flags 00000015
<7>[14842.610000] mmc0: req done (CMD13): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] mmc0: req done (CMD13): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] mmc0: req done (CMD13): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] mmc0: req done (CMD13): 1/0/0: 00000000 00000000 00000000 00000000
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] davinci-mmc davinci-mmc.0: From code segment excuted when card removed
<7>[14842.610000] mmc0: selected 50.000MHz transfer rate
<7>[14842.610000] mmc0: clock 50000000Hz busmode 2 powermode 2 cs 0 Vdd 20 width 2
<7>[14842.610000] davinci-mmc davinci-mmc.0: clock 50000000Hz busmode 2 powermode 2                     Vdd 0.20
<7>[14842.610000] davinci-mmc davinci-mmc.0:
<7>[14842.640000] mmc0: clock 0Hz busmode 1 powermode 0 cs 0 Vdd 0 width 0
<7>[14842.640000] davinci-mmc davinci-mmc.0: clock 0Hz busmode 1 powermode 0                    Vdd 0.00
<7>[14842.640000] davinci-mmc davinci-mmc.0:
<7>[14843.610000] davinci-mmc davinci-mmc.0: MMC-Probing mmc with cmd1
<7>[14844.610000] davinci-mmc davinci-mmc.0: MMC-Probing mmc with cmd55
<7>[14845.610000] mmc0: clock 0Hz busmode 1 powermode 1 cs 0 Vdd 20 width 0
<7>[14845.610000] davinci-mmc davinci-mmc.0: clock 0Hz busmode 1 powermode 1                    Vdd 0.20
<7>[14845.610000] davinci-mmc davinci-mmc.0:
<7>[14845.630000] mmc0: clock 312500Hz busmode 1 powermode 2 cs 0 Vdd 20 width 0
<7>[14845.630000] davinci-mmc davinci-mmc.0: clock 312500Hz busmode 1 powermode 2                       Vdd 0.20
<7>[14845.630000] davinci-mmc davinci-mmc.0:
<7>[14845.650000] mmc0: clock 312500Hz busmode 1 powermode 2 cs 1 Vdd 20 width 0
<7>[14845.650000] davinci-mmc davinci-mmc.0: clock 312500Hz busmode 1 powermode 2                       Vdd 0.20
<7>[14845.650000] davinci-mmc davinci-mmc.0:
<7>[14845.670000] mmc0: starting CMD0 arg 00000000 flags 00000040
<7>[14845.670000] mmc0: req done (CMD0): 0/0/0: 00000000 00000000 00000000 00000000
<7>[14845.690000] mmc0: clock 312500Hz busmode 1 powermode 2 cs 0 Vdd 20 width 0
<7>[14845.690000] davinci-mmc davinci-mmc.0: clock 312500Hz busmode 1 powermode 2                       Vdd 0.20
<7>[14845.690000] davinci-mmc davinci-mmc.0:
<7>[14845.710000] mmc0: starting CMD8 arg 000001aa flags 00000075
<7>[14845.710000] mmc0: req done (CMD8): 0/0/0: 000001aa 00000000 00000000 00000000
<7>[14845.710000] mmc0: starting CMD55 arg 00000000 flags 00000015
<7>[14845.710000] mmc0: req done (CMD55): 0/0/0: 00000120 00000000 00000000 00000000
<7>[14845.710000] mmc0: starting CMD41 arg 00000000 flags 00000061
<7>[14845.710000] mmc0: req done (CMD41): 0/0/0: 00ff8000 00000000 00000000 00000000
<7>[14845.710000] mmc0: clock 312500Hz busmode 1 powermode 2 cs 0 Vdd 20 width 0
<7>[14845.710000] davinci-mmc davinci-mmc.0: clock 312500Hz busmode 1 powermode 2                       Vdd 0.20
<7>[14845.710000] davinci-mmc davinci-mmc.0:
<7>[14845.710000] mmc0: clock 312500Hz busmode 1 powermode 2 cs 1 Vdd 20 width 0
<7>[14845.710000] davinci-mmc davinci-mmc.0: clock 312500Hz busmode 1 powermode 2                       Vdd 0.20
<7>[14845.710000] davinci-mmc davinci-mmc.0:
<7>[14845.730000] mmc0: starting CMD0 arg 00000000 flags 00000040
<7>[14845.730000] mmc0: req done (CMD0): 0/0/0: 00000000 00000000 00000000 00000000
<7>[14845.750000] mmc0: clock 312500Hz busmode 1 powermode 2 cs 0 Vdd 20 width 0
<7>[14845.750000] davinci-mmc davinci-mmc.0: clock 312500Hz busmode 1 powermode 2                       Vdd 0.20
<7>[14845.750000] davinci-mmc davinci-mmc.0:
<7>[14845.770000] mmc0: starting CMD8 arg 000001aa flags 00000075
<7>[14845.770000] mmc0: req done (CMD8): 0/0/0: 000001aa 00000000 00000000 00000000
<7>[14845.770000] mmc0: starting CMD55 arg 00000000 flags 00000015
<7>[14845.770000] mmc0: req done (CMD55): 0/0/0: 00000120 00000000 00000000 00000000
<7>[14845.770000] mmc0: starting CMD41 arg 40100000 flags 00000061
<7>[14845.770000] mmc0: req done (CMD41): 0/0/0: 00ff8000 00000000 00000000 00000000
<7>[14845.790000] mmc0: starting CMD55 arg 00000000 flags 00000015
<7>[14845.790000] mmc0: req done (CMD55): 0/0/0: 00000120 00000000 00000000 00000000
<7>[14845.790000] mmc0: starting CMD41 arg 40100000 flags 00000061
<7>[14845.790000] mmc0: req done (CMD41): 0/0/0: 00ff8000 00000000 00000000 00000000
<7>[14845.810000] mmc0: starting CMD55 arg 00000000 flags 00000015
<7>[14845.810000] mmc0: req done (CMD55): 0/0/0: 00000120 00000000 00000000 00000000
<7>[14845.810000] mmc0: starting CMD41 arg 40100000 flags 00000061
<7>[14845.810000] mmc0: req done (CMD41): 0/0/0: 00ff8000 00000000 00000000 00000000
<7>[14845.830000] mmc0: starting CMD55 arg 00000000 flags 00000015
<7>[14845.830000] mmc0: req done (CMD55): 0/0/0: 00000120 00000000 00000000 00000000
<7>[14845.830000] mmc0: starting CMD41 arg 40100000 flags 00000061
<7>[14845.830000] mmc0: req done (CMD41): 0/0/0: 00ff8000 00000000 00000000 00000000
<7>[14845.850000] mmc0: starting CMD55 arg 00000000 flags 00000015
<7>[14845.850000] mmc0: req done (CMD55): 0/0/0: 00000120 00000000 00000000 00000000
<7>[14845.850000] mmc0: starting CMD41 arg 40100000 flags 00000061
<7>[14845.850000] mmc0: req done (CMD41): 0/0/0: 00ff8000 00000000 00000000 00000000
<7>[14845.870000] mmc0: starting CMD55 arg 00000000 flags 00000015
<7>[14845.870000] mmc0: req done (CMD55): 0/0/0: 00000120 00000000 00000000 00000000
<7>[14845.870000] mmc0: starting CMD41 arg 40100000 flags 00000061
<7>[14845.870000] mmc0: req done (CMD41): 0/0/0: c0ff8000 00000000 00000000 00000000
<7>[14845.870000] mmc0: starting CMD2 arg 00000000 flags 00000067
<7>[14845.870000] mmc0: req done (CMD2): 0/0/0: 02544d53 41303447 1041a989 9a00c459
<7>[14845.870000] mmc0: starting CMD3 arg 00000000 flags 00000065
<7>[14845.870000] mmc0: req done (CMD3): 0/0/0: 12340500 00000000 00000000 00000000
<7>[14845.870000] mmc0: starting CMD2 arg 00000000 flags 00000067
<7>[14845.870000] mmc0: req done (CMD2): 1/0/0: 12340500 41303447 1041a989 9a00c459
<7>[14845.870000] mmc0: clock 312500Hz busmode 2 powermode 2 cs 0 Vdd 20 width 0
<7>[14845.870000] davinci-mmc davinci-mmc.0: clock 312500Hz busmode 2 powermode 2                       Vdd 0.20
<7>[14845.870000] davinci-mmc davinci-mmc.0:
<7>[14845.870000] mmc0: starting CMD9 arg 12340000 flags 00000007
<7>[14845.870000] mmc0: req done (CMD9): 0/0/0: 400e0032 5b590000 1d177f80 0a40008d
<7>[14845.870000] mmc0: starting CMD7 arg 12340000 flags 00000015
<7>[14845.870000] mmc0: req done (CMD7): 0/0/0: 00000700 00000000 00000000 00000000
<7>[14845.870000] mmc0: clock 312500Hz busmode 2 powermode 2 cs 0 Vdd 20 width 0
<7>[14845.870000] davinci-mmc davinci-mmc.0: clock 312500Hz busmode 2 powermode 2                       Vdd 0.20
<7>[14845.870000] davinci-mmc davinci-mmc.0:
<7>[14845.880000] mmc0: starting CMD55 arg 12340000 flags 00000015
<7>[14845.880000] mmc0: req done (CMD55): 0/0/0: 00000920 00000000 00000000 00000000
<7>[14845.880000] mmc0: starting CMD51 arg 00000000 flags 00000035
<7>[14845.880000] davinci-mmc davinci-mmc.0: MMCSD : Data xfer (block read), DTO 0 cycles + 100000000 ns, 1 blocks of 8 bytes
<7>[14845.880000] mmc0: req done (CMD51): 0/0/0: 00000920 00000000 00000000 00000000
<7>[14845.880000] mmc0: starting CMD7 arg 00000000 flags 00000000
<7>[14845.880000] mmc0: req done (CMD7): 0/0/0: 00000000 00000000 00000000 00000000
<7>[14845.880000] mmc0: starting CMD7 arg 12340000 flags 00000015
<7>[14845.880000] mmc0: req done (CMD7): 0/0/0: 00000700 00000000 00000000 00000000
<7>[14845.880000] mmc0: starting CMD55 arg 12340000 flags 00000015
<7>[14845.880000] mmc0: req done (CMD55): 0/0/0: 00000920 00000000 00000000 00000000
<7>[14845.880000] mmc0: starting CMD6 arg 00000002 flags 00000015
<7>[14845.880000] mmc0: req done (CMD6): 0/0/0: 00000920 00000000 00000000 00000000
<7>[14845.880000] mmc0: clock 312500Hz busmode 2 powermode 2 cs 0 Vdd 20 width 2
<7>[14845.880000] davinci-mmc davinci-mmc.0: clock 312500Hz busmode 2 powermode 2                       Vdd 0.20
<7>[14845.880000] davinci-mmc davinci-mmc.0:
<7>[14845.880000] mmc0: starting CMD6 arg 00fffff1 flags 00000035
<7>[14845.880000] davinci-mmc davinci-mmc.0: MMCSD : Data xfer (block read), DTO 0 cycles + 100000000 ns, 1 blocks of 64 bytes
<7>[14845.890000] mmc0: req done (CMD6): 0/0/0: 00000900 00000000 00000000 00000000
<7>[14845.890000] mmc0: starting CMD6 arg 80fffff1 flags 00000035
<7>[14845.890000] davinci-mmc davinci-mmc.0: MMCSD : Data xfer (block read), DTO 0 cycles + 100000000 ns, 1 blocks of 64 bytes
<7>[14845.890000] mmc0: req done (CMD6): 0/0/0: 00000900 00000000 00000000 00000000
<7>[14845.890000] mmc0: starting CMD7 arg 00000000 flags 00000000
<7>[14845.890000] mmc0: req done (CMD7): 0/0/0: 00000000 00000000 00000000 00000000
<7>[14845.890000] mmc0: selected 50.000MHz transfer rate
<7>[14845.890000] mmc0: clock 50000000Hz busmode 2 powermode 2 cs 0 Vdd 20 width 2
<7>[14845.890000] davinci-mmc davinci-mmc.0: clock 50000000Hz busmode 2 powermode 2                     Vdd 0.20
<7>[14845.890000] davinci-mmc davinci-mmc.0:
<6>[14845.900000] mmcblk0: mmc0:1234 SA04G 3813376KiB
<6>[14845.900000]  mmcblk0:<7>mmc0: starting CMD7 arg 12340000 flags 00000015
<7>[14845.910000] mmc0: req done (CMD7): 0/0/0: 00000700 00000000 00000000 00000000
<7>[14845.910000] mmc0: starting CMD55 arg 12340000 flags 00000015
<7>[14845.910000] mmc0: req done (CMD55): 0/0/0: 00000920 00000000 00000000 00000000
<7>[14845.910000] mmc0: starting CMD6 arg 00000002 flags 00000015
<7>[14845.910000] mmc0: req done (CMD6): 0/0/0: 00000920 00000000 00000000 00000000
<7>[14845.910000] mmc0: clock 50000000Hz busmode 2 powermode 2 cs 0 Vdd 20 width 2
<7>[14845.910000] davinci-mmc davinci-mmc.0: clock 50000000Hz busmode 2 powermode 2                     Vdd 0.20
<7>[14845.910000] davinci-mmc davinci-mmc.0:
<7>[14845.910000] mmc0: starting CMD18 arg 00000000 flags 00000035
<7>[14845.910000] davinci-mmc davinci-mmc.0: MMCSD : Data xfer (block read), DTO 0 cycles + 100000000 ns, 8 blocks of 512 bytes
<7>[14845.920000] mmc0: req done (CMD18): 0/0/0: 00000900 00000000 00000000 00000000
 
 
Any suggesttion is helpful!
Thanks!

Best regards!

  • Hang,

    From the logs there are no errors reported from the driver. Can you verify whether you are able to read/write to the card? You can try one simple command.

    dd if=/dev/zero of=/dev/mmcblk0p1 bs=1024 count=1024

    This will screw up the card. So you might have to format it again to make it useful. Can you share the dmesg logs after executing this command?

  • Hi Renjith!

    the dmesg log  as follow:

    #
    # dd if=/dev/zero of=/dev/mmcblk0p1 bs=1024 count=1024
    dd: /dev/mmcblk0p1: No such device or address

    Best regards!

  • Hang,

    Can you send me the output of the following commands?

    cat /proc/devices

    ls -l /dev/mmc*


  • # cat /proc/partitions
    major minor  #blocks  name

      31     0       3072 mtdblock0
      31     1       2048 mtdblock1
      31     2       4096 mtdblock2
      31     3      24576 mtdblock3
      31     4       2048 mtdblock4
      31     5      95232 mtdblock5
     254     0    3813376 mmcblk0
     254     1    3807373 mmcblk0p1
    #

    # cat /proc/devices
    Character devices:
      1 mem
      4 /dev/vc/0
      4 tty
      4 ttyS
      5 /dev/tty
      5 /dev/console
      5 /dev/ptmx
      7 vcs
     10 misc
     13 input
     14 sound
     21 sg
     81 video4linux
     89 i2c
     90 mtd
    116 alsa
    128 ptm
    136 pts
    247 cmem
    248 dm365mmap
    249 irqk
    250 edma
    251 dev_dma
    252 dev_i2c
    253 csl
    254 rtc

    Block devices:
      1 ramdisk
      8 sd
     31 mtdblock
     65 sd
     66 sd
     67 sd
     68 sd
     69 sd
     70 sd
     71 sd
    128 sd
    129 sd
    130 sd
    131 sd
    132 sd
    133 sd
    134 sd
    135 sd
    254 mmc

     

    #
    # ls -l /dev/mmc*
    brwxrwxrwx    1 40502    root     253,   0 Nov 11  2011 /dev/mmcblk0
    brwxrwxrwx    1 40502    root     253,   1 Nov 11  2011 /dev/mmcblk0p1
    #

  • Hang,

    If you see the major number assigned to the device /dev/mmcblk0 and /dev/mmcblk0p1 is 253. Whereas the actual device major number is 254 according to /proc/devices. 

    So, you can delete the current /dev/mmcblk entries and create new block device entries with the same name using mknod command for the major number 254. Try this out.

  • Hi Renjith!

    Thanks  a  lot!

    Under your direction i have solved the problem!

    Best regards!

  • Hang,

    Glad that you've solved the issue. Can you mark this post as answered?

  • Hi Renjith :

    i have the same problem for my DM365 board, SD cannot be detected :

    platform : DM365

    system : kernel 2.6.18, SDK 2_10_01_18

    and i follow your suggestion, create a device by using mknod :

    #mknod /dev/mmcblk0p1 254 0

    but still didn't work, what should i do??? could you help me??? thanks in advanced!!!

    some info. just like bellow:

    # cat /proc/devices

    Character devices:  

    1 mem  

    4 /dev/vc/0  

    4 tty  

    4 ttyS  

    5 /dev/tty  

    5 /dev/console  

    5 /dev/ptmx  

    7 vcs  

    10 misc  

    13 input  

    14 sound  

    29 fb  

    81 video4linux  

    89 i2c  

    90 mtd

    116 alsa

    128 ptm

    136 pts

    180 usb

    189 usb_device

    249 DM365AEW

    250 DM365AF

    251 DaVinciResizer

    252 DaVinciPreviewer

    253 DM365FACEDETECT

    254 rtc

    Block devices:  

    1 ramdisk  

    31 mtdblock

    254 mmc

    # ls /dev/mmc* -l

    ls: /dev/mmc*: No such file or directory

    # cat /proc/partitions

    major minor  #blocks  name

    31     0       3840 mtdblock0  

    31     1        256 mtdblock1  

    31     2       4096 mtdblock2  

    31     3      65536 mtdblock3  

     31     4     450560 mtdblock4  

     31     5          8 mtdblock5

     #

  • Antony,

    Is you card getting detected during kernel bootup properly? Can you share the complete kernel logs?

  • 0184.my dm365.txt

    nice to hear you!!!

    of course, please see it in my-dm365.txt

     

    thanks!!!

    Antony

  • Antony,

    The card it self is not detected. After the log 

    davinci-mmc davinci-mmc.0: Supporting 4-bit mode
    davinci-mmc davinci-mmc.0: Using DMA mode

    there is no card detection logs for sd card. I believe there might be some issue with the card or card detection logic. Remove the card and see whether you are still getting 

    davinci-mmc davinci-mmc.0: Supporting 4-bit mode
    davinci-mmc davinci-mmc.0: Using DMA mode 

    logs.

  • Renjith :

    the whole system (kernel 2.6.18 + filesys) it did run on DM365EVM board, and no problem with SD card, but our board without CPLD that controled SD WP & CD, it is the reason that my board cannot detect the SD device(in my board SD WP is connected to GPIO 3 and SD CD is connected to GPIO1) ???

     from the logs, can you see something wrong with HW issues or SW issues???

     

    PS : may i ask you some question about camera image issues??? i cannot get the image data form OV 9715 , and my board without TVP5158(514x), TVP7002,THS7353!!

    thanks

    Antony

  • Antony,

    The card detection logic in EVM is different from yours. I guess you better check your code for proper card detection logic. 

    Regarding the camera, are you having  a proper driver for the OV9715 sensor? Are you able to do I2C read/write from/to the sensor?

  • Renjith :

    thanks for your replay!!

    1. "The card detection logic in EVM is different from yours" what do you mean??? could you give me more hints???

    2. i don't have any OV9715 sensor driver, my program is based on V4L2 API, i thinks it need a driver for connecting with v4l2 port right???

    because i cannot open /dev/video0 this device!!! or if you have such a driver, could provide me???

     

    thanks very much!!!

    Antony

     

     

  • Antony,

    1. What I meant is the card detection in EVM uses CPLD, whereas you are detecting card using a GPIO directly. 

    2. I don't have a ov9715 sensor driver with me. 

  • Renjith :

    i see!!!

    so could you teach me how to modify the source code for detecting SD card using GPIO??? please!!!

    thanks very much again!!!

    Antony

  • Antony,

    There is no issue in teaching you. But it will take a lot of time as I don't have the code and your boards schematics with me. What I suggest you to do is to figure out how card detect works in EVM by enabling printks in the mmc driver. Understand the flow and understand how the hardware card detect works on EVM. Once you understand the flow, check your boards's schematics as to how your hardware connections are and make suitable modifications in your driver as well. 

    Also one more thing you can try as a temporary solution is to understand the driver and modify(hardcode) the driver in such a way that it always assume that card is connected. This will help in validating your SD driver and you'll be able to do a read/write to the card.