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

Behold 2 flashing kernel and security (?)

The 1.6 for Galaxy has the .29 kernel (same as 2.x).

There is a community version of 2.x running on the galaxy which has everything working except bluetooth (almost), camera (almost) and 3d (nowhere near).

We have emailed samsung and they said they will release the 1.6 sources on 2nd march. If thats true, we can expect a fully running 2.1 galaxy system soon afterwards!

That's why i'm saying you should use this time to build the galaxy kernel WITH linux console (this is the boot console that shows boot on the phone screen itself), and substitute bh2 drivers as necesary to get it to boot.

If you can do that, you can compile the galaxy 2.x using the same method :)
 
Upvote 0
The 1.6 for Galaxy has the .29 kernel (same as 2.x).

There is a community version of 2.x running on the galaxy which has everything working except bluetooth (almost), camera (almost) and 3d (nowhere near).

We have emailed samsung and they said they will release the 1.6 sources on 2nd march. If thats true, we can expect a fully running 2.1 galaxy system soon afterwards!

That's why i'm saying you should use this time to build the galaxy kernel WITH linux console (this is the boot console that shows boot on the phone screen itself), and substitute bh2 drivers as necesary to get it to boot.

If you can do that, you can compile the galaxy 2.x using the same method :)

I've not had much time to try and build it.. Currently Making a baby room & fixing odd things around the House as well..

Tomorrow I'll have a bit of time to try, & will post any Result's I get..
My biggest issue right now is un-splitting the Ramdisk & Kernel. I get Reboot loops just making the simplest edit.

I need to figured this issue out first, once I solve this, I'll be happy to build a kernel, just last few day's been trying to figure out why the unsplit is wrong, though it splits it fine & my understanding is if it splits, it should un-split fine as well..
 
  • Like
Reactions: tritran18518
Upvote 0
BH_MAN:

Here's the boot log mod I was talking about:

Samsung Galaxy Framebuffer Console

Some kernel messages will drop you into fb mode and you'll need to reboot to get back. So if the screen goes black or white, it means you hit one of those messages.

So this isnt great to leave on, in a final kernel - even tho it looks cool, but realllly usefull for debugging boot isues.
 
Upvote 0
BH_MAN:

Here's the boot log mod I was talking about:

Samsung Galaxy Framebuffer Console

Some kernel messages will drop you into fb mode and you'll need to reboot to get back. So if the screen goes black or white, it means you hit one of those messages.

So this isnt great to leave on, in a final kernel - even tho it looks cool, but realllly usefull for debugging boot isues.

This is still linux, so what about syslog and save all this to a text file?
 
Upvote 0
Yeah sure, but you wont get a syslog until the fs is booted. The first problem you will have is mounting the different partitions on the bh2 i think
But thats what happens for regular linux too.

A nice diagram Inside the Linux boot process

The bootloader(which we dont have access too) loads the kernel and well I dont know as the kernel could be self contained or there is a initid image that it boots too(a ram disk image). But at this point the kernel is loaded and it runs, this is where you get all the cool hackerific messages. After the kernel boots, it mounts in readwrite mode the file system and passes things to init(or init.rc).

This is where we see the Android boot logo(Or with the patch, the Samsung logo). This is where Android starts up, does whatever, including if you got some sort of logging processes, like syslogd, would run as a system service. And then it probably finishes with the locking down of the system.

Since logging is handled by the kernel, and thus if you compile the kernel, you can turn these options back on, it should just require a program like syslogd to plug into the kernel and save the messages to a file.

But my knowledge ends about there. I'm not a programmer so don't know the internals beyond that. Since this is all based off of linux, it would do some good to understand how Linux works in general. Like it says in the article, the kernel is programmed to start init but can be set to start whatever script/program you want after it runs.
 
Upvote 0
No, you're right.. but...

Kernel boots in RAM - we need to log this first.
root filesystem mounted
run init.rc - this mounts other filesystems and runs init scripts in etc or equivalent on android.
kernel modules load and the stuff like the launcher and adbd load.

Normally the kernel always boots, but in this case a galaxy kernel will not boot and get as far as mounting the filesystems and running syslogd. So you are blind as to what went wrong in the kernel itself.

Thats why you need this on screen log of the bootprocess to see where the kernel died.

Once the kernel did boot and we have syslogd, dmesg etc then that is alot easier to work with as you say :)
 
Upvote 0
No, you're right.. but...Normally the kernel always boots, but in this case a galaxy kernel will not boot and get as far as mounting the filesystems and running syslogd. So you are blind as to what went wrong in the kernel itself...

OH duh lol yea forgot about that. Yes, if kernel panics or whatever else stops it from booting yea it wont log. *slaps head* "Have you had your V8 today?" hehehe
 
Upvote 0
great! Did you see the other post about extracting the kernel from the partition dump? You could use that to make a odin file for the 'behold 2 updated kernel' that was in the update

An update on the whole ODIN images..

I tried this the other day and it failed on the system image with an error stating the image size was larger than the partition. I suspect it was just some extra zeroing that cause the issue. I've had to flash back to stock and I'm waiting to get the update before making a second attempt.

Next time I will dump the STL device for the file system images, and keep using the BML device dumps for the raw images. Since each dump is of the respective device's highest level I'm hoping it will be successful next time.

I used GNU tar with Cygwin to create the usTar files in Windows and ODIN took them just fine, no modifications to the uids/gids needed. If I appended the MD5 sums to the end ODIN would crash so there is something I wasn't doing right there.

As soon as I get the update I hope to get a no-root-needed updated ROM image posted.
 
Upvote 0
If you can't get RFS working you may need to remove it and have the kernel use YAFFS2 or similar for the file systems instead.

It may be hard to obtain the header files for the RFS module, legally at least.

Yeah I had the Same thought :) Been Digging around to see what I can come up with, & my guy at Samsung Lips are sealed.. Not mad at him though, Wouldn't want anyone to lose there Job over this.
 
Upvote 0

BEST TECH IN 2023

We've been tracking upcoming products and ranking the best tech since 2007. Thanks for trusting our opinion: we get rewarded through affiliate links that earn us a commission and we invite you to learn more about us.

Smartphones