Author Topic: Porting M5rc14 To Real Hardware  (Read 62396 times)

Mrflying

  • Newbie
  • *
  • Posts: 4
    • View Profile
Porting M5rc14 To Real Hardware
« on: February 18, 2008, 10:38:28 pm »
Hi everyone:
Does anyone can help me? Thanks in advance.
I'm now working on porting m5rc14 to our platform.
I meet 2 problems:

1) when system starts, console seem almost hangs. and process
system_server
occupies 99% of CPU time.

This is my logcat:
W/AudioFlinger(  557): Using stubbed audio hardware. No sound will be
produced.
I/AudioFlinger(  557): AudioFlinger's main thread ready to run.
I/ServiceManager(  539): ServiceManager: addService(AudioFlinger,
0x133f8)
I/sysproc (  557): System server: starting Android runtime.
I/sysproc (  557): System server: starting Android services.
I/SystemServer(  557): Entered the Android system server!
I/sysproc (  557): System server: entering thread pool.
D/TouchDex(  557): TouchDex parent waiting for pid=580 (timeout=36.4s)
I/ServiceManager(  539): ServiceManager: unable to find service
activity
I/runtime (  539): Still waiting for activity manager...
I/ServiceManager(  539): ServiceManager: waiting for service activity
D/AudioFlinger(  557): Audio hardware entering standby
I/ServiceManager(  539): ServiceManager: unable to find service
activity
I/runtime (  539): Still waiting for activity manager...
I/ServiceManager(  539): ServiceManager: waiting for service activity
I/ServiceManager(  539): ServiceManager: unable to find service
activity
I/runtime (  539): Still waiting for activity manager...
I/ServiceManager(  539): ServiceManager: waiting for service activity
I/ServiceManager(  539): ServiceManager: unable to find service
activity
I/runtime (  539): Still waiting for activity manager...
I/ServiceManager(  539): ServiceManager: waiting for service activity
I/ServiceManager(  539): ServiceManager: unable to find service
activity
I/runtime (  539): Still waiting for activity manager...
I/ServiceManager(  539): ServiceManager: waiting for service activity
I/ServiceManager(  539): ServiceManager: unable to find service
activity
I/runtime (  539): Still waiting for activity manager...
I/ServiceManager(  539): ServiceManager: waiting for service activity
I/ServiceManager(  539): ServiceManager: unable to find service
activity
I/runtime (  539): Still waiting for activity manager...
I/ServiceManager(  539): ServiceManager: waiting for service activity
E/TouchDex(  557): timed out waiting for 580; kill(0) returns 0

It seems services don't respond to SeviceManager, it doesn't happen on
previous version

2). There's nothing appear on the screen. (screen is turned to black,
it doesn't happen on previous version, too)

m3rc37 system runs well on our platform with new released kernel.

cortez

  • Sr. Member
  • ****
  • Posts: 375
    • View Profile
    • http://www.omegamoon.com
Porting M5rc14 To Real Hardware
« Reply #1 on: February 19, 2008, 03:32:56 am »
Did you create a new kernel with latest Google patches applied?
If not, then don't bother to try, it won't work on the kernel used in the previous release, since they made some major changes.
[div align=\"center\"]== == == == == == == == == == == == == ==
www.omegamoon.com
Zaurus SL-C750 - Died in a dreadful coffee experiment, has a second life somewhere in the Czech Republic
Zaurus SL-C1000 - Multiboot Zubuntu, Debian, Fedora, Poky, Android and others
Zaurus SL-C3100 - Development device, currently Zubuntu 2.0
Zaurus SL-6000L - The fridge is running Zubuntu 1.0
Zaurus SL-C860 - Cacko, untouched since kindly donated, waiting for Zubuntu
== == == == == == == == == == == == == ==[/div]

jpmatrix

  • Hero Member
  • *****
  • Posts: 1014
    • View Profile
    • http://matrixmen.free.fr
Porting M5rc14 To Real Hardware
« Reply #2 on: February 19, 2008, 10:50:02 am »
Quote from: cortez
Did you create a new kernel with latest Google patches applied?
If not, then don't bother to try, it won't work on the kernel used in the previous release, since they made some major changes.

is there the same for kernel 2.6.24 ? i cannot find it...
would someone (2orO ?  compile it for us please ?
« Last Edit: February 19, 2008, 10:50:39 am by jpmatrix »
**Fujitsu U1010 !!!  
**ex-Zaurus SL-C3000 owner with Debian kernel 2.6.24-yonggun

Android Zaurus

  • Newbie
  • *
  • Posts: 45
    • View Profile
    • http://androidzaurus.seesaa.net
Porting M5rc14 To Real Hardware
« Reply #3 on: February 19, 2008, 09:47:52 pm »
Quote from: Mrflying
2). There's nothing appear on the screen. (screen is turned to black,
it doesn't happen on previous version, too)

Same for Angstrom Zaurus. Just blank screen, nothing displayed.

I don't think this would work though, give a try to copy /dev/fb0 to /dev/graphics/fb0 and chmod 666. The emulator is working like that.

Android Zaurus: Confusing issue of Android m5_rc14
http://androidzaurus.seesaa.net/article/84934031.html

Mrflying

  • Newbie
  • *
  • Posts: 4
    • View Profile
Porting M5rc14 To Real Hardware
« Reply #4 on: February 21, 2008, 04:15:09 am »
Quote from: Android Zaurus
Quote from: Mrflying
2). There's nothing appear on the screen. (screen is turned to black,
it doesn't happen on previous version, too)

