Diffrece Between Android Kernel and Linux Kernel

42 views
Skip to first unread message

Pankaj

unread,
Jun 25, 2010, 7:07:24 AM6/25/10
to android-porting
Hi all

I want to know diffrence beween android kernel and linux kernel.
Can any one give me some information regarding that?

Thank you
Pankaj Gadhiya

Subramani Venkatesh

unread,
Jun 25, 2010, 7:31:50 AM6/25/10
to gadhiya_...@yahoo.co.in, android-porting
Android uses same open source Linux kernel, there is no much
difference, other than few kernel modules like Binders addition...

> --
> unsubscribe: android-porti...@googlegroups.com
> website: http://groups.google.com/group/android-porting
>

Pankaj

unread,
Jun 25, 2010, 8:20:52 AM6/25/10
to android-porting
Hi
Thank you very much for the reply
Actually i want to run android in my PCB. It has superH arch
processor.
I am sucsessfully compiled android source code for the superh arch.
Also i have kernel which is sucessfully run in my PCB but android is
not run yet.
Now i want to porting android in my PCB. So i have used my own PCB
kernel.
So i think some changes is necessary in my kernel for the run andorid
in my PCB.

So i want to know that how much changes is necessary in kernel code?
Also do you know a main file where android is start?

Thank you in advance
Pankaj Gadhiya
> > website:http://groups.google.com/group/android-porting- Hide quoted text -
>
> - Show quoted text -

Ashwin Bihari

unread,
Jun 25, 2010, 8:39:57 AM6/25/10
to android-porting
There is Android support in 2.6.29-rc3 and 2.6.32 Kernel's..so
depending on what version of Kernel you are using, just do a diff
between the two trees. Take out anything that you've added to make it
work on your board, ignore all the common stuff, and whatever is
leftover are all things that most likely Android needs..

Regards
-- Ashwin

Srikant

unread,
Jun 25, 2010, 12:28:57 PM6/25/10
to android-porting
The main file in Android is system/core/init/init.c, which parses the
kernel command line, parses init.rc etc.
> > > website:http://groups.google.com/group/android-porting-Hide quoted text -

Sunny Aujla

unread,
Jun 25, 2010, 8:14:16 AM6/25/10
to subbu...@gmail.com, gadhiya_...@yahoo.co.in, android-porting
Hi Pankaj,

There's not much difference. 
The Android kernel code has been removed from the main kernel tree as of the 2.6.33 kernel release

The Android code was in the main kernel tree before 2.6.33 kernel release but no one cared about the code, so it was removed. Then google had taken over this code.
Google has taken the Linux kernel, and nothing else from a traditional Linux system, and created a portable and robust phone platform.  What this means now is:

Drivers written for Android hardware platforms, can not get merged into the main kernel tree because they have dependencies on code that only lives in Google's kernel tree, causing it to fail to build in the kernel tree. Because of this, Google has now prevented a large chunk of hardware drivers and platform code from ever getting merged into the main kernel tree.

Hope that gives you some insight of what has happened.

Regards,

Dianne Hackborn

unread,
Jun 25, 2010, 8:00:43 PM6/25/10
to sunnyf...@gmail.com, subbu...@gmail.com, gadhiya_...@yahoo.co.in, android-porting
On Fri, Jun 25, 2010 at 5:14 AM, Sunny Aujla <sunnyf...@gmail.com> wrote:
Drivers written for Android hardware platforms, can not get merged into the main kernel tree because they have dependencies on code that only lives in Google's kernel tree, causing it to fail to build in the kernel tree. Because of this, Google has now prevented a large chunk of hardware drivers and platform code from ever getting merged into the main kernel tree.

I'm not going to get into a huge discussion on this, but Google engineers spent a very large amount of time rewriting code 5 or 6 times and addressing a huge number of questions and requests to get this into the mainline kernel. Ultimately, however, the mainline maintainers let this drag out and never accepted the patches.  It is pretty out there to lay the blame for the current situation all on Google's feet.

--
Dianne Hackborn
Android framework engineer
hac...@android.com

Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails.  All such questions should be posted on public forums, where I and others can see and answer them.

