Jump to content

    

Промышленный компьютер тион-про28

find {kernel_source_tree_root}/drivers -name "mxs-mm*" -print

Хотя я бы для начала все же убедился в целостности файловой системы, и явно сказал бы rootfstype= rw

Share this post


Link to post
Share on other sites

Не могу найти пути к функциям в debian 9 mxs_mmc_get_wp_ssp0 и mxs_mmc_get_ro. Прошу помощи. 

Share this post


Link to post
Share on other sites

А причем тут дебиан вообще? Это функции внутри драйверов ядра. Вы по-прежнему будете самодеятельностью заниматься или все-же снизойдете до ответов на вопросы?

Share this post


Link to post
Share on other sites

Я не совсем понимаю как правильно применить команду rootfstype= rw. Если есть возможно расскажите более подробно как эта сделать. Просто отправить rootfstype= rw в момент остановки загрузки или нужно, как-то предварительно зайти в загрузчик и после отправить  rootfstype= rw ?  По ссылки указаны пути поиска device.c (..../ltib/rpm/BUILD/linux-2.6.35.3/arch/arm/mach-mx28/device.c) и mxs-mmc.c (..../ltib/rpm/BUILD/linux-2.6.35.3/drivers/mmc/host/mxs-mmc.c)  у меня linux-4.17.8 и папки mach-mx28 нет, а в mxs-mmc.c нет функции mxs_mmc_get_ro. 

Share this post


Link to post
Share on other sites

Не нужно ничего никуда добавлять пока, нужно править DeviceTree под вашу плату:

buildroot/output/build/linux-???/arch/arm/boot/dts/imx28-evk.dts

(??? - не помню, как точно должна называться директория, если ядро строит buildroot. В будущем надо будет уметь его собирать отдельно)

 

Находим там:

			ssp0: ssp@80010000 {
				compatible = "fsl,imx28-mmc";
				pinctrl-names = "default";
				pinctrl-0 = <&mmc0_8bit_pins_a
					&mmc0_cd_cfg &mmc0_sck_cfg>;
				bus-width = <8>;
				wp-gpios = <&gpio2 12 0>;
				vmmc-supply = <&reg_vddio_sd0>;
				status = "okay";
			};

и убираем строку wp-gpios.

 

Далее запускаем сборку.

Share this post


Link to post
Share on other sites

Да, судя по схеме, WP там не прослеживается, и bus-width явно не 8, надо уточнить, есть ли в .dtsi отдельный пример конфига для SD (этот явно для MMC). Либо взять этот кусок из DT U-Boot'а (судя по дате, он тоже свежесобранный)

Share this post


Link to post
Share on other sites

Убрал строку wp-gpios = <&gpio2 12 0>; в linux-4.17.8 (есть еще linux-headers-4.17.8 его не трогал)  собрал проект выполнив команды

cd buildroot
make freescale_imx28evk_defconfig
make

проект собрался намного быстрее чем в прошлый раз.

Вопрос перед закатывание на cd-карту при помощи dd нужно отформатировать cd-карту?  

Edited by Alex_Golubev

Share this post


Link to post
Share on other sites
6 minutes ago, Alex_Golubev said:

Вопрос перед закатывание на cd-карту при помощи dd нужно отформатировать cd-карту? 

Нет, dd в данном случае -посекторное копирование. И вообще, в будущем, я бы попробовал подняться хотя бы до 4.19...

Share this post


Link to post
Share on other sites

удалил строчку wp-gpios = <&gpio2 12 0>; ошибка осталась. 

Spoiler

<0>HTLLCLLC

U-Boot 2018.05 (May 13 2019 - 12:28:49 +0700)

CPU:   Freescale i.MX28 rev1.2 at 454 MHz
BOOT:  SSP SD/MMC #0, 3V3
SPI:   ready
DRAM:  128 MiB
No arch specific invalidate_icache_all available!
NAND:  256 MiB
MMC:   MXS MMC: 0
Loading Environment from MMC... *** Warning - bad CRC, using default environment

Failed (-5)
Video: MXSFB: 'videomode' variable not set!
In:    serial
Out:   serial
Err:   serial
Net:   FEC0 [PRIME], FEC1
Hit any key to stop autoboot:  0 
switch to partitions #0, OK
mmc0 is current device
** Unable to read file boot.scr **
4506312 bytes read in 1334 ms (3.2 MiB/s)
Booting from mmc ...
22340 bytes read in 31 ms (703.1 KiB/s)
Kernel image @ 0x42000000 [ 0x000000 - 0x44c2c8 ]
## Flattened Device Tree blob at 41000000
   Booting using the fdt blob at 0x41000000
   Loading Device Tree to 47b17000, end 47b1f743 ... OK

Starting kernel ...

