Ник:
Пароль:

Контакты

E-mail: info@starterkit.ru
тел.: +7 922 680-21-73
тел.: +7 922 680-21-74
Телеграм: t.me/starterkit_ru
Партнеры:
otladka.com.ua - г.Киев

Способы оплаты

User Info


Добро пожаловать,
Guest

Регистрация или входРегистрация или вход
Потеряли пароль?Потеряли пароль?

Ник:
Пароль:

ПользователейПользователей:0
Поисковых ботовПоисковых ботов:3
ГостейГостей:1

ОбновитьПодробнееВсегоВсего:4
Форум » starterkit.ru » ARM
imx233 sd card boot linux uncompress problem
sasamy
Добавлено 22.10.2010 15:35 Сообщение: 21
sasamy
4.70

Пункты: 75729
Регистрация: 14.08.2009
Цитата
Hello,
As I mentioned below, if you give me a mmc_config fie inculing SSP1 MMC boot and ext2 rootfs support in for mmcblkop2 . it really could help me to get further steps. Thanks.


Firstly - our kernel will not work with MMC on ssp1, see sk-mks.patch
Код

-CMDLINE_DEVICE_CHOOSE (ssp1, mmc, spi1)
+ CMDLINE_DEVICE_CHOOSE (ssp2, mmc, gpmi_nfc)


you need the original kernel. To compile a kernel with MMC on ssp1 - edit the kernel config before building include a boot argument like this

CONFIG_CMDLINE = "console=ttyAM0,115200 ssp1=mmc root=/dev/mmcblk0p2 rootfstype=ext2 rootwaitt"

Second - original imx-bootlets loader uses a keyboard with lradc, reads it and change the kernel boot options. I disabled it because we do not have a keyboard and the result can be unpredictable:
imx-bootlets-src-10.05.02/linux_prep/core/setup.c

Код

u32 setup_tags (void)
{
// enum magic_key magic_key;

// magic_key = get_magic_key();
// find_command_lines();

setup_start_tag();
setup_mem_tag();
// setup_initrd_tag();
// setup_cmdline_tag(cmdlines[magic_key]);
setup_end_tag();

return (u32)ATAGS_BASE_ADDRESS;
}


Regards.
Спуститься к концу Подняться к началу
Персональная информация
itmicro
Добавлено 22.10.2010 17:53 Сообщение: 22
itmicro
0

Пункты: 2274
Регистрация: 20.10.2010
Thank you for explanation. I have changed the comand line as you recommended : CONFIG_CMDLINE = "console=ttyAM0,115200 ssp1=mmc root=/dev/mmcblk0p2 rootfstype=ext2 rootwaitt"

I get below output


RPC: Registered udp transport module.

RPC: Registered tcp transport module.

mxs-rtc mxs-rtc.0: setting system clock to 1970-01-01 00:00:11 UTC (11)

Root-NFS: No NFS server available, giving up.

VFS: Unable to mount root fs via NFS, trying floppy.

VFS: Cannot open root device "mmcblk0p2" or unknown-block(2,0)

Please append a correct "root=" boot option; here are the available partitions:

Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)

Why does the kernel still complain about boot option although we set . Thanks,



Цитата
[quote]Hello,
As I mentioned below, if you give me a mmc_config fie inculing SSP1 MMC boot and ext2 rootfs support in for mmcblkop2 . it really could help me to get further steps. Thanks.


Firstly - our kernel will not work with MMC on ssp1, see sk-mks.patch
Код

-CMDLINE_DEVICE_CHOOSE (ssp1, mmc, spi1)
+ CMDLINE_DEVICE_CHOOSE (ssp2, mmc, gpmi_nfc)


you need the original kernel. To compile a kernel with MMC on ssp1 - edit the kernel config before building include a boot argument like this

CONFIG_CMDLINE = "console=ttyAM0,115200 ssp1=mmc root=/dev/mmcblk0p2 rootfstype=ext2 rootwaitt"

