SERIAL_CONSOLE PROBLEM ON COMMON_ANDROID_KERNEL-3.10

vicky
Hi Everyone, Hope you guys are doing well.

I'm trying to build common_android_kernel-3.10 on mini2440(x35).
Did configuration by merging three configuration (mini2440_defconfig,
android-base.cfg and config_mini2440_x35) files using
scripts/kconfig/merge_config.sh. Got zImage successfully, without any
errors.

PROBLEM: Problem is not able to see kernel messages on my pc. I'm
using ttyUSB0 serial cable with minicom tool. Did changes changes on
default kernel command line options as console=ttySAC0,115200. Not able to
find the solution.

I would be thankful if anyone helps me.

kangear
I got the same problem on 3.10.
there is a bug about UART clock on 3.10.
here:
https://github.com/torvalds/linux/commit/ee2f769fb4a5a317b1558d0bbcccb89...

after 3.10.4, they fixed this bug.

by the way, if there is nothing kernel messages, you can enable
CONFIG_DEBUG_LL see some low debug message.
menuconfig --->
 Kernel hacking  ---> 
  [*] Kernel debugging
  [*] Kernel low-level debugging functions (read help!)
      Kernel low-level debugging port (Use S3C UART 0 for low-level debug) 
--->

kangear
Supplement:
After enable CONFIG_DEBUG_LL, I can't get this kernel message:
"Warning: Neither atags nor dtb found"

which is print with func "early_print", It can works fine than prink.
so I find the bug from git log.

finally, I use the 3.10.4, UART can works fine.


hope helpful to you. :P

kangear
Sorry, there is a wrong spelling.

Supplement:
After enable CONFIG_DEBUG_LL, I *can get this kernel message:
"Warning: Neither atags nor dtb found"

which is print with func "early_print", It can works fine than prink.
so I find the bug (about UART clock) from mainline kernel git log.

finally, I use the 3.10.4, UART can works fine.


hope helpful to you. :P

vicky
Dear kangear....

Thanq you so much for your help. It worked fine

kangear
Hi vicky.

with 3.10.4, I can't get any voice.
have you tried this? and can you give me some advice ?

but with 3.12, I can get voice.

And I'm trying to modify 3.10.4 to MINI2440, there is the GIT repo:
https://github.com/kangear/linux/commits/mini2440/v3.10.4_modify

Maybe we do it together. :)

vicky
Hi kangear.

Hope you doing good. I'm very sorry to say that I didn't try voice.

I'm trying to bring up android on mini2440 with 'android kernel 3.10',
using boot loader: 'supervivi128M' and I downloaded file system from
http://www.friendlyarm.net/forum/topic/5458

Modified file system as ext3 format using 'mkext3image' binary file. Passed
command line arguments as 'noinitrd root=/dev/mtdblock2 init=/linuxrc
console=ttySAC0,115200'

PROBLEM: Getting errors

No soundcards found.
end_request: I/O error, dev mtdblock2, sector 2
EXT3-fs (mtdblock2): error: unable to read superblock
end_request: I/O error, dev mtdblock2, sector 2
EXT4-fs (mtdblock2): unable to read superblock
end_request: I/O error, dev mtdblock2, sector 2
EXT4-fs (mtdblock2): unable to read superblock
FAT-fs (mtdblock2): utf8 is not a recommended IO charset for FAT
filesystems, filesystem will be case sensitive!
__nand_correct_data: uncorrectable ECC error
end_request: I/O error, dev mtdblock2, sector 0
FAT-fs (mtdblock2): unable to read boot sector
VFS: Cannot open root device "mtdblock2" or unknown-block(31,2): error -5
Please append a correct "root=" boot option; here are the available
partitions:
1f00             256 mtdblock0  (driver?)
1f01             128 mtdblock1  (driver?)
1f02            5120 mtdblock2  (driver?)
1f03         1043072 mtdblock3  (driver?)
Kernel panic - not syncing: VFS: Unable to mount root fs on
unknown-block(31,2)
CPU: 0 PID: 1 Comm: swapper Not tainted 3.10.0-FriendlyARM #17
Backtrace: 
[<c0012248>] (dump_backtrace+0x0/0x10c) from [<c001245c>]
(show_stack+0x18/0x1c)
 r6:c04a9510 r5:00008001 r4:c042fdf0 r3:00000000