[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] Linux version 4.17.8 (alexey@alexey) (gcc version 7.4.0 (Buildroot 2019.05-rc1-00022-g653bf93837)) #1 Mon May 13 12:30:12 +07 2019
[    0.000000] CPU: ARM926EJ-S [41069265] revision 5 (ARMv5TEJ), cr=0005317f
[    0.000000] CPU: VIVT data cache, VIVT instruction cache
[    0.000000] OF: fdt: Machine model: Freescale i.MX28 Evaluation Kit
[    0.000000] Memory policy: Data cache writeback
[    0.000000] random: get_random_bytes called from start_kernel+0x84/0x474 with crng_init=0
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 32512
[    0.000000] Kernel command line: console=ttyAMA0,115200 root=/dev/mmcblk0p3 rw rootwait
[    0.000000] Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
[    0.000000] Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
[    0.000000] Memory: 113240K/131072K available (6064K kernel code, 555K rwdata, 2008K rodata, 300K init, 7442K bss, 17832K reserved, 0K cma-reserved)
[    0.000000] Virtual kernel memory layout:
[    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
[    0.000000]     fixmap  : 0xffc00000 - 0xfff00000   (3072 kB)
[    0.000000]     vmalloc : 0xc8800000 - 0xff800000   ( 880 MB)
[    0.000000]     lowmem  : 0xc0000000 - 0xc8000000   ( 128 MB)
[    0.000000]     modules : 0xbf000000 - 0xc0000000   (  16 MB)
[    0.000000]       .text : 0x(ptrval) - 0x(ptrval)   (6066 kB)
[    0.000000]       .init : 0x(ptrval) - 0x(ptrval)   ( 300 kB)
[    0.000000]       .data : 0x(ptrval) - 0x(ptrval)   ( 556 kB)
[    0.000000]        .bss : 0x(ptrval) - 0x(ptrval)   (7443 kB)
[    0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[    0.000000] Running RCU self tests
[    0.000000] NR_IRQS: 16, nr_irqs: 16, preallocated irqs: 16
[    0.000000] clocksource: mxs_timer: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 79635851949 ns
[    0.000031] sched_clock: 32 bits at 24MHz, resolution 41ns, wraps every 89478484971ns
[    0.002268] Console: colour dummy device 80x30
[    0.002430] Lock dependency validator: Copyright (c) 2006 Red Hat, Inc., Ingo Molnar
[    0.002497] ... MAX_LOCKDEP_SUBCLASSES:  8
[    0.002551] ... MAX_LOCK_DEPTH:          48
[    0.002602] ... MAX_LOCKDEP_KEYS:        8191
[    0.002651] ... CLASSHASH_SIZE:          4096
[    0.002702] ... MAX_LOCKDEP_ENTRIES:     32768
[    0.002752] ... MAX_LOCKDEP_CHAINS:      65536
[    0.002802] ... CHAINHASH_SIZE:          32768
[    0.002853]  memory used by lock dependency info: 4655 kB
[    0.002903]  per task-struct memory footprint: 1536 bytes
[    0.003103] Calibrating delay loop... 226.09 BogoMIPS (lpj=1130496)
[    0.071443] pid_max: default: 32768 minimum: 301
[    0.072577] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.072687] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.081135] CPU: Testing write buffer coherency: ok
[    0.090280] Setting up static identity map for 0x40008400 - 0x40008458
[    0.103342] devtmpfs: initialized
[    0.165032] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.165283] futex hash table entries: 256 (order: 1, 11264 bytes)
[    0.166931] pinctrl core: initialized pinctrl subsystem
[    0.181215] NET: Registered protocol family 16
[    0.184220] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.389925] Serial: AMBA PL011 UART driver
[    0.393553] 80074000.serial: ttyAMA0 at MMIO 0x80074000 (irq = 236, base_baud = 0) is a PL011 rev2
[    0.715226] console [ttyAMA0] enabled
[    0.802306] mxs-dma 80004000.dma-apbh: initialized
[    0.820354] mxs-dma 80024000.dma-apbx: initialized
[    0.847359] SCSI subsystem initialized
[    0.854330] usbcore: registered new interface driver usbfs
[    0.860607] usbcore: registered new interface driver hub
[    0.866917] usbcore: registered new device driver usb
[    0.881770] pps_core: LinuxPPS API ver. 1 registered
[    0.887042] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[    0.896455] PTP clock support registered
[    0.903453] Advanced Linux Sound Architecture Driver Initialized.
[    0.917968] clocksource: Switched to clocksource mxs_timer
[    1.575538] NET: Registered protocol family 2
[    1.585201] tcp_listen_portaddr_hash hash table entries: 128 (order: 0, 5120 bytes)
[    1.593384] TCP established hash table entries: 1024 (order: 0, 4096 bytes)
[    1.600744] TCP bind hash table entries: 1024 (order: 3, 36864 bytes)
[    1.608351] TCP: Hash tables configured (established 1024 bind 1024)
[    1.615911] UDP hash table entries: 256 (order: 2, 20480 bytes)
[    1.622701] UDP-Lite hash table entries: 256 (order: 2, 20480 bytes)
[    1.630910] NET: Registered protocol family 1
[    1.641799] RPC: Registered named UNIX socket transport module.
[    1.648307] RPC: Registered udp transport module.
[    1.653103] RPC: Registered tcp transport module.
[    1.658078] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    1.679348] workingset: timestamp_bits=30 max_order=15 bucket_order=0
[    1.769266] NFS: Registering the id_resolver key type
[    1.775478] Key type id_resolver registered
[    1.780245] Key type id_legacy registered
[    1.784841] jffs2: version 2.2. (NAND) В© 2001-2006 Red Hat, Inc.
[    1.816566] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 248)
[    1.824580] io scheduler noop registered (default)
[    1.829712] io scheduler mq-deadline registered
[    1.834343] io scheduler kyber registered
[    1.848365] pwm-backlight backlight: backlight supply power not found, using dummy regulator
[    1.906916] Console: switching to colour frame buffer device 100x30
[    1.934039] mxsfb 80030000.lcdif: initialized
[    1.945792] 8006a000.serial: ttyAPP0 at MMIO 0x8006a000 (irq = 234, base_baud = 1500000) is a 8006a000.serial
[    1.958355] mxs-auart 8006a000.serial: Found APPUART 3.1.0
[    1.966334] 80070000.serial: ttyAPP3 at MMIO 0x80070000 (irq = 235, base_baud = 1500000) is a 80070000.serial
[    1.978957] mxs-auart 80070000.serial: Found APPUART 3.1.0
[    2.029934] random: fast init done
[    2.070575] nand: device found, Manufacturer ID: 0x2c, Chip ID: 0xda
[    2.077033] nand: Micron MT29F2G08ABAEAWP
[    2.081339] nand: 256 MiB, SLC, erase size: 128 KiB, page size: 2048, OOB size: 64
[    2.097338] Scanning device for bad blocks
[    3.361904] gpmi-nand 8000c000.gpmi-nand: driver registered.
[    3.398678] m25p80 spi1.0: unrecognized JEDEC id bytes: ff, ff, ff
[    3.410429] libphy: Fixed MDIO Bus: probed
[    3.566926] libphy: fec_enet_mii_bus: probed
[    3.577455] fec 800f4000.ethernet: 800f4000.ethernet supply phy not found, using dummy regulator
[    3.594794] usbcore: registered new interface driver asix
[    3.600943] usbcore: registered new interface driver ax88179_178a
[    3.607489] usbcore: registered new interface driver cdc_ether
[    3.614171] usbcore: registered new interface driver smsc95xx
[    3.620682] usbcore: registered new interface driver net1080
[    3.626785] usbcore: registered new interface driver cdc_subset
[    3.633394] usbcore: registered new interface driver zaurus
[    3.639847] usbcore: registered new interface driver cdc_ncm
[    3.645609] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    3.652958] usbcore: registered new interface driver usb-storage
[    3.690214] ci_hdrc ci_hdrc.1: EHCI Host Controller
[    3.696166] ci_hdrc ci_hdrc.1: new USB bus registered, assigned bus number 1
[    3.728278] ci_hdrc ci_hdrc.1: USB 2.0 started, EHCI 1.00
[    3.748834] hub 1-0:1.0: USB hub found
[    3.753755] hub 1-0:1.0: 1 port detected
[    3.773898] input: mxs-lradc-ts as /devices/soc0/80000000.apb/80040000.apbx/80050000.lradc/mxs-lradc-ts/input/input0
[    3.794832] stmp3xxx-rtc 80056000.rtc: rtc core: registered 80056000.rtc as rtc0
[    3.804414] i2c /dev entries driver
[    3.818749] stmp3xxx_rtc_wdt stmp3xxx_rtc_wdt: initialized watchdog with heartbeat 19s
[    3.833186] mxs-mmc 80010000.ssp: Got WP GPIO
[    3.870602] mxs-mmc 80010000.ssp: initialized
[    3.897502] mxs-dcp 80028000.dcp: Failed to register sha1 hash!
[    3.907132] mxs-dcp: probe of 80028000.dcp failed with error -22
[    3.920915] usbcore: registered new interface driver usbhid
[    3.926585] usbhid: USB HID core driver
[    3.947253] mmc0: new high speed SDHC card at address aaaa
[    3.972939] mmcblk0: mmc0:aaaa SL16G 14.8 GiB (ro)
[    4.013670] mxs-sgtl5000 sound: ASoC: CODEC DAI sgtl5000 not registered
[    4.026335]  mmcblk0: p1 p2 p3
[    4.031117] NET: Registered protocol family 17
[    4.036894] Key type dns_resolver registered
[    4.066154] registered taskstats version 1
[    4.154152] sgtl5000 0-000a: Error reading chip id -6
[    4.165483] mxs-sgtl5000 sound: ASoC: CODEC DAI sgtl5000 not registered
[    4.176217] stmp3xxx-rtc 80056000.rtc: setting system clock to 1970-01-01 00:00:09 UTC (9)
[    4.186214] usb0_vbus: disabling
[    4.190488] can-3v3: disabling
[    4.193660] ALSA device list:
[    4.196697]   No soundcards found.
[    4.205306] uart-pl011 80074000.serial: no DMA platform data
[    4.214449] VFS: Cannot open root device "mmcblk0p3" or unknown-block(179,3): error -30
[    4.222837] Please append a correct "root=" boot option; here are the available partitions:
[    4.231661] 1f00          262144 mtdblock0 
[    4.231703]  (driver?)
[    4.238595] b300        15558144 mmcblk0 
[    4.238639]  driver: mmcblk
[    4.245563]   b301           16384 mmcblk0p1 00000000-01
[    4.245599] 
[    4.252730]   b302           16384 mmcblk0p2 00000000-02
[    4.252769] 
[    4.259905]   b303           61440 mmcblk0p3 00000000-03
[    4.259943] 
[    4.266874] Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(179,3)
[    4.275388] CPU: 0 PID: 1 Comm: swapper Not tainted 4.17.8 #1
[    4.281191] Hardware name: Freescale MXS (Device Tree)
[    4.286461] [<c0011010>] (unwind_backtrace) from [<c000f1a4>] (show_stack+0x10/0x14)
[    4.294326] [<c000f1a4>] (show_stack) from [<c001ad4c>] (panic+0xcc/0x258)
[    4.301319] [<c001ad4c>] (panic) from [<c0816574>] (mount_block_root+0x1bc/0x2c0)
[    4.308900] [<c0816574>] (mount_block_root) from [<c0816788>] (mount_root+0x110/0x154)
[    4.316909] [<c0816788>] (mount_root) from [<c08168f4>] (prepare_namespace+0x128/0x188)
[    4.325009] [<c08168f4>] (prepare_namespace) from [<c0816140>] (kernel_init_freeable+0x310/0x36c)
[    4.333986] [<c0816140>] (kernel_init_freeable) from [<c05ed700>] (kernel_init+0x8/0xf0)
[    4.342177] [<c05ed700>] (kernel_init) from [<c00090b0>] (ret_from_fork+0x14/0x24)
[    4.349808] Exception stack(0xc7483fb0 to 0xc7483ff8)
[    4.354929] 3fa0:                                     00000000 00000000 00000000 00000000
[    4.363179] 3fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
[    4.371423] 3fe0: 00000000 00000000 00000000 00000000 00000013 00000000
[    4.378149] ---[ end Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(179,3) ]---
[   67.598137] random: crng init done
 

 

 