Second - original imx-bootlets loader uses a keyboard with lradc, reads it and change the kernel boot options. I disabled it because we do not have a keyboard and the result can be unpredictable:
imx-bootlets-src-10.05.02/linux_prep/core/setup.c

Код

u32 setup_tags (void)
{
// enum magic_key magic_key;

// magic_key = get_magic_key();
// find_command_lines();

setup_start_tag();
setup_mem_tag();
// setup_initrd_tag();
// setup_cmdline_tag(cmdlines[magic_key]);
setup_end_tag();

return (u32)ATAGS_BASE_ADDRESS;
}


Regards.[/quote]
Спуститься к концу Подняться к началу
Персональная информация
itmicro
Добавлено 22.10.2010 19:16 Сообщение: 23
itmicro
0

Пункты: 2274
Регистрация: 20.10.2010
Hello,

Where is the exact location of kernel config ? Which file should I modify ? Thanks

Цитата
Thank you for explanation. I have changed the comand line as you recommended : CONFIG_CMDLINE = "console=ttyAM0,115200 ssp1=mmc root=/dev/mmcblk0p2 rootfstype=ext2 rootwaitt"

I get below output


RPC: Registered udp transport module.

RPC: Registered tcp transport module.

mxs-rtc mxs-rtc.0: setting system clock to 1970-01-01 00:00:11 UTC (11)

Root-NFS: No NFS server available, giving up.

VFS: Unable to mount root fs via NFS, trying floppy.

VFS: Cannot open root device "mmcblk0p2" or unknown-block(2,0)

Please append a correct "root=" boot option; here are the available partitions:

Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)

Why does the kernel still complain about boot option although we set . Thanks,



[quote][quote]Hello,
As I mentioned below, if you give me a mmc_config fie inculing SSP1 MMC boot and ext2 rootfs support in for mmcblkop2 . it really could help me to get further steps. Thanks.


Firstly - our kernel will not work with MMC on ssp1, see sk-mks.patch
Код

-CMDLINE_DEVICE_CHOOSE (ssp1, mmc, spi1)
+ CMDLINE_DEVICE_CHOOSE (ssp2, mmc, gpmi_nfc)


you need the original kernel. To compile a kernel with MMC on ssp1 - edit the kernel config before building include a boot argument like this

CONFIG_CMDLINE = "console=ttyAM0,115200 ssp1=mmc root=/dev/mmcblk0p2 rootfstype=ext2 rootwaitt"

Second - original imx-bootlets loader uses a keyboard with lradc, reads it and change the kernel boot options. I disabled it because we do not have a keyboard and the result can be unpredictable:
imx-bootlets-src-10.05.02/linux_prep/core/setup.c

Код

u32 setup_tags (void)
{
// enum magic_key magic_key;

// magic_key = get_magic_key();
// find_command_lines();

setup_start_tag();
setup_mem_tag();
// setup_initrd_tag();
// setup_cmdline_tag(cmdlines[magic_key]);
setup_end_tag();

return (u32)ATAGS_BASE_ADDRESS;
}


Regards.[/quote][/quote]
Спуститься к концу Подняться к началу
Персональная информация
sasamy
Добавлено 22.10.2010 22:02 Редактировалось 22.10.2010 22:04 Сообщение: 24
sasamy
4.70

Пункты: 75729
Регистрация: 14.08.2009
Цитата

Where is the exact location of kernel config ? Which file should I modify ?


$./ltib -m config
[*] Configure the kernel
[*] Leave the sources after building
$./ltib
in kernel menuconfig
Boot options --->
(console=ttyAM0,115200 ssp1=mmc root=/dev/mmcblk0p2 rootfstype=ext2 rootwait) Default kernel command string

Device Drivers ---> <*> MMC/SD/SDIO card support --->
<*> MMC block device driver
[*] Use bounce buffer for simple hosts
<*> MXS MMC support

File systems --->
<*> Second extended fs support
[*] Ext2 extended attributes
[*] Ext2 POSIX Access Control Lists
[*] Ext2 Security Labels

