HAZZA24937
Posts: 13
Joined: Tue May 29, 2012 3:05 am

Patching a Linux or Unix based OS to support ARM11

Tue May 29, 2012 3:09 am

Say the model b Raspberry Pi is used which has an ARM11 CPU, how hard is it to patch the Kernel of an OS to support ARM11? and where can I find how to? I have looked for Tutorials but can't find any.
Some help would be appreciated.

felix123
Posts: 153
Joined: Tue May 15, 2012 6:06 am

Re: Patching a Linux or Unix based OS to support ARM11

Tue May 29, 2012 4:01 am

You can't just patch it. You have to find the source code and then compile it for arm.

HAZZA24937
Posts: 13
Joined: Tue May 29, 2012 3:05 am

Re: Patching a Linux or Unix based OS to support ARM11

Tue May 29, 2012 8:30 am

felix123 wrote:You can't just patch it. You have to find the source code and then compile it for arm.
So how is that done and how difficult is it?

User avatar
cheery
Posts: 219
Joined: Wed Jan 25, 2012 9:39 pm

Re: Patching a Linux or Unix based OS to support ARM11

Tue May 29, 2012 8:56 am

It should be straightforward, might be hard but I'm not sure about that. There's probably not tutorials for this, but everything(most) required is described in the manuals and these forums supplement the rest.

The next simplest thing to get started would be to get the kernel boot up and interface with some small set of hardware you can measure. GPIO/UART etc. Would be my choice of initial hardware support. Remember to go one step at a time. Get first concerned about getting it to boot up and after that get concerned with the interfacing (try blink a LED first!).

A small platform-dependent example kernel would work well as a kind of 'tutorial' you're asking for, but nobody seems to have done one yet! I am sure we'll get some as Raspberry Pi did not went under the radar of OS-developers and their communities.

How to apply the gained knowledge into your project then? You need to divide your kernel to platform dependent and platform independent code. Platform dependent code should be written in portable language and should be about the only code you don't need to rewrite for a kernel port. You also need to port the language's compiler if it's not ported already.. But... that's.. about it.

User avatar
AndrewS
Posts: 3625
Joined: Sun Apr 22, 2012 4:50 pm
Location: Cambridge, UK
Contact: Website

Re: Patching a Linux or Unix based OS to support ARM11

Tue May 29, 2012 3:29 pm

Have a look at http://elinux.org/R-Pi_Hub#Software_.26 ... tributions and http://elinux.org/Rpi_kernel_compilation

Maybe if you explain in more detail what it is you're trying to do, we could point you in the right direction...

HAZZA24937
Posts: 13
Joined: Tue May 29, 2012 3:05 am

Re: Patching a Linux or Unix based OS to support ARM11

Wed May 30, 2012 12:16 pm

Thanks cherry and Andrew.
Specifically what I am trying to do is retrace Apple footsteps when they ported OS X 10.4 to the Iphone and made iOS (but leave most OS X features). Thus making the cheapest available Hackintosh Distro.
I have already gained some help from a hacker friend and we are under way, i have source code and the compiler now so I will talk to my friends soon.
Also, I am going to move this thread to a different forum if I need more advice.

User avatar
AndrewS
Posts: 3625
Joined: Sun Apr 22, 2012 4:50 pm
Location: Cambridge, UK
Contact: Website

Re: Patching a Linux or Unix based OS to support ARM11

Thu May 31, 2012 12:26 am

Sounds like it's of dubious legality - so probably best not to discuss it on these forums.
And without wanting to sound rude, this is another one of those things where if you have ask how to do it, then it probably means you won't be able to do it.

Squiffy
Posts: 14
Joined: Sat Jun 30, 2012 9:11 pm

Re: Patching a Linux or Unix based OS to support ARM11

Sun Jul 01, 2012 3:12 am

iOS is more than just a kernel. The bootloader process is very long. iOS devices use other processors to boot the device as well. To say the least, iOS can't be ported. It is simply impossible. And the kernel already in existence for iOS would probably run fine on ARM11. Its not like ARM decides to get a new instruction set every revision. I could go into more detail but its not even worth it. Just know that this is impossible.

6677
Posts: 383
Joined: Wed Mar 14, 2012 9:23 pm

Re: Patching a Linux or Unix based OS to support ARM11

Tue Jul 17, 2012 7:36 pm

HAZZA24937 wrote:Thanks cherry and Andrew.
retrace Apple footsteps when they ported OS X 10.4 to the Iphone and made iOS (but leave most OS X features)
They didn't. iOS isn't a port of macOS. Its a new OS.

Squiffy
Posts: 14
Joined: Sat Jun 30, 2012 9:11 pm

Re: Patching a Linux or Unix based OS to support ARM11

Mon Jul 23, 2012 11:08 pm

6677 wrote:
HAZZA24937 wrote:Thanks cherry and Andrew.
retrace Apple footsteps when they ported OS X 10.4 to the Iphone and made iOS (but leave most OS X features)
They didn't. iOS isn't a port of macOS. Its a new OS.
This is correct. If anything, it was a port of FreeBSD with its special XNU kernel with a few extras.

Return to “Other”