Edited by Alex_Golubev

Share this post


Link to post
Share on other sites
4 hours ago, Alex_Golubev said:

удалил строчку wp-gpios = <&gpio2 12 0>; ошибка осталась

Проверьте дату и время файлов:

ls -l output/build/linux-4.17.8/arch/arm/boot/dts/imx28-evk.dt*

 

Share this post


Link to post
Share on other sites

Выполнил команду. Дата 15 мая 12:26, еще раз сохранил imx28-evk.dts.

проверка даты и времени.png

Share this post


Link to post
Share on other sites

Как вариант - тормозните U-Boot и попробуйте почитать этот раздел U-Boot'ом - у него драйвер SD/MMC, видимо, рабочий. ext2ls mmc 0:2 /

Share this post


Link to post
Share on other sites
Quote

тормозните U-Boot и попробуйте почитать этот раздел U-Boot'ом

Можете более подробно рассказать как это сделать ? Чтобы я быстрее сделал. 

Edited by Alex_Golubev

Share this post


Link to post
Share on other sites
5 hours ago, Alex_Golubev said:

Hit any key to stop autoboot:  0 

 

Share this post


Link to post
Share on other sites
40 minutes ago, gosha-z said:

Как вариант - тормозните U-Boot и попробуйте почитать этот раздел U-Boot'ом - у него драйвер SD/MMC, видимо, рабочий. ext2ls mmc 0:2 /

Зачем, если результат заранее известен?

5 hours ago, Alex_Golubev said:

[    4.214449] VFS: Cannot open root device "mmcblk0p3" or unknown-block(179,3): error -30

30 Read only file system

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now