cancel
Showing results for 
Search instead for 
Did you mean: 

STM32MP157 mmc1 not switch into high speed mode

SChen.19
Associate II

Hi supporter, I have two boards, one is my custom board and another is dk2. Those boards are not support high speed of mmc1. The mmc2 is into high speed and has 50Mhz clock.

Below is some info about mmc1 and mmc2 on dk2 board.

root@stm32mp1:~# cat /sys/kernel/debug/mmc0/ios
clock:		25000000 Hz
actual clock:	24750000 Hz
vdd:		21 (3.3 ~ 3.4 V)
bus mode:	2 (push-pull)
chip select:	0 (don't care)
power mode:	2 (on)
bus width:	2 (4 bits)
timing spec:	0 (legacy)
signal voltage:	0 (3.30 V)
driver type:	0 (driver type B)
root@stm32mp1:~# cat /sys/kernel/debug/mmc1/ios
clock:		50000000 Hz
actual clock:	49500000 Hz
vdd:		21 (3.3 ~ 3.4 V)
bus mode:	2 (push-pull)
chip select:	0 (don't care)
power mode:	2 (on)
bus width:	2 (4 bits)
timing spec:	2 (sd high-speed)
signal voltage:	0 (3.30 V)
driver type:	0 (driver type B)
root@stm32mp1:~# mount -t debugfs debugfs /mnt/
root@stm32mp1:~# cat /mnt/^C
root@stm32mp1:~# dmesg| grep mmc
[    0.000000] Kernel command line: root=/dev/mmcblk0p6 rootwait rw console=ttySTM0,115200
[    1.948032] mmci-pl18x 58005000.sdmmc: Linked as a consumer to regulator.8
[    1.953617] mmci-pl18x 58005000.sdmmc: mmc0: PL180 manf 53 rev2 at 0x58005000 irq 58,0 (pio)
[    1.991010] mmci-pl18x 58007000.sdmmc: allocated mmc-pwrseq
[    1.995496] mmci-pl18x 58007000.sdmmc: Linked as a consumer to regulator.8
[    2.003329] mmci-pl18x 58007000.sdmmc: mmc1: PL180 manf 53 rev1 at 0x58007000 irq 59,0 (pio)
[    2.042312] mmc0: host does not support reading read-only switch, assuming write-enable
[    2.060730] mmc0: Problem switching card into high-speed mode!
[    2.069832] mmc0: new SDHC card at address 0001
[    2.079128] mmcblk0: mmc0:0001 SD 14.6 GiB
[    2.094173] mmc1: queuing unknown CIS tuple 0x80 (2 bytes)
[    2.104142] mmc1: queuing unknown CIS tuple 0x80 (3 bytes)
[    2.116461] mmc1: queuing unknown CIS tuple 0x80 (3 bytes)
[    2.127848] mmc1: queuing unknown CIS tuple 0x80 (7 bytes)
[    2.136986] mmc1: queuing unknown CIS tuple 0x80 (3 bytes)
[    2.183527] mmc1: queuing unknown CIS tuple 0x80 (6 bytes)
[    2.189127]  mmcblk0: p1 p2 p3 p4 p5 p6 p7
[    2.277342] mmc1: new high speed SDIO card at address 0001

I found an error message "mmc0: Problem switching card into high-speed mode!". What cause the mmc1 not into speed mode? In my application stuation, we need mmc1 at 50Mhz to more higher io speed for read/write file on sdcard.

1 ACCEPTED SOLUTION

Accepted Solutions

Hi,

have you tried with another SD-Card ?

On my DK2-F, I got correct card speed.

root@stm32mp1:~# cat /sys/kernel/debug/mmc0/ios
clock:          50000000 Hz
actual clock:   49500000 Hz
vdd:            21 (3.3 ~ 3.4 V)
bus mode:       2 (push-pull)
chip select:    0 (don't care)
power mode:     2 (on)
bus width:      2 (4 bits)
timing spec:    2 (sd high-speed)
signal voltage: 0 (3.30 V)
driver type:    0 (driver type B)
root@stm32mp1:~# dmesg| grep mmc
[    3.249286] mmci-pl18x 58005000.sdmmc: Got CD GPIO
[    3.254048] mmci-pl18x 58005000.sdmmc: mmc0: PL180 manf 53 rev2 at 0x58005000 irq 54,0 (pio)
[    3.291261] mmci-pl18x 58007000.sdmmc: allocated mmc-pwrseq
[    3.297290] mmci-pl18x 58007000.sdmmc: mmc1: PL180 manf 53 rev1 at 0x58007000 irq 55,0 (pio)
[    3.354453] mmc0: new high speed SDHC card at address 0007
[    3.365910] mmcblk0: mmc0:0007 SD16G 14.5 GiB
.....

Regards.

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.

View solution in original post

6 REPLIES 6
PatrickF
ST Employee

Hi,

On DK2 did you use the (latest) Starter Package or your own binaries?

Did you tried with another SD-Card ?

If you generated your own binaries, please share ecosystem version and the Device Tree you used.

Regards.

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.

I use binary from stm32mp1-openstlinux-4.19-thud-mp1-19-02-20 file.My sdcard is sandisk classs10 u1 type.

Hi,

Although this did not explain the issue, your are using an v1.2 ecosystem.

I strongly encourage you to use latest binaries from ecosystem v3.1 for your boards (stm32mp1-openstlinux-5.10-dunfell-mp1-21-11-17).

See step-by-step "Populate the target and boot the image" for your DK2 in the wiki: https://wiki.st.com/stm32mpu/wiki/Getting_started/STM32MP1_boards/STM32MP157x-DK2/Let%27s_start

Regards

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.

Hi PatrickF,

I download the v3.1 package and populate into sdcard. Then boot it on dk2 board. It's also has same issue.The mmc0 only has 25Mhz not the 50Mhz.

root@stm32mp1:~# cat /sys/kernel/debug/mmc0/ios
clock:		25000000 Hz
actual clock:	24750000 Hz
vdd:		21 (3.3 ~ 3.4 V)
bus mode:	2 (push-pull)
chip select:	0 (don't care)
power mode:	2 (on)
bus width:	2 (4 bits)
timing spec:	0 (legacy)
signal voltage:	0 (3.30 V)
driver type:	0 (driver type B)
root@stm32mp1:~# cat /sys/kernel/debug/mmc1/ios
clock:		50000000 Hz
actual clock:	49500000 Hz
vdd:		21 (3.3 ~ 3.4 V)
bus mode:	2 (push-pull)
chip select:	0 (don't care)
power mode:	2 (on)
bus width:	2 (4 bits)
timing spec:	2 (sd high-speed)
signal voltage:	0 (3.30 V)
driver type:	0 (driver type B)
root@stm32mp1:~# uname -a
Linux stm32mp1 5.10.61 #1 SMP PREEMPT Thu Aug 26 12:51:21 UTC 2021 armv7l armv7l armv7l GNU/Linux
root@stm32mp1:~# cat /etc/issue
ST OpenSTLinux - Weston - (A Yocto Project Based Distro) 3.1.11-openstlinux-5.10-dunfell-mp1-21-11-17 \n \l
 
root@stm32mp1:~# cat /etc/os-release
ID=openstlinux-weston
NAME="ST OpenSTLinux - Weston - (A Yocto Project Based Distro)"
VERSION="3.1.11-openstlinux-5.10-dunfell-mp1-21-11-17 (dunfell)"
VERSION_ID=3.1.11-openstlinux-5.10-dunfell-mp1-21-11-17
PRETTY_NAME="ST OpenSTLinux - Weston - (A Yocto Project Based Distro) 3.1.11-openstlinux-5.10-dunfell-mp1-21-11-17 (dunfell)"

Hi,

have you tried with another SD-Card ?

On my DK2-F, I got correct card speed.

root@stm32mp1:~# cat /sys/kernel/debug/mmc0/ios
clock:          50000000 Hz
actual clock:   49500000 Hz
vdd:            21 (3.3 ~ 3.4 V)
bus mode:       2 (push-pull)
chip select:    0 (don't care)
power mode:     2 (on)
bus width:      2 (4 bits)
timing spec:    2 (sd high-speed)
signal voltage: 0 (3.30 V)
driver type:    0 (driver type B)
root@stm32mp1:~# dmesg| grep mmc
[    3.249286] mmci-pl18x 58005000.sdmmc: Got CD GPIO
[    3.254048] mmci-pl18x 58005000.sdmmc: mmc0: PL180 manf 53 rev2 at 0x58005000 irq 54,0 (pio)
[    3.291261] mmci-pl18x 58007000.sdmmc: allocated mmc-pwrseq
[    3.297290] mmci-pl18x 58007000.sdmmc: mmc1: PL180 manf 53 rev1 at 0x58007000 irq 55,0 (pio)
[    3.354453] mmc0: new high speed SDHC card at address 0007
[    3.365910] mmcblk0: mmc0:0007 SD16G 14.5 GiB
.....

Regards.

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.

Hi PatrickF,

Thanks your reply. I have tried on another sdcard with u3 class. It's has high-speed with 50Mhz. Thanks again.