Исхоные данные: плата SK-iMX6S/D-SODIM, материнская плата starterkit для неё, buildroot-2014.08-sk с ядром linux-imx_3.10.17_1.0.2_ga-sk и неизменённым файлом imx6qdl-sodimm.dtsi, пустая sd карта на 2Гб с файловой системой FAT. Ситуация следующая: после загрузки платы, если вставить карту памяти, то она определится и примонтируется. С ней можно работать, считывать и записывать данные. Если карту извлечь, то появится соответсвующее сообщение. Однако если вставить карту памяти до загрузки платы, то при загрузке возникнет сбой и зависание системы. Вот вывод коносли:
Starting kernel ...
Booting Linux on physical CPU 0x0
Linux version 3.10.17 (serg@linux-hw53) (gcc version 4.9.1 20140505 (prerelease) (crosstool-NG linaro-1.13.1-4.9-2014.05 - Linaro GC4
CPU: ARMv7 Processor [412fc09a] revision 10 (ARMv7), cr=10c53c7d
CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
Machine: Freescale i.MX6 Quad/DualLite (Device Tree), model: Starterkit SK-iMX6D-SODIMM Board
cma: CMA: reserved 256 MiB at 40000000
Memory policy: ECC disabled, Data cache writealloc
PERCPU: Embedded 8 pages/cpu @810ff000 s8896 r8192 d15680 u32768
Built 1 zonelists in Zone order, mobility grouping on. Total pages: 260096
Kernel command line: console=ttymxc0,115200 root=/dev/mmcblk0p1 rootwait rw video=mxcfb0:dev=ldb,LDB-WSVGA,if=RGB666
PID hash table entries: 4096 (order: 2, 16384 bytes)
Dentry cache hash table entries: 131072 (order: 7, 524288 bytes)
Inode-cache hash table entries: 65536 (order: 6, 262144 bytes)
Memory: 1024MB = 1024MB total
Memory: 767596k/767596k available, 280980k reserved, 0K highmem
Virtual kernel memory layout:
vector : 0xffff0000 - 0xffff1000 ( 4 kB)
fixmap : 0xfff00000 - 0xfffe0000 ( 896 kB)
vmalloc : 0xc0800000 - 0xff000000 (1000 MB)
lowmem : 0x80000000 - 0xc0000000 (1024 MB)
pkmap : 0x7fe00000 - 0x80000000 ( 2 MB)
modules : 0x7f000000 - 0x7fe00000 ( 14 MB)
.text : 0x80008000 - 0x80802760 (8170 kB)
.init : 0x80803000 - 0x8083c2c0 ( 229 kB)
.data : 0x8083e000 - 0x80882ba0 ( 275 kB)
.bss : 0x80882ba0 - 0x808e96a4 ( 411 kB)
SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=2, Nodes=1
Preemptible hierarchical RCU implementation.
NR_IRQS:16 nr_irqs:16 16
L310 cache controller enabled
l2x0: 16 ways, CACHE_ID 0x410000c7, AUX_CTRL 0x32070000, Cache size: 1048576 B
sched_clock: 32 bits at 3000kHz, resolution 333ns, wraps every 1431655ms
CPU identified as i.MX6Q, silicon rev 1.2
Console: colour dummy device 80x30
Calibrating delay loop... 1581.05 BogoMIPS (lpj=7905280)
pid_max: default: 32768 minimum: 301
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
Setting up static identity map for 0x805ee620 - 0x805ee678
CPU1: Booted secondary processor
CPU1: thread -1, cpu 1, socket 0, mpidr 80000001
Brought up 2 CPUs
SMP: Total of 2 processors activated (3162.11 BogoMIPS).
CPU: All CPU(s) started in SVC mode.
devtmpfs: initialized
pinctrl core: initialized pinctrl subsystem
regulator-dummy: no parameters
NET: Registered protocol family 16
DMA: preallocated 256 KiB pool for atomic coherent allocations
Use WDOG1 as reset source
syscon 20c8000.anatop: regmap [mem 0x020c8000-0x020c8fff] registered
vdd1p1: 800 <--> 1375 mV at 1125 mV
vdd3p0: 2800 <--> 3150 mV at 3000 mV
vdd2p5: 2000 <--> 2750 mV at 2425 mV
cpu: 725 <--> 1450 mV at 1150 mV
vddpu: 725 <--> 1450 mV
vddsoc: 725 <--> 1450 mV at 1175 mV
syscon 20e0000.iomuxc-gpr: regmap [mem 0x020e0000-0x020e0037] registered
syscon 21bc000.ocotp-ctrl: regmap [mem 0x021bc000-0x021bffff] registered
hw-breakpoint: found 5 (+1 reserved) breakpoint and 1 watchpoint registers.
hw-breakpoint: maximum watchpoint size is 4 bytes.
imx6q-pinctrl 20e0000.iomuxc: initialized IMX pinctrl driver
bio: create slab <bio-0> at 0
mxs-dma 110000.dma-apbh: initialized
3P3V: 3300 mV
vgaarb: loaded
SCSI subsystem initialized
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
i2c i2c-0: IMX I2C adapter registered
Linux video capture interface: v2.00
pps_core: LinuxPPS API ver. 1 registered
pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
PTP clock support registered
imx-ipuv3 2400000.ipu: IPU DMFC NORMAL mode: 1(0~1), 5B(4,5), 5F(6,7)
imx-ipuv3 2800000.ipu: IPU DMFC NORMAL mode: 1(0~1), 5B(4,5), 5F(6,7)
MIPI CSI2 driver module loaded
Advanced Linux Sound Architecture Driver Initialized.
cfg80211: Calling CRDA to update world regulatory domain
Switching to clocksource mxc_timer1
imx6q-pcie 1ffc000.pcie: phy link never came up
PCI host bridge to bus 0000:00
pci_bus 0000:00: root bus resource [io 0x1000-0x10000]
pci_bus 0000:00: root bus resource [mem 0x01000000-0x01efffff]
pci_bus 0000:00: No busn resource found for root bus, will use [bus 00-ff]
PCI: bus0: Fast back to back transfers disabled
PCI: bus1: Fast back to back transfers enabled
pci 0000:00:00.0: BAR 0: assigned [mem 0x01000000-0x010fffff]
pci 0000:00:00.0: BAR 6: assigned [mem 0x01100000-0x0110ffff pref]
pci 0000:00:00.0: PCI bridge to [bus 01]
NET: Registered protocol family 2
TCP established hash table entries: 8192 (order: 4, 65536 bytes)
TCP bind hash table entries: 8192 (order: 4, 65536 bytes)
TCP: Hash tables configured (established 8192 bind 8192)
TCP: reno registered
UDP hash table entries: 512 (order: 2, 16384 bytes)
UDP-Lite hash table entries: 512 (order: 2, 16384 bytes)
NET: Registered protocol family 1
RPC: Registered named UNIX socket transport module.
RPC: Registered udp transport module.
RPC: Registered tcp transport module.
RPC: Registered tcp NFSv4.1 backchannel transport module.
hw perfevents: enabled with ARMv7 Cortex-A9 PMU driver, 7 counters available
pureg-dummy: no parameters
imx6_busfreq busfreq.15: DDR medium rate not supported.
SK: i.MX6Q DDR 400M, disable bus frequency scaling
Bus freq driver module loaded
VFS: Disk quotas dquot_6.5.2
Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
NFS: Registering the id_resolver key type
Key type id_resolver registered
Key type id_legacy registered
fuse init (API version 7.22)
msgmni has been set to 2011
io scheduler noop registered (default)
io scheduler deadline registered
io scheduler cfq registered
imx-weim 21b8000.weim: WEIM driver registered.
mxc_sdc_fb fb.21: register mxc display driver ldb
imx-ipuv3 2800000.ipu: IPU DMFC DP HIGH RESOLUTION: 1(0,1), 5B(2~5), 5F(6,7)
mxc_sdc_fb fb.22: register mxc display driver hdmi
mxc_hdmi 20e0000.hdmi_video: Detected HDMI controller 0x13:0xa:0xa0:0xc1
fbcvt: 1280x720@60: CVT Name - .921M9
imx-sdma 20ec000.sdma: no iram assigned, using external mem
imx-sdma 20ec000.sdma: loaded firmware 1.1
imx-sdma 20ec000.sdma: initialized
Serial: IMX driver
2020000.serial: ttymxc0 at MMIO 0x2020000 (irq = 58) is a IMX
console [ttymxc0] enabled
21e8000.serial: ttymxc1 at MMIO 0x21e8000 (irq = 59) is a IMX
21ec000.serial: ttymxc2 at MMIO 0x21ec000 (irq = 60) is a IMX
serial: Freescale lpuart driver
[drm] Initialized drm 1.1.0 20060810
[drm] Initialized vivante 1.0.0 20120216 on minor 0
brd: module loaded
loop: module loaded
Wait for CR ACK error!
sata phy RX_PLL is stable!
ahci: SSS flag set, parallel bus scan disabled
ahci ahci: AHCI 0001.0300 32 slots 1 ports 3 Gbps 0x1 impl platform mode
ahci ahci: flags: ncq sntf stag pm led clo only pmp pio slum part ccc apst
scsi0 : ahci_platform
ata1: SATA max UDMA/133 mmio [mem 0x02200000-0x02203fff] port 0x100 irq 71
spi_imx 2008000.ecspi: probed
spi_imx 2014000.ecspi: probed
CAN device driver interface
flexcan 2094000.can: device registered (reg_base=c0a58000, irq=143)
libphy: fec_enet_mii_bus: probed
fec 2188000.ethernet eth0: registered PHC device 0
usbcore: registered new interface driver smsc75xx
ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
ehci-pci: EHCI PCI platform driver
usbcore: registered new interface driver usb-storage
ci_hdrc ci_hdrc.1: doesn't support gadget
ci_hdrc ci_hdrc.1: EHCI Host Controller
ci_hdrc ci_hdrc.1: new USB bus registered, assigned bus number 1
ci_hdrc ci_hdrc.1: USB 2.0 started, EHCI 1.00
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 1 port detected
mousedev: PS/2 mouse device common for all mice
ads7846 spi32766.0: touchscreen, irq 251
input: ADS0 Touchscreen as /devices/soc0/soc.1/2000000.aips-bus/2000000.spba-bus/2008000.ecspi/spi_master/spi32766/spi32766.0/input/0
ads7846 spi32765.0: touchscreen, irq 266
input: ADS0 Touchscreen as /devices/soc0/soc.1/2000000.aips-bus/2000000.spba-bus/2014000.ecspi/spi_master/spi32765/spi32765.0/input/1
snvs_rtc 20cc034.snvs-rtc-lp: rtc core: registered 20cc034.snvs-rtc-lp as rtc0
i2c /dev entries driver
DBG sensor data is at 808d87d8
mxc_v4l2_output v4l2_out.28: V4L2 device registered as video16
mxc_v4l2_output v4l2_out.28: V4L2 device registered as video17
mxc_v4l2_output v4l2_out.28: V4L2 device registered as video18
mxc_v4l2_output v4l2_out.28: V4L2 device registered as video19
usbcore: registered new interface driver uvcvideo
USB Video Class driver (1.1.1)
imx2-wdt 20bc000.wdog: IMX2+ Watchdog Timer enabled. timeout=60s (nowayout=0)
cpuidle: using governor ladder
cpuidle: using governor menu
sdhci: Secure Digital Host Controller Interface driver
sdhci: Copyright(c) Pierre Ossman
sdhci-pltfm: SDHCI platform and OF driver helper
mmc0: no vqmmc regulator found
mmc0: SDHCI controller on 2190000.usdhc [2190000.usdhc] using ADMA
mmc1: no vqmmc regulator found
mmc1: SDHCI controller on 2198000.usdhc [2198000.usdhc] using ADMA
mmc0: host does not support reading read-only switch. assuming write-enable.
ata1: SATA link down (SStatus 0 SControl 300)
mmc0: new high speed SD card at address b368
mmcblk0: mmc0:b368 00000 1.83 GiB
mmcblk0: p1
usb 1-1: new high-speed USB device number 2 using ci_hdrc
mmc1: BKOPS_EN bit is not set
mmc1: new high speed DDR MMC card at address 0001
mmcblk1: mmc1:0001 M4G1FB 3.64 GiB
mmcblk1boot0: mmc1:0001 M4G1FB partition 1 1.00 MiB
mmcblk1boot1: mmc1:0001 M4G1FB partition 2 1.00 MiB
mmcblk1rpmb: mmc1:0001 M4G1FB partition 3 128 KiB
mmcblk1: p1
mmcblk1boot1: unknown partition table
mmcblk1boot0: unknown partition table
hub 1-1:1.0: USB hub found
hub 1-1:1.0: 4 ports detected
Galcore version 4.6.9.9754
mxc_vdoa 21e4000.vdoa: i.MX Video Data Order Adapter(VDOA) driver probed
mxc_asrc 2034000.asrc: mxc_asrc registered
mxc_vpu 2040000.vpu: VPU initialized
caam 2100000.caam: device ID = 0x0a16010000000000 (Era -524)
caam 2100000.caam: job rings = 2, qi = 0
caam 2100000.caam: authenc-hmac-md5-cbc-aes-caam
caam 2100000.caam: authencesn-hmac-md5-cbc-aes-caam
caam 2100000.caam: authenc-hmac-sha1-cbc-aes-caam
caam 2100000.caam: authencesn-hmac-sha1-cbc-aes-caam
caam 2100000.caam: authenc-hmac-sha224-cbc-aes-caam
caam 2100000.caam: authencesn-hmac-sha224-cbc-aes-caam
caam 2100000.caam: authenc-hmac-sha256-cbc-aes-caam
caam 2100000.caam: authencesn-hmac-sha256-cbc-aes-caam
caam 2100000.caam: authenc-hmac-md5-cbc-des3_ede-caam
caam 2100000.caam: authencesn-hmac-md5-cbc-des3_ede-caam
caam 2100000.caam: authenc-hmac-sha1-cbc-des3_ede-caam
caam 2100000.caam: authencesn-hmac-sha1-cbc-des3_ede-caam
caam 2100000.caam: authenc-hmac-sha224-cbc-des3_ede-caam
caam 2100000.caam: authencesn-hmac-sha224-cbc-des3_ede-caam
caam 2100000.caam: authenc-hmac-sha256-cbc-des3_ede-caam
caam 2100000.caam: authencesn-hmac-sha256-cbc-des3_ede-caam
caam 2100000.caam: authenc-hmac-md5-cbc-des-caam
caam 2100000.caam: authencesn-hmac-md5-cbc-des-caam
caam 2100000.caam: authenc-hmac-sha1-cbc-des-caam
caam 2100000.caam: authencesn-hmac-sha1-cbc-des-caam
caam 2100000.caam: authenc-hmac-sha224-cbc-des-caam
caam 2100000.caam: authencesn-hmac-sha224-cbc-des-caam
caam 2100000.caam: authenc-hmac-sha256-cbc-des-caam
caam 2100000.caam: authencesn-hmac-sha256-cbc-des-caam
caam 2100000.caam: ecb-des-caam
caam 2100000.caam: ecb-arc4-caam
caam 2100000.caam: ecb-aes-caam
caam 2100000.caam: ctr-aes-caam
caam 2100000.caam: cbc-aes-caam
caam 2100000.caam: ecb-des3-caam
caam 2100000.caam: cbc-3des-caam
caam 2100000.caam: cbc-des-caam
caam 2100000.caam: fsl,sec-v4.0 algorithms registered in /proc/crypto
platform 2101000.jr0: registering rng-caam
platform caam_sm: caam_sm_test: 8-byte key test match OK
platform caam_sm: caam_sm_test: 16-byte key test match OK
platform caam_sm: caam_sm_test: 32-byte key test match OK
platform caam_secvio.29: security violation service handlers armed
usbcore: registered new interface driver usbhid
usbhid: USB HID core driver
usbcore: registered new interface driver snd-usb-audio
tlv320aic23-codec 0-001a: codec clk_frequency = 12000000
imx-tlv320 sound.24: tlv320aic23-hifi <-> 202c000.ssi mapping ok
imx-spdif sound-spdif.26: ASoC: CPU DAI (null) not registered
imx-spdif sound-spdif.26: snd_soc_register_card failed: -517
platform sound-spdif.26: Driver imx-spdif requests probe deferral
imx-audio-hdmi sound-hdmi.25: hdmi-hifi <-> hdmi_audio.16 mapping ok
TCP: cubic registered
NET: Registered protocol family 10
sit: IPv6 over IPv4 tunneling driver
NET: Registered protocol family 17
can: controller area network core (rev 20120528 abi 9)
NET: Registered protocol family 29
can: raw protocol (rev 20120528)
can: broadcast manager protocol (rev 20120528 t)
can: netlink gateway (rev 20130117) max_hops=1
8021q: 802.1Q VLAN Support v1.8
Key type dns_resolver registered
VFP support v0.3: implementor 41 architecture 3 part 30 variant 9 rev 4
imx-spdif sound-spdif.26: ASoC: CPU DAI (null) not registered
imx-spdif sound-spdif.26: snd_soc_register_card failed: -517
platform sound-spdif.26: Driver imx-spdif requests probe deferral
snvs_rtc 20cc034.snvs-rtc-lp: setting system clock to 1970-01-01 00:04:04 UTC (244)
ALSA device list:
#0: imx-tlv320
#1: imx-hdmi-soc
FAT-fs (mmcblk0p1): Volume was not properly unmounted. Some data may be corrupt. Please run fsck.
VFS: Mounted root (vfat filesystem) on device 179:1.
devtmpfs: error mounting -2
Freeing unused kernel memory: 228K (80803000 - 8083c000)
Kernel panic - not syncing: No init found. Try passing init= option to kernel. See Linux Documentation/init.txt for guidance.
CPU1: stopping
CPU: 1 PID: 0 Comm: swapper/1 Not tainted 3.10.17 #27
[<8001451c>] (unwind_backtrace+0x0/0xec) from [<80011510>] (show_stack+0x10/0x14)
[<80011510>] (show_stack+0x10/0x14) from [<80013758>] (handle_IPI+0x108/0x118)
[<80013758>] (handle_IPI+0x108/0x118) from [<800084d4>] (gic_handle_irq+0x58/0x5c)
[<800084d4>] (gic_handle_irq+0x58/0x5c) from [<8000dc80>] (__irq_svc+0x40/0x70)
Exception stack(0xac095f48 to 0xac095f90)
5f40: ac095f90 3b9aca00 9af8388a 00000000 99d24a72 00000000
5f60: 81108130 00000001 00000001 808d8d14 00000010 00000000 0000b94a ac095f90
5f80: fffffff7 803f3d24 00000113 ffffffff
[<8000dc80>] (__irq_svc+0x40/0x70) from [<803f3d24>] (cpuidle_enter_state+0x58/0xec)
[<803f3d24>] (cpuidle_enter_state+0x58/0xec) from [<803f3e80>] (cpuidle_idle_call+0xc8/0x158)
[<803f3e80>] (cpuidle_idle_call+0xc8/0x158) from [<8000ec64>] (arch_cpu_idle+0x10/0x54)
[<8000ec64>] (arch_cpu_idle+0x10/0x54) from [<80059efc>] (cpu_startup_entry+0x100/0x14c)
[<80059efc>] (cpu_startup_entry+0x100/0x14c) from [<105e5f64>] (0x105e5f64)
Мог бы кто-нибудь проверить у себя загрузку с неизъятой картой памяти?
Аналогично поведение и на сторонней материской плате с модифицированым файлом
imx6qdl-sodimm.dtsi. В этом случае присутсвуют 2 разъёма sd карты(sd1 и sd2). Загрузка с любой неизъятой картой памяти приводит к краху и зависанию.
И ещё один вопрос касаемо подключения карт.
Вот так происходит подключение карты памяти SD1:
mmc0: host does not support reading read-only switch. assuming write-enable.
mmc0: new high speed SD card at address b368
mmcblk1: mmc0:b368 00000 1.83 GiB
mmcblk1: p1
А вот так происходит подключение карты памяти SD2:
mmc1: host does not support reading read-only switch. assuming write-enable.
mmc1: new high speed SD card at address b368
mmcblk1: mmc1:b368 00000 1.83 GiB
mmcblk1: p1
mmcblk1: error -84 transferring data, sector 64, nr 56, cmd response 0x900, card status 0xb00
mmcblk1: retrying using single block read
mmcblk1: error -84 transferring data, sector 840, nr 8, cmd response 0x900, card status 0xb00
mmcblk1: retrying using single block read
mmcblk1: error -84 transferring data, sector 1032, nr 8, cmd response 0x900, card status 0xb00
mmcblk1: retrying using single block read
В обоих случаях с картой можно работать, но чем могут быть вызваны ошибки в начале при подключении кары SD2?