After build, kernel sources can be found here
ltib/rpm/BUILD/linux-2.6.31
and kernel configuration file
ltib/rpm/BUILD/linux-2.6.31/.config
Спуститься к концу Подняться к началу
Персональная информация
itmicro
Добавлено 23.10.2010 00:47 Сообщение: 25
itmicro
0

Пункты: 2274
Регистрация: 20.10.2010
Hello,

I made all the settings you recommended. I get below output as a result :

ALSA device list:
#0: MXS EVK (mxs adc/dac)
TCP cubic registered
NET: Registered protocol family 10
IPv6 over IPv4 tunneling driver
NET: Registered protocol family 17
RPC: Registered udp transport module.
RPC: Registered tcp transport module.
mxs-rtc mxs-rtc.0: setting system clock to 1970-01-01 00:00:11 UTC (11)
Root-NFS: No NFS server available, giving up.
VFS: Unable to mount root fs via NFS, trying floppy.
VFS: Cannot open root device "mmcblk0p2" or unknown-block(2,0)
Please append a correct "root=" boot option; here are the available partitions:
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)

What do you think about the reason of this kernel panic. Thanks

Regards


Цитата
Цитата

Where is the exact location of kernel config ? Which file should I modify ?


$./ltib -m config
[*] Configure the kernel
[*] Leave the sources after building
$./ltib
in kernel menuconfig
Boot options --->
(console=ttyAM0,115200 ssp1=mmc root=/dev/mmcblk0p2 rootfstype=ext2 rootwait) Default kernel command string

Device Drivers ---> <*> MMC/SD/SDIO card support --->
<*> MMC block device driver
[*] Use bounce buffer for simple hosts
<*> MXS MMC support

File systems --->
<*> Second extended fs support
[*] Ext2 extended attributes
[*] Ext2 POSIX Access Control Lists
[*] Ext2 Security Labels

After build, kernel sources can be found here
ltib/rpm/BUILD/linux-2.6.31
and kernel configuration file
ltib/rpm/BUILD/linux-2.6.31/.config
Спуститься к концу Подняться к началу
Персональная информация
sasamy
Добавлено 23.10.2010 01:46 Сообщение: 26
sasamy
4.70

Пункты: 75729
Регистрация: 14.08.2009
Hi. You need to ask on the forum freescale. Kernel parameter has changed - it is the work ltib & imx-bootlets. I do not know how to fix it in ltib. I could not successfully build ltib
Спуститься к концу Подняться к началу
Персональная информация
itmicro
Добавлено 23.10.2010 03:09 Сообщение: 27
itmicro
0

Пункты: 2274
Регистрация: 20.10.2010
Hello,
I found the reason of problem related mmc mounting. If you forget umount the device after you write rootfs in mmc, mmc would remain an unwanted state.

Pls see below output,

-----------------------------------------------------------------------------------
mxs-rtc mxs-rtc.0: setting system clock to 1970-01-01 00:00:11 UTC (11)
Waiting for root device /dev/mmcblk0p2...
mmc0: new high speed SDHC card at address e624
mmcblk0: mmc0:e624 SU04G 3.69 GiB
mmcblk0: p1 p2
EXT2-fs warning: mounting unchecked fs, running e2fsck is recommended
VFS: Mounted root (ext2 filesystem) on device 179:2.
Freeing init memory: 136K
Warning: unable to open an initial console.
Kernel panic - not syncing: No init found. Try passing init= option to kernel.
------------------------------------------------------------------------------------

how can I pass init= option to kernel ? Would you tell me proper definition about that. Thanks

PS: I believe that all the conversation happened among us would be very usefull for new developers to understand some basic steps. Thats great I think

Regards,

Цитата
Hi. You need to ask on the forum freescale. Kernel parameter has changed - it is the work ltib & imx-bootlets. I do not know how to fix it in ltib. I could not successfully build ltib
Спуститься к концу Подняться к началу
Персональная информация
sasamy
Добавлено 23.10.2010 13:49 Редактировалось 23.10.2010 14:00 Сообщение: 28
sasamy
4.70

Пункты: 75729
Регистрация: 14.08.2009
Цитата