Same for Angstrom Zaurus. Just blank screen, nothing displayed.

I don't think this would work though, give a try to copy /dev/fb0 to /dev/graphics/fb0 and chmod 666. The emulator is working like that.

Android Zaurus: Confusing issue of Android m5_rc14
http://androidzaurus.seesaa.net/article/84934031.html


I've tried copy a binary to /dev/graphics/fb0, and it can work. My framebuffer driver works well
But Android still not print something on the screem. It semms google make some  modification on
SufaceFlinger serives.
As I trace the system bootup, it uses mmap to map /dev/graphics/fb0 to memory.

BTW, the boot very slow problem is solved, it's because my flash driver I/O thread's priority is too low.
Now system can boot successfully, but still have nothing on screen
« Last Edit: February 21, 2008, 04:18:24 am by Mrflying »

speculatrix

  • Administrator
  • Hero Member
  • *****
  • Posts: 3703
    • View Profile
Porting M5rc14 To Real Hardware
« Reply #5 on: February 21, 2008, 05:57:08 pm »
Quote from: Mrflying
I've tried copy a binary to /dev/graphics/fb0, and it can work. My framebuffer driver works well
But Android still not print something on the screem. It semms google make some  modification on
SufaceFlinger serives.
As I trace the system bootup, it uses mmap to map /dev/graphics/fb0 to memory.

how did you copy it?

you need to do "cp -prd /dev/XXX /dev/graphics/" to copy the device, or, better yet, use "mknod" instead!
Gemini 4G/Wi-Fi owner, formerly zaurus C3100 and 860 owner; also owner of an HTC Doubleshot, a Zaurus-like phone.

Mrflying

  • Newbie
  • *
  • Posts: 4
    • View Profile
Porting M5rc14 To Real Hardware
« Reply #6 on: February 21, 2008, 10:04:20 pm »
Quote from: speculatrix
Quote from: Mrflying
I've tried copy a binary to /dev/graphics/fb0, and it can work. My framebuffer driver works well
But Android still not print something on the screem. It semms google make some  modification on
SufaceFlinger serives.
As I trace the system bootup, it uses mmap to map /dev/graphics/fb0 to memory.

how did you copy it?

you need to do "cp -prd /dev/XXX /dev/graphics/" to copy the device, or, better yet, use "mknod" instead!

I use android's original init, and it creates device node automatically; /dev/graphics/fb0 (29, 0) is alreadly there
when system boot-up.
I mean I copy a binary image into the fb device, and there's something shown on screen
And I also use mmap() to map the fb device, write something, and it works.
My framebuffer driver seems works fine.

Mrflying

  • Newbie
  • *
  • Posts: 4
    • View Profile
Porting M5rc14 To Real Hardware
« Reply #7 on: February 21, 2008, 10:12:46 pm »
Quote from: cortez
Did you create a new kernel with latest Google patches applied?
If not, then don't bother to try, it won't work on the kernel used in the previous release, since they made some major changes.

Ya. I've updated to newest kernel. Google do minor modify on new kernel. The major change is the binder driver.

jpmatrix

  • Hero Member
  • *****
  • Posts: 1014
    • View Profile
    • http://matrixmen.free.fr
Porting M5rc14 To Real Hardware
« Reply #8 on: February 22, 2008, 02:35:11 pm »
Quote from: Mrflying
Quote from: cortez
Did you create a new kernel with latest Google patches applied?
If not, then don't bother to try, it won't work on the kernel used in the previous release, since they made some major changes.

Ya. I've updated to newest kernel. Google do minor modify on new kernel. The major change is the binder driver.

so is it working now?
**Fujitsu U1010 !!!  
**ex-Zaurus SL-C3000 owner with Debian kernel 2.6.24-yonggun

speculatrix

  • Administrator
  • Hero Member
  • *****
  • Posts: 3703
    • View Profile
Porting M5rc14 To Real Hardware
« Reply #9 on: February 25, 2008, 05:51:31 pm »
very much please to have even a partial version working!!!
Gemini 4G/Wi-Fi owner, formerly zaurus C3100 and 860 owner; also owner of an HTC Doubleshot, a Zaurus-like phone.

cortez

  • Sr. Member
  • ****
  • Posts: 375
    • View Profile
    • http://www.omegamoon.com