[<c0012444>] (show_stack+0x0/0x1c) from [<c037a260>] (dump_stack+0x20/0x28)
[<c037a240>] (dump_stack+0x0/0x28) from [<c0377868>] (panic+0x88/0x1d0)
[<c03777e0>] (panic+0x0/0x1d0) from [<c048dd50>]
(mount_block_root+0x1c4/0x270)
 r3:00000001 r2:00000000 r1:c0837ea0 r0:c042fdf0
 r7:c042fe58
[<c048db8c>] (mount_block_root+0x0/0x270) from [<c048dfe4>]
(mount_root+0xec/0x114)
[<c048def8>] (mount_root+0x0/0x114) from [<c048e16c>]
(prepare_namespace+0x160/0x1b4)
 r8:c04a94e8 r7:c04e9ea0 r6:c04a9510 r5:c04a9510 r4:c04e9f00
[<c048e00c>] (prepare_namespace+0x0/0x1b4) from [<c048d948>]
(kernel_init_freeable+0x16c/0x1b0)
 r6:c04e9ea0 r5:00000007 r4:c04af86c
[<c048d7dc>] (kernel_init_freeable+0x0/0x1b0) from [<c037671c>]
(kernel_init+0x10/0x158)
[<c037670c>] (kernel_init+0x0/0x158) from [<c000ec10>]
(ret_from_fork+0x14/0x24)
 r5:c037670c r4:00000000

Hope you can give advices to me, if you don't mind.
Email Id: vikramp1991@gmail.com

kangear
Hi vicky. there are some advice for you.

1.add "rootfstype=ext3" in command line, and try it.

2.actually, I didn't try ext3 filesystem on Mini2440, I only tried Yaffs2.
If there still are some problem, maybe you can try Yaffs2 filesystem.

3.I guess that maybe you flash the rootfs(ext3) use flash yaffs2 fs way. so
...

vicky
Dear kangear, Thanks for your response.

1. I tried by passing 'rootfstype=ext3' in command line. But still getting
Kernel panic - not syncing: VFS: Unable to mount root fs on
unknown-block(31,2).

2. And also I tried with 'initramfs'. This time I'm getting error : Kernel
panic - not syncing: Attempted to kill init! exitcode=0x0000000b

3. I tried yaffs2 file system. Created yaffs2 file system using
'mkyaffs2image-128M'. I found that there is no supported configuration for
yaffs2 file system in android kernel 3.10.

Can you share where I need to change kernel source code or where can I find
default supported yaffs2 file system android kernel.

Please share info through mail, if you don't mind.
Email Id: vikramp1991@gmail.com

Thanks.

vicky
Hi kangear,

Got yaffs2 file system patches from:
https://github.com/kangear/linux/commit/089b3744d9605814b48d4754eea6d2a6...

Mounted file system successfully. Now I'm able to activate console (Please
press Enter to activate this console) on my pc through serial cable and
also able to see bootup logo (penguin).

PROBLEM: Not able to see graphics on board. Please share info, if you are
aware.

kangear
Hi vicky.

congrats you for mounting rootfs successfully.

And I'm sorry that I am not very clear to your LAST PROBLEM.
Can you describe some of the more clearly it?

vicky
Hi kangear...

Problem is "Not able to see any applications on board".

Using 2.6.27 android kernel I'm able to see applications as like below
video shows. You can find video here:
https://www.youtube.com/watch?v=ouaKNhytEdo

I'm trying to bring up the board as like above video shows, using common
android kernel 3.10 and yaffs2 file system. For that I did configuration by
merging three configuration (mini2440_defconfig, android-base.cfg and
config_mini2440_x35) files using scripts/kconfig/merge_config.sh.

I think there are lot of changes happened in between android kernel 2.6 and
android kernel 3.10 according to android changes, and file systems too.
I'm not aware how to fix these issues.

Can you advice me where can I find default android kernel configuration
file (or kernel image) and android file system. Hope you understood
clearly. 

Thanks for your response.

kangear
Hi, vicky

Yes, I'm clear now.
But I haven't try Linux _3.10_ for Android on Mini2440.
So, I can't advice something about __3.10__.

BTW,I had tried the android image (kernel and filesystem) which was
provided by FriendlyARM on Mini2440.

Images is here: http://www.arm9.net/download.asp  (Chinese)
And there are some pictures I took.
http://www.arm9home.net/read.php?tid=27499 (Chinese)


Enjoy it. :)

vicky
Hi kangear...

Thanks for your help.