Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 7 Sep 2018 13:37:05 -0700
From:      Mark Millard <marklmi@yahoo.com>
To:        freebsd-arm <freebsd-arm@freebsd.org>
Subject:   Just an FYI: debug kernel output for an e.MMC on a sdcard adapter (Pine64+ 2GB context, head -r338518 based)
Message-ID:  <73FE40F2-9D13-4A43-9B03-E8452DC146A9@yahoo.com>

next in thread | raw e-mail | index | archive | help
I built and installed a debug kernel with "options VERBOSE_SYSINIT"
as well and I added "hw.mmc.debug=3D1" to /boot/loader.conf and used
boot -v just to see what such a combination would report for the
Pine64+ 2GB attempting to boot from the e.MMC with that kernel on
it.

The boot_run_interrupt_driven_config_hooks area ended up looking
like (serial numbers replaced):

QUOTE
subsystem a800000
   boot_run_interrupt_driven_config_hooks(0)... aw_mmc0: Powering up =
sd/mmc
axp8xx_pmu0: Enable vcc-3v3 (dcdc1)
mmc0: Probing bus
ugen1.1: <Generic OHCI root HUB> at usbus1
uhub0: <Generic OHCI root HUB, class 9/0, rev 1.00/1.00, addr 1> on =
usbus1
ugen2.1: <Allwinner EHCI root HUB> at usbus2
uhub1: <Allwinner EHCI root HUB, class 9/0, rev 2.00/1.00, addr 1> on =
usbus2
ugen3.1: <Generic OHCI root HUB> at usbus3
uhub2: <Generic OHCI root HUB, class 9/0, rev 1.00/1.00, addr 1> on =
usbus3
ugen0.1: <Allwinner EHCI root HUB> at usbus0
uhub3: <Allwinner EHCI root HUB, class 9/0, rev 2.00/1.00, addr 1> on =
usbus0
Expensive timeout(9) function: 0xffff0000004149f8(0) 0.002082708 s
aw_mmc0: error rint: 0x00000100
AW_MMC_INT_RESP_TIMEOUT=20
mmc0: CMD8 RESULT: 1
aw_mmc0: error rint: 0x00000100
AW_MMC_INT_RESP_TIMEOUT=20
mmc0: CMD8 RESULT: 1
aw_mmc0: error rint: 0x00000100
AW_MMC_INT_RESP_TIMEOUT=20
mmc0: CMD8 RESULT: 1
aw_mmc0: error rint: 0x00000100
AW_MMC_INT_RESP_TIMEOUT=20
mmc0: CMD8 RESULT: 1
aw_mmc0: error rint: 0x00000100
AW_MMC_INT_RESP_TIMEOUT=20
mmc0: CMD55 RESULT: 1
aw_mmc0: error rint: 0x00000100
AW_MMC_INT_RESP_TIMEOUT=20
mmc0: CMD55 RESULT: 1
aw_mmc0: error rint: 0x00000100
AW_MMC_INT_RESP_TIMEOUT=20
mmc0: CMD55 RESULT: 1
aw_mmc0: error rint: 0x00000100
AW_MMC_INT_RESP_TIMEOUT=20
mmc0: CMD55 RESULT: 1
mmc0: SD probe: failed
mmc0: MMC probe: OK (OCR: 0x40ff8080)
mmc0: Current OCR: 0x00ff8080
mmc0: Probing cards
mmc0: New card detected (CID 150100444a4e42345207???????636f)
mmc0: New card detected (CSD d02701320f5903fff6dbffef8e40400d)
aw_mmc0: error rint: 0x00008018
AW_MMC_INT_DATA_END_BIT_ERR
mmc0: CMD19 RESULT: 4
mmc0: Card at relative address 0x0002 added:
mmc0:  card: MMCHC DJNB4R 0.7 SN <REMOVED> MFG 06/2016 by 21 0x0000
mmc0:  quirks: 0
mmc0:  bus: 4bit, 200MHz (HS200 timing)
mmc0:  memory: 244277248 blocks, erase sector 1024 blocks
aw_mmc0: error rint: 0x00000100
AW_MMC_INT_RESP_TIMEOUT=20
mmc0: CMD2 RESULT: 1
aw_mmc0: error rint: 0x00000100
AW_MMC_INT_RESP_TIMEOUT=20
mmc0: CMD2 RESULT: 1
aw_mmc0: error rint: 0x00000100
AW_MMC_INT_RESP_TIMEOUT=20
mmc0: CMD2 RESULT: 1
uhub0: 1 port with 1 removable, self powered
aw_mmc0: error rint: 0x00000104
AW_MMC_INT_RESP_TIMEOUT=20
mmc0: CMD2 RESULT: 1
mmc0: setting transfer rate to 52.000MHz (dual data rate timing)
uhub2: 1 port with 1 removable, self powered
mmc0: Failed to set VCCQ for card at relative address 2
uhub1: 1 port with 1 removable, self powered
uhub3: 1 port with 1 removable, self powered
aw_mmc0: controller timeout
aw_mmc0: timeout updating clock
Expensive timeout(9) function: 0xffff00000068400c(0xfffffd00001bd400) =
11.120601791 s
mmc0: CMD8 RESULT: 1
aw_mmc0: controller timeout
aw_mmc0: timeout updating clock
mmc0: CMD8 RESULT: 1
aw_mmc0: controller timeout
aw_mmc0: timeout updating clock
mmc0: CMD8 RESULT: 1
aw_mmc0: controller timeout
aw_mmc0: Spurious interrupt - no active request, rint: 0x00000000

mmc0: CMD8 RESULT: 1
mmcsd0: Error reading EXT_CSD Timeout
device_attach: mmcsd0 attach returned 6
done.
   vt_upgrade(&vt_consdev)... done.
subsystem affffff
END QUOTE



You may want to ignore my guesses below . . .



If I gather right, the part before:

mmc0: MMC probe: OK (OCR: 0x40ff8080)

is as expected.



I'm not sure about:

aw_mmc0: error rint: 0x00008018
AW_MMC_INT_DATA_END_BIT_ERR
mmc0: CMD19 RESULT: 4



The part between:

mmc0:  bus: 4bit, 200MHz (HS200 timing)
and:
mmc0: setting transfer rate to 52.000MHz (dual data rate timing)

may well be as expected.



I'm guessing that the following is the odd part
that contributes to device_attach returning 6:

aw_mmc0: controller timeout
aw_mmc0: timeout updating clock
Expensive timeout(9) function: 0xffff00000068400c(0xfffffd00001bd400) =
11.120601791 s
mmc0: CMD8 RESULT: 1
aw_mmc0: controller timeout
aw_mmc0: timeout updating clock
mmc0: CMD8 RESULT: 1
aw_mmc0: controller timeout
aw_mmc0: timeout updating clock
mmc0: CMD8 RESULT: 1
aw_mmc0: controller timeout
aw_mmc0: Spurious interrupt - no active request, rint: 0x00000000

mmc0: CMD8 RESULT: 1
mmcsd0: Error reading EXT_CSD Timeout
device_attach: mmcsd0 attach returned 6



One thing looking different than linux booting from such a e.MMC
on a sdcard adapter may be the 52.000MHz. Linux showed:

# cat /sys/kernel/debug/mmc0/ios
clock:          52000000 Hz
actual clock:   50000000 Hz
. . .



=3D=3D=3D
Mark Millard
marklmi at yahoo.com
( dsl-only.net went
away in early 2018-Mar)




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?73FE40F2-9D13-4A43-9B03-E8452DC146A9>