how can I pass init= option to kernel ? Would you tell me proper definition about that.


The default first process created by the kernel init=/sbin/init, you can change this by passing the command line init=/path/to/my/init but it does not solve your problem

Boot options --->
(console=ttyAM0,115200 init=/path/to/my/init ssp1=mmc root=/dev/mmcblk0p2 rootfstype=ext2 rootwait) Default kernel command string

Your root file system does not include /sbin/init - as I wrote it is not properly built or empty or incorrectly recorded. How do you write rootfs on SD/MMC?

PS where can I download your rootfs image to check it out?
Спуститься к концу Подняться к началу
Персональная информация
itmicro
Добавлено 23.10.2010 14:17 Сообщение: 29
itmicro
0

Пункты: 2274
Регистрация: 20.10.2010
Hello,

Actually, for testing purpose I download ready to use image from freescale web site and wrote into sd card memory ext2 partition which I created. The reason choosing ready image , LTIB does not provide an option to create a custom rootfs.ext image for SD/MMC. It only gives ramdisk support for ext2 image genaration. You can check this link : http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=IMX23EVK&fpsp=1&tab=Design_Tools_Tab

File name which includes ready to use images is : L2.6.31_MX23_SDK_1005_IMAGE

Meanwhile, how can I get rootfs.ext image properly by myself ? Do you have any proper one for booting my device on mmc1 and mmblk0p2 for ext2 ? Thanks,



Цитата
Цитата

how can I pass init= option to kernel ? Would you tell me proper definition about that.


The default first process created by the kernel init=/sbin/init, you can change this by passing the command line init=/path/to/my/init but it does not solve your problem

Boot options --->
(console=ttyAM0,115200 init=/path/to/my/init ssp1=mmc root=/dev/mmcblk0p2 rootfstype=ext2 rootwait) Default kernel command string

Your root file system does not include /sbin/init - as I wrote it is not properly built or empty or incorrectly recorded. How do you write rootfs on SD/MMC?

PS where can I download your rootfs image to check it out?
Спуститься к концу Подняться к началу
Персональная информация
itmicro
Добавлено 23.10.2010 19:41 Сообщение: 30
itmicro
0

Пункты: 2274
Регистрация: 20.10.2010
Hello,

Dear my friend,great news once again :)) I could eventually mount the ext2 file system to my kernel properly. I have been working silly mistake. I was trying to copy rootfs.ext2 image instead of my rootfs directory to the mmcblk0p2 partition of MMC. It is done now.

Next step is getting my tft panel worked with my device. I realized that you have written a very nice driver for SSD19xx and put it into kernel which you given in your web site. When I try to compile that, I get many errors. How can I adapt your driver into my linux kernel comes from Freescale BSP.

Thanks,


Цитата
Hello,

Actually, for testing purpose I download ready to use image from freescale web site and wrote into sd card memory ext2 partition which I created. The reason choosing ready image , LTIB does not provide an option to create a custom rootfs.ext image for SD/MMC. It only gives ramdisk support for ext2 image genaration. You can check this link : http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=IMX23EVK&fpsp=1&tab=Design_Tools_Tab

File name which includes ready to use images is : L2.6.31_MX23_SDK_1005_IMAGE

Meanwhile, how can I get rootfs.ext image properly by myself ? Do you have any proper one for booting my device on mmc1 and mmblk0p2 for ext2 ? Thanks,



Цитата
Цитата

how can I pass init= option to kernel ? Would you tell me proper definition about that.


The default first process created by the kernel init=/sbin/init, you can change this by passing the command line init=/path/to/my/init but it does not solve your problem

Boot options --->
(console=ttyAM0,115200 init=/path/to/my/init ssp1=mmc root=/dev/mmcblk0p2 rootfstype=ext2 rootwait) Default kernel command string

Your root file system does not include /sbin/init - as I wrote it is not properly built or empty or incorrectly recorded. How do you write rootfs on SD/MMC?

PS where can I download your rootfs image to check it out?
Спуститься к концу Подняться к началу
Персональная информация
Форум » starterkit.ru » ARM