Porting M5rc14 To Real Hardware
« Reply #10 on: February 26, 2008, 02:51:58 am »
Quote from: speculatrix
very much please to have even a partial version working!!!
You mean you don't even care that the screen is black all the time?  
I've created an installable image from the new SDK. From what I see in the traces Android starts normally. It's just that there's nothing displayed...
[div align=\"center\"]== == == == == == == == == == == == == ==
www.omegamoon.com
Zaurus SL-C750 - Died in a dreadful coffee experiment, has a second life somewhere in the Czech Republic
Zaurus SL-C1000 - Multiboot Zubuntu, Debian, Fedora, Poky, Android and others
Zaurus SL-C3100 - Development device, currently Zubuntu 2.0
Zaurus SL-6000L - The fridge is running Zubuntu 1.0
Zaurus SL-C860 - Cacko, untouched since kindly donated, waiting for Zubuntu
== == == == == == == == == == == == == ==[/div]

speculatrix

  • Administrator
  • Hero Member
  • *****
  • Posts: 3703
    • View Profile
Porting M5rc14 To Real Hardware
« Reply #11 on: February 26, 2008, 07:37:36 am »
Quote from: cortez
Quote from: speculatrix
very much please to have even a partial version working!!!
You mean you don't even care that the screen is black all the time?  
I've created an installable image from the new SDK. From what I see in the traces Android starts normally. It's just that there's nothing displayed...

if you tap around on the screen, can you tell if something's happening by looking at debug output and any processes/threads running?
Gemini 4G/Wi-Fi owner, formerly zaurus C3100 and 860 owner; also owner of an HTC Doubleshot, a Zaurus-like phone.

zaurick

  • Newbie
  • *
  • Posts: 17
    • View Profile
Porting M5rc14 To Real Hardware
« Reply #12 on: February 26, 2008, 11:48:32 am »
Quote from: cortez
Quote from: speculatrix
very much please to have even a partial version working!!!
You mean you don't even care that the screen is black all the time?  
I've created an installable image from the new SDK. From what I see in the traces Android starts normally. It's just that there's nothing displayed...

Hi,

Have you got some IOCTL errors about /dev/fb or /dev/graphics in the debug output.
The last time i've got a black screen problem when porting an appli, it was because of the use of a double framebuffer.
The framebuffer was mmaped in ram with the size of two screens and it started with the second screen !!!
and then tried to switch the base address of the visible window with "FBIOPAN" IOCTL (don't work with our driver).
Maybe It's not our actual problem, but i have no other idea.

All of you make a great work about porting android !!!

cortez

  • Sr. Member
  • ****
  • Posts: 375
    • View Profile
    • http://www.omegamoon.com
Porting M5rc14 To Real Hardware
« Reply #13 on: February 26, 2008, 12:36:23 pm »
Quote from: zaurick
Quote from: cortez
Quote from: speculatrix
very much please to have even a partial version working!!!
You mean you don't even care that the screen is black all the time?  
I've created an installable image from the new SDK. From what I see in the traces Android starts normally. It's just that there's nothing displayed...

Hi,

Have you got some IOCTL errors about /dev/fb or /dev/graphics in the debug output.
The last time i've got a black screen problem when porting an appli, it was because of the use of a double framebuffer.
The framebuffer was mmaped in ram with the size of two screens and it started with the second screen !!!
and then tried to switch the base address of the visible window with "FBIOPAN" IOCTL (don't work with our driver).
Maybe It's not our actual problem, but i have no other idea.

All of you make a great work about porting android !!!

I see no IOCTL errors of significance. All devices are created nicely when running the /init executable, including /dev/graphics/fb0. This is no double framebuffer as far as I can tell. All services start successfully (I don't see the errors as described in the first post).

The main difference between Qemu emulator and Zaurus seems to be the supported OpenGL options. From what I remember, the Zaurus doesn't support page flipping.
[div align=\"center\"]== == == == == == == == == == == == == ==
www.omegamoon.com
Zaurus SL-C750 - Died in a dreadful coffee experiment, has a second life somewhere in the Czech Republic
Zaurus SL-C1000 - Multiboot Zubuntu, Debian, Fedora, Poky, Android and others
Zaurus SL-C3100 - Development device, currently Zubuntu 2.0
Zaurus SL-6000L - The fridge is running Zubuntu 1.0
Zaurus SL-C860 - Cacko, untouched since kindly donated, waiting for Zubuntu
== == == == == == == == == == == == == ==[/div]

Android Zaurus

  • Newbie
  • *
  • Posts: 45
    • View Profile
    • http://androidzaurus.seesaa.net
Porting M5rc14 To Real Hardware
« Reply #14 on: February 26, 2008, 08:32:55 pm »
My guess for now. Let the Android use drivers/video/pxafb.c not platform driver in arch/arm/mach-pxa. I'm working on another project for now and my Zaurus is configured for m3 Android. Later I'd like to try to build the kernel with CONFIG_FB_PXA=m and see what happens.

By the way, I found this wiki is very informational.

Android on OMAP - Embeddedlinux
http://elinux.org/Android_on_OMAP