• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Root Intro guide to understanding kernels?

ddongell

Newbie
Can someone please post a link to a thread regarding kernels? I'd just like to understand as much as possible between the different types before I begin trying them. Thank you!
 
This might help:

Android Runtime

Android includes a set of core libraries that provides most of the functionality available in the core libraries of the Java programming language.
Every Android application runs in its own process, with its own instance of the Dalvik virtual machine. Dalvik has been written so that a device can run multiple VMs efficiently. The Dalvik VM executes files in the Dalvik Executable (.dex) format which is optimized for minimal memory footprint. The VM is register-based, and runs classes compiled by a Java language compiler that have been transformed into the .dex format by the included "dx" tool.
The Dalvik VM relies on the Linux kernel for underlying functionality such as threading and low-level memory management.


Linux Kernel


Android relies on Linux version 2.6 for core system services such as security, memory management, process management, network stack, and driver model. The kernel also acts as an abstraction layer between the hardware and the rest of the software stack.



What is Android? | Android Developers
 
General ROM FAQ - Android Forums

A. Parts of a ROM

i. The kernel.
Android (like many other Smartphone operating systems) runs on the Linux kernel. The Linux kernel was created in the early 1990’s by a gentleman named Linus Torvalds in Helsinki Finland. It’s incredibly stable, incredibly friendly, and incredibly difficult for the layman to understand and modify. Thankfully it’s also very popular so it has been ported on to a multitude of hardware, including our Android devices.

Think of the kernel as an interface layer between the hardware and software on your device. The kernel decides when things happen, such as the LED indicator gets lit. An application sends a request to the operating system to blink the LED. The operating system then sends the request to the kernel, which makes the light flash for the amount of time requested by the OS.

What sounds like a round-about way to get things done is also what makes the system so scalable and robust. Application developers only have to code in a way the operating system understands and the kernel makes it work on the hardware. This also keeps the application running in it’s own user-space and separate from the kernel. That means when you run the latest uber-cool app that wasn’t designed for your particular OS version, or is still very beta and it crashes, the kernel gives you the option to Force Close the application and the kernel can run untouched.

In a standard Android ROM (we will leave developer images and the like for another discussion) the kernel is bundled along with a set of instructions that tell the device how to load the kernel and the OS during boot. This is the boot.img that you see inside a zipped ROM that your not able to easily open. The device knows to extract this image to internal memory (the ramdisk) and follow a series of scripts (init scripts) to load the kernel and then the other portions of the OS. That’s what’s happening while you’re watching the boot animation. Interestingly enough this is done the same way for a PC, your smartphone, an Android tablet, or even a smart Linux powered toaster. If you’re feeling exceptionally geeky, plug your Android phone into the USB port on your PC and let the PC boot from the USB device. No, it doesn’t actually load, but you can watch the animation while it tries to match up the hardware support with what’s inside your PC. As I said, Linux is amazingly scalable and as a result so is Android.
 
Wow, those are all very in-depth answers! I was more interested in knowing the difference between a havs-more and havs-less kernel, things like that. Haha but thank you both for taking the time to explain the idea behind how kernels work! I'm trying kings unleashed 2 right now and am going to trying a few different kernels, but I really won't know what each one is doing if I don't understand the difference between them. For example, the difference between the 4 or 5 toastmod kernels that come with the rom.
 
Also when flashing a kernel, I've read to wipe both partition cache and dalvik cache, but in my clockwork recovery (2.6.0.1) it onlt lists 'wipe partition cache.' Is that all I would need to do?
 
Also when flashing a kernel, I've read to wipe both partition cache and dalvik cache, but in my clockwork recovery (2.6.0.1) it onlt lists 'wipe partition cache.' Is that all I would need to do?


You might want to try RA recovery 2.3. Check my sig for a link to it.
 
Back
Top Bottom