Tim Bird

unread,
Jun 25, 2010, 8:37:02 PM6/25/10
to sunnyf...@gmail.com, subbu...@gmail.com, gadhiya_...@yahoo.co.in, android-porting
On 06/25/2010 05:14 AM, Sunny Aujla wrote:
> Hi Pankaj,
>
> There's not much difference.�
> The Android kernel code has been removed from the main kernel tree as of
> the 2.6.33 kernel release
>
> The Android code was in the main kernel tree before 2.6.33 kernel
> release but no one cared about the code, so it was removed. Then google
> had taken over this code.
> Google has taken the Linux kernel, and nothing else from a traditional
> Linux system, and created a portable and robust phone platform.� What
> this means now is:
>
> Drivers written for Android hardware platforms, can not get merged into
> the main kernel tree because they have dependencies on code that only
> lives in Google's kernel tree, causing it to fail to build in the kernel
> tree. Because of this, Google has now prevented a large chunk of
> hardware drivers and platform code from ever getting merged into the
> main kernel tree.

That's a pretty biased and simplistic narrative. Google has
expended a lot of effort to mainline their power management
code. Nothing prevents the authors of these "large chunks of
hardware drivers and platform code" from isolating the
wakelock callouts from the rest of their code, and mainlining
the core parts. Sometimes out-of-tree code has to "stew" for
years before being accepted in one form or another. In the
mean time, I don't think it's productive to blame Google for
lack of mainlining code that they mostly didn't write in
the first place, when they've made serious attempts to
mainline their stuff.

=============================
Tim Bird
Architecture Group Chair, CE Linux Forum
Senior Staff Engineer, Sony Network Entertainment
=============================

Ashwin Bihari

unread,
Jun 26, 2010, 11:33:53 AM6/26/10
to sunnyf...@gmail.com, subbu...@gmail.com, gadhiya_...@yahoo.co.in, android-porting
Sunny,

Your narrative clearly says that you've never actually TRIED to get
anything into the Linux Kernel mainline..it takes a very concentrated
and prolonged effort to get the simplest thing reviewed and
accepted..so the changes that Google made would take a considerable
amount of time..

Google isn't necessarily the one to blame here and aren't the only
people out that the maintain a Kernel tree that parallels in the
mainline Kernel but is separate..

-- Ashwin

Pankaj

unread,
Jun 28, 2010, 9:16:53 AM6/28/10
to android-porting

Hi

Thank you very much for the reply.
I think discussion is goting some wrong way.
I am newbee in android poriting .

Actually i want to run android in my PCB. It has superH arch
processor.

I am sucsessfully compiled android source code for the superh arch.
Also i have kernel which is sucessfully run in my PCB but android is
not run yet.

Now i want to porting android in my PCB. So i have used my own PCB
kernel.

After build source code sucssessfully, copy ramdisk.img file in my CF
card
and create folder structure using unzip ramdisk,img file.

Copy userland in SD card (system and data).

After this for run android, i try to run init file.
But i can't get android boot logo.

Please guide me on this topic.
Should i have changes to kernel or any other code.
I am trying to run init file for android starup. it is right way?

Thank you in advance
Pankaj Gadhiya

> >> On Fri, Jun 25, 2010 at 7:07 AM, Pankaj <gadhiya_pankaj...@yahoo.co.in>
> >> wrote:
> >> > Hi all
>
> >> > I want to know diffrence beween android kernel and linux kernel.
> >> > Can any one give me some information regarding that?
>
> >> > Thank you
> >> > Pankaj Gadhiya
>
> >> > --
> >> > unsubscribe: android-porti...@googlegroups.com
> >> > website:http://groups.google.com/group/android-porting
>
> >> --
> >> unsubscribe: android-porti...@googlegroups.com
> >> website:http://groups.google.com/group/android-porting
>
> > --
> > unsubscribe: android-porti...@googlegroups.com
> > website:http://groups.google.com/group/android-porting- Hide quoted text -
Reply all
Reply to author
Forward
0 new messages