Real-time linux kernel


47 posts   Page 1 of 2   1, 2
by IDE » Mon Jan 16, 2012 6:13 pm
Is there any 2.6 real-time kernels available for the Raspberry Pi?
Posts: 52
Joined: Fri Jan 13, 2012 12:28 am
by jamesh » Mon Jan 16, 2012 6:20 pm
Not as such, but its fairly easy to rebuild the kernel with the right options to make it a bit more real time. Think the patches for that are in mainline now.
Soon to be unemployed software engineer currently specialising in camera drivers and frameworks, but can put mind to most embedded tasks. Got a job in N.Cambridge or surroundings? I'm interested!
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 11559
Joined: Sat Jul 30, 2011 7:41 pm
by manicgeek » Mon Jan 16, 2012 8:22 pm
On the subject of which is there a defconfig file for the RasPi?
Posts: 44
Joined: Tue Aug 30, 2011 5:31 pm
by selvmarcus » Wed Jan 18, 2012 5:10 am
What kernel version will we likely see for the release?

Will you supply your patches upstream? This would allow the real-time patch developers to have an eye on them.

How easy will be migration to newer (and therefore more real-time capable) kernels?

You can access official real-time patches, instructions and tests from here:

https://rt.wiki.kernel.org/

Patches are slowly migrated to mainline kernel. 3.0 and 3.2 are recent major steps, from what I got.

The claim has been for (almost) hard real-time performance on linux with these latest patches, this would still be depending on the well-behaving of custom drivers, SoC design and custom kernel patches.

But certainly there is light at the end of the tunnel!

Marcus
Posts: 18
Joined: Sat Jan 07, 2012 1:21 pm
by mung » Thu Jan 19, 2012 5:53 pm
for some reason I cannot post to this thread????

I am adding small copy and paste snippets, as I think this is due to anti spam tests and will not allow me to paste more than a few characters?????

I have spent this morning trying to work out how to compile the kernel with rtai.

I am no expert and have no real experience with low level programming of ARM or of linux kernel programming, so I am probably not the best person to be doing this.
 
So far it is a fail, but I hope if I document what I have done someone better than I will be successful.

I think the HAL patch needs fixing (actually applying

:D
  )and also the rtai config from 'make config' was not quite correct, I hope someone who knows has some help.

The simple step by step guide to how to compile the kernel using the http://russelldavis.org/2011/09/10/virtualbox-vm-for-raspberrypi-development/

Once you have logged in open a terminal and type the following in......
 
 
mkdir kcompile
cd kcompile
wget https://www.rtai.org/RTAI/rtai-3.8.tar.bz2
 
 
then there are lots of other commands that anti spam will not allow :( 
 
 
 
 
 
 
 
Posts: 195
Joined: Fri Nov 18, 2011 10:49 am
by jamesh » Thu Jan 19, 2012 6:27 pm
I've been finding C&P a bit odd, but doesn't limit the amount - just does the paste them jumps to the bottom of the webpage!
Soon to be unemployed software engineer currently specialising in camera drivers and frameworks, but can put mind to most embedded tasks. Got a job in N.Cambridge or surroundings? I'm interested!
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 11559
Joined: Sat Jul 30, 2011 7:41 pm
by mung » Thu Jan 19, 2012 10:19 pm

for some reason I cannot post to this thread????

I am really looking like an idiot now as I cannot seem to include web links or complete a continuous post without quoting my original posting and editing it???????

WTF is wrong with this forum??????

Is it just me?

I am adding small copy and paste snippets, as I think this is due to anti spam tests and will not allow me to paste more than a few characters?????

I have spent this morning trying to work out how to compile the kernel with rtai.

I am no expert and have no real experience with low level programming of ARM or of linux kernel programming, so I am probably not the best person to be doing this.
 
So far it is a fail, but I hope if I document what I have done someone better than I will be successful.

I think the HAL patch needs fixing (actually applying

:D
  )and also the rtai config from "make config" was not quite correct, I hope someone who knows has some help.

The simple step by step guide to how to compile the kernel using the http://russelldavis.org/2011/09/10/virtualbox-vm-for-raspberrypi-development/

Once you have logged in open a terminal and type the following in......
 
mkdir kcompile
cd kcompile
wget https://www.rtai.org/RTAI/rtai-3.8.tar.bz2
wget anticore.org/ratgentoo/files/kernels/xenomai/linux-2.6.35.7.tar.bz2
wget  raspberrypi.org/kernel.zip
tar xjf linux-2.6.35.7.tar.bz2
cd linux-2.6.35.7
unzip ../kernel.zip
gzip -d raspberrypi.patch.gz
patch -p0 < raspberrypi.patch
cd tree/linux/
tar cf ../../patchtree.tar .
cd ../..
tar xf patchtree.tar
make dep
make ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi- zImage
cd .. 
tar xjf rtai-3.8.tar.bz2
ln -sf linux-2.6.35.7 /usr/src/linux
cd rtai-3.8/
sb2 ./configure
# rtai wants cc not gcc should i change makefile CC=???
cp arm-none-linux-gnueabi-gcc arm-none-linux-gnueabi-cc
sb2 make -f makefile ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi-
 
 
then there are lots of other commands that anti spam will not allow 

Posts: 195
Joined: Fri Nov 18, 2011 10:49 am
by IDE » Sat Jan 21, 2012 12:28 am
Very interesting to notice the others who has interest having a real-time kernel on the RP. Lets see when the forums will be fixed for letting people paste stuff in it..
Posts: 52
Joined: Fri Jan 13, 2012 12:28 am
by IDE » Sat Jan 21, 2012 6:24 pm
Mung: Promethus suggested using pastebin.com as a work-around.
Posts: 52
Joined: Fri Jan 13, 2012 12:28 am
by mung » Mon Jan 23, 2012 8:10 pm
IDE said:


Very interesting to notice the others who has interest having a real-time kernel on the RP. Lets see when the forums will be fixed for letting people paste stuff in it..


I am mainly interested in the rtai kernel support so that EMC2 and possibly other robotic and control software can be run on the RP. The RP seems like the perfect cheap robot controller if the gert board can be integrated with some of the control software available for linux. I started looking at compiling realtime kernel and rtai only due to my intrest in EMC2 see this post: http://www.raspberrypi.org/for.....controller

I have unfortunately never yet given this a concerted enough effort to ever complete compiling a real time kernel though I have managed to get realtime for a i486 compiled I never quite got it working right, and I have not even got as far as getting the kernel properly configured for the ARM (this is my first ever attempt at making kernel 'make config' changes for ARM)

So far I have spent maybe 3-4 hours on this, and I think will take a lot lot longer??

I doubt I will be putting much more effort into this  until I order a RP, and I doubt I will be the person that will actually get things working as I think I don't have enough time, talent, or experience.

Would love to help and I hope that others can add more information and links on this thread to help with getting some good realtime control software running on the RP.

I should say that as far as I can see linux should support rtai  on ARM 'out of the box', but that depends on finding the right kernel .config options and compiling the kernel in order to put it 'into the box'

I have so far not found any default config file that purports to compile linux for ARM with rtai may be worth reading this http://uu.diva-portal.org/smas.....FULLTEXT01

Also I am not totally sure the Broadcom ARM chip used in the RP has all the right instructions and supervisor logic to get RT working(I have no real idea about anything, but I have heard custom chips sometimes drop parts of the architecture to save power or cut production costs????)

Would be good if some RP or Broadcom tech experts could comment?
Posts: 195
Joined: Fri Nov 18, 2011 10:49 am
by IDE » Tue Feb 07, 2012 7:15 pm
In this thread http://www.raspberrypi.org/for.....ing#p39130

They mention this link http://elinux.org/RPi_Kernel_Compilation

They talk about the repository for the kernel v3.. Although I'm interested into 2.6 for realtime.
Posts: 52
Joined: Fri Jan 13, 2012 12:28 am
by jazzer » Sun Apr 15, 2012 2:50 pm
Oh my god, having RTAI on RPI would be sooooooooo nice for motor control.
Please tell me you guys haven't forgotten about this thread?

Would love to help get it done, but I dont have any experience with kernel compilation either. RTAI works on ARM 7, do we have any idea whether it is feasible on this board?
Posts: 1
Joined: Sun Apr 15, 2012 1:37 pm
by IDE » Sun Apr 15, 2012 8:18 pm
I'm still keeping a close eye to this thread. I'm supposed to receive my first order next month.
Posts: 52
Joined: Fri Jan 13, 2012 12:28 am
by Jongen » Sat Jun 02, 2012 3:57 am
Yes, real-time capabilities would be extremely nice to have, especially if they were made fairly straightforward to apply.. I remember some of my colleagues trying to get the real-time kernel on a Gumstix a couple of years ago, and spending many nights fighting it.

I'm not the biggest Linux guru - hardware is my strong point, so I'm probably not going to dive into this on my own, but I'd sure be appreciative of anyone who can get it working and provide a write-up of how he did it. Having real-time support really opens RP up as a research platform for things like robotics, avionics, and other serious embedded systems. Best of luck.
Posts: 1
Joined: Sat Jun 02, 2012 3:47 am
by mung » Wed Jun 13, 2012 12:34 pm
I have no idea if this will copy paste here okay, but it is the last script of notes I made in looking at compiling realtime support in a kernel.


Code: Select all
#!/bin/bash

#### absolutly pointless script of notes about trying to compile real time kernel for raspberrypi

# suggest important reading
# http://lwn.net/images/conf/rtlws11/papers/proc/p11.pdf
#http://www.raspberrypi.org/wp-content/uploads/2012/02/BCM2835-ARM-Peripherals.pdf
#http://osdir.com/ml/linux.real-time.xenomai.devel/2006-04/msg00163.html

# overview of my current opinion (I have no real time knowledge):
# I think RTAI and emc on raspberry pi is almost certainly possible.

# RTAI current branch known as magma, and xenomai (fork of RTAI) do not as far as I can see support ARM11 architecture.

# this means there is probably no simple (download a patch and kernel .config) way to get a realtime kernel compatible with emc running????

# As far as I can see ARM11 is backwards compatible with ARM9 instructions but all the cache addressing architecture is different this means there would probably need quite a few patches to get things working, of course it may be worth just trying to apply the ARM9 patches and see what happens????


# I did find some notes that suggested someone has tried RTAI for ARM11 in 2005 but not seen any details of success (http://mail.rtai.org/pipermail/rtai/2005-January/010051.html)

#Anyone considering going further should probably ask questions on the RTAI maillist and read this https://www.rtai.org/RTAILAB/RTAI-TARGET-HOWTO.txt

# I may look at this further, but I feel its beyond me as I don't have time to learn all the new information required and don't really have any RTAI experience.

# I think this is a project for someone with a couple of hundred hours spare and some knowledge of RTAI and ARM architecture, really should be done by broadcom as I am sure RTAI support for their chip would add great possibilitys for sales in the systems control market?

# Code below may give you a skeleton codebase to start browsing and hacking but may be useless??


#mkdir kcompile
#cd kcompile
rtai=0
xenomai=0
diskimage=0


if [ ! -e kernel.zip ]; then
wget http://www.raspberrypi.org/kernel.zip
fi
if [ ! -e linux-2.6.35.7.tar.bz2 ]; then
wget http://www.anticore.org/ratgentoo/files/kernels/xenomai/linux-2.6.35.7.tar.bz2
tar xjf linux-2.6.35.7.tar.bz2
cd linux-2.6.35.7
unzip ../kernel.zip
gzip -d raspberrypi.patch.gz
patch -p0 < raspberrypi.patch
cd tree/linux/
tar cf ../../patchtree.tar .
cd ../..
tar xf patchtree.tar

else
cd linux-2.6.35.7
make dep
make ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi- zImage
cd ..
ln -sf linux-2.6.35.7 /usr/src/linux
fi

if [ $rtai == 1 ]; then
######################### RTAI does not support ARM11???????  https://www.rtai.org/
wget https://www.rtai.org/RTAI/rtai-3.8.tar.bz2
######## patch the kernel with the RTAI patches
tar xjf rtai-3.8.tar.bz2
cd rtai-3.8/
sb2 ./configure
######## rtai wants cc not gcc should i change makefile CC???
cp arm-none-linux-gnueabi-gcc arm-none-linux-gnueabi-cc
sb2 make -f makefile ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi-
#cd /usr/src/linux
echo "patch -p1 < /usr/src/rtai/base/arch/i386/patches/hal-linux-x.x.xx_rx.patch"

###### don't think ARM11 is supported yet maybe try it with ARM9 patches???
fi

if [ $xenomai == 1 ]; then
######################### we should try xenomai instead? http://www.xenomai.org
wget http://download.gna.org/xenomai/stable/xenomai-2.6.0.tar.bz2
tar xjf xenomai-2.6.0.tar.bz2
####### get the patch used for miniemc??? (this is for ARM9 only???)
wget http://miniemc2.googlecode.com/files/linux-2.6.35.9-s3c24xx-i-pipe-adeos-2.5.6-fiq-isr-aufs2.mod2.patch
####### get miniemc just for reference...
wget http://miniemc2.googlecode.com/files/miniemc2_v08rc1.tar.gz
cd xenomai-2.6.0

######### what to do next????
fi

####################  the following just writes a disk image for testing
if [ $diskimage == 1 ]; then
dd if=/dev/zero of=rootfs.img bs=320k count=1
mkfs.ext2 ­i 1024 ­F rootfs.ext2
mkdir /mnt/rootfs
mount ­o loop rootfs.img /mnt/rootfs
sync
qemu -m32 -hda rootfs.img -kernel linux­2.6.12/arch/arm/boot/bzImage -append "root=/dev/hda "
fi
Posts: 195
Joined: Fri Nov 18, 2011 10:49 am
by mung » Wed Jun 13, 2012 2:39 pm
Well maybe my research was wrong just found the following posts on http://www.denx.de
Xenomai Real-Time Support for MPC5121 (ADS5121) and i.MX31 (Qong)

Tue Feb 17 2009
DENX Software Engineering proudly presents Xenomai based RTOS emulation and real-time support for the popular Freescale MPC5121 Power Architecture® and i.MX31 ARM11 processors. All needed code has been integrated into the official Xenomai distribution and is available from the Xenomai Download Area. Benchmark results for example for the i.MX31 based QONG EVB-Lite board are available here.


QONG EVB-Lite

Tue Dec 09 2008
DENX Computer Systems ships the new QONG EVB-Lite. Based on the i.MX31 CPU the board was developed as an extended version of the QONG processor module. The "heart" of the board consists by the QONG module itself; surrounded by a PCB extension that provides native connectors for most common I/O interfaces.
More information on the QONG EVB-Lite is available in our product page


Embedded Linux Development Kit 4.2 for ARM11

Tue Nov 25 2008
DENX today announced a new release of its Embedded Linux Development Kit (ELDK Release 4.2) for ARM processors. This new versions targets especially for ARM11 and other systems with hardware floating point support, like the Freescale i.MX31 or Samsung S3C6400 processors. Another important new feature is support for the Embedded Application Binary Interface (EABI) standard.

The DENX Embedded Linux Development Kit provides a complete and powerful software development environment for Embedded and Real-Time Systems:

Cross development tools (compiler, assembler, linker etc .) to develop software for the target system
Native tools (shell, commands and libraries) that will run on the target system
Firmware that can easily be ported to new boards and processors
Linux kernel including all device drivers, board-support functions etc .
Supports Xenomai ­ kernel extensions for systems with hard real-time requirements
EABI support
Software and Hardware Floating Point versions
SELF (Simple Embedded Linux Framework) as a base to build run-time environments for your embedded systems
All components of the ELDK are available as Free Software with complete source code under GPL and other Open Source licenses . The ELDK can be downloaded from the DENX FTP server and from several mirror sites. A mailing list for ELDK related discussion is available here.


This suggests that xenomai supports the i.MX31 which is an ARM11 based processor, so maybe the best route to compiling real time kernel support for the rasp pi is to start from the xenomai i.MX31 patches. Once that is working look at the RTAI skin for xenomai then compile emc.

Now we just need someone stupid enough to spend many hours of free time doing all this hard work :D
Posts: 195
Joined: Fri Nov 18, 2011 10:49 am
by mung » Wed Jun 13, 2012 3:31 pm
Some benchmarks for the i.MX31 look quite promising for running emc on the raspberry pi.

http://www.denx.de/wiki/DULG/AN2008_03_ ... pioIrqQong

I may try compiling xenomai and kernel over the weekend, though I don't have a pi to test yet.


Also thought I would post a fewmore links that maybe useful......

http://sourceforge.net/projects/rpicnc/
http://www.digipedia.pl/usenet/thread/18400/12163/
Posts: 195
Joined: Fri Nov 18, 2011 10:49 am
by mung » Mon Jun 25, 2012 6:55 pm
Well I finally got a pi on friday and that spurred me on to work over the weekend at what I was hoping to do with it.

I have realised there will possibly be many problems which I may now babble incoherently about......

I have found lots of problems with scratchbox cross compiling and debian package dependencies (maybe due to my lack of knowledge), so thought I would build everything on the pi.

The pi is slow, painfully slow and lacks memory, it could not download the pi kernel git repo I think due to insufficient memory, it also could not compile emc2 due to lack of memory (crashed gcc though gcc did not say why?).

I have not tried to grab the RP kernel git tree again but did manage to compile emc2 after adding some swap.

xenomai seems to currently only support 2.6 kernels (of course the pi uses 3.2 now though I imagine xenomai should still patch to it I have not tried)????

I have decided to attack the problem by doing the simple things first.

So I have compiled a 2.6 kernel on the pi but not patched it with xenomai yet (lots of RTFM).

I have compiled emc2 from the linuxcnc git repository.

I have totally bastardised the /usr/include/ files to get things to compile without error.

I have made some initial familiarisation with the xenomai codebase but I still have no idea where to start('I am guessing maybe 5 to 10 hours just to get a first patch and compilation)


emc2 seemed to compile successfully in simulation configuration but I think there maybe problems as trying to run axis is giving errors about paths and initialisation files???

I have not got round to testing either the 2.6 kernel or emc2 simulator.

All compilation was done on the latest wheezy beta release that was shown on the raspberrypi.org frontpage last week.

I may have a look at fixing the paths on emc2 and testing this during the week, but doubt I will test the 2.6 kernel until next weekend as I want to try it on a fresh SD card and test build and don't have a spare card at present.

I am already quite worried about the possible work required to get real time running correctly, I feel like progress may look good at present but I think this could take months.

If anyone is interested in getting real time fixed and has more expertise please feel free to help or give advice.

An easy guide to scratchbox or xenomai porting would be useful.
Posts: 195
Joined: Fri Nov 18, 2011 10:49 am
by AndrewS » Tue Jun 26, 2012 8:21 am
I dunno if it's the same RT-patchset that you're looking at, but see this thread viewtopic.php?f=29&t=9311

I suspect chasing a 2.6 kernel my be a dead-end? Without a lot of back-porting of the changes made in https://github.com/raspberrypi/linux I dunno if a 2.6 kernel will even boot on the Pi? :?
User avatar
Posts: 3022
Joined: Sun Apr 22, 2012 4:50 pm
Location: Cambridge, UK
by mung » Tue Jun 26, 2012 11:30 am
Okay so I checked all the errors and path problems and found after a little searching that all I needed was a simple 'sudo apt-get install python-gtk2' and then the problems with font paths disappeared.

Seems linuxcnc compiles in simulator mode almost without fault on the raspberrypi (I have not done any bug testing)

I think it maybe only took 10 hours real work though the pi compile time was probably 4 hours from a 'make clean' and it took about 4 attempts to get it to compile.

I have totally lost track of what I did, but I think the /usr/include/linux and /usr/include/asm directorys were symlinked in from /usr/src/linux-2.6.35 and the was a wrapper arm_bitops.h I created in emc2-dev/src/rtapi/ and I had to remove a function declaration for ffs in string.h???
Attachments
picnc1.jpg
picnc1.jpg (62.04 KiB) Viewed 24155 times
Posts: 195
Joined: Fri Nov 18, 2011 10:49 am
by mung » Tue Jun 26, 2012 11:54 am
AndrewS wrote:I dunno if it's the same RT-patchset that you're looking at, but see this thread viewtopic.php?f=29&t=9311

I suspect chasing a 2.6 kernel my be a dead-end? Without a lot of back-porting of the changes made in https://github.com/raspberrypi/linux I dunno if a 2.6 kernel will even boot on the Pi? :?



This news has made me a little dispondent, I hope maybe the 3.2 kernel is patchable with xenomai but I think maybe the real time hacking will be beyond me.

I may continue looking at getting the RPI kernel from git and make some very simple attempts at patching, but kernel hacking is not something I have much experience of.

My main interest is in getting linuxcnc running on the RPI (possibly I am taking this thread off topic?), but I am starting to think RPI does not have sufficient speed for it to run without glitches anyways???

Maybe with some overclocking it will be possible??

As far as I know RT-Preempt is not the same as xenomai as RT-Prempt is part of the linux kernel, whereas xenomai runs as a supervisor OS and runs linux as a sub process???

I really don't have enough knowledge to say anything yet though as I have not got further than reading some very basic info and having a quick browse of the xenomai source tree.

I am starting to get the feeling that I will be leaving all the harder work to someone else with experience, as I think realtime kernel hacking needs more expertise and understanding of the ARM architecture than I will ever have.

I will probably have a quick attempt at it before I give up though.
Posts: 195
Joined: Fri Nov 18, 2011 10:49 am
by mung » Tue Jun 26, 2012 4:17 pm
AndrewS wrote:I suspect chasing a 2.6 kernel my be a dead-end? Without a lot of back-porting of the changes made in https://github.com/raspberrypi/linux I dunno if a 2.6 kernel will even boot on the Pi? :?


I wonder what makes you think 2.6 kernels will not run on the RPI???

I did not really put much thought into your reply before and just assumed that you were an expert that knew about such things.

I have not done any work on kernels for RPI yet and have only run a default wheezy beta image on the RPI, I am not an expert and really only hack code with a very low level of knowledge, but I would appreciate if you make a comment about what is/is not possible then you qualify it with your experience or some definite real world example of validity!!

I just had a look on google and found this link that shows 2.6 kernels do work http://www.raspberrypi.org/phpBB3/viewtopic.php?f=66&t=8160

I understand your comment about backporting possibly being a dead end, but patching xenomai on its supported kernel (2.6) will likely be far simpler than trying to port xenomai to a new kernel that xenomai does support!

Especially as RPI is known to work with a 2.6 kernel.

I am sure I am probably wrong about many things and I try to make people aware of the fact I am not sure of all I say, but it causes extra work for others if forums contain information that is incorrect or improperly qualified, so please try to qualify your statements better so it does not confuse the subject!
Posts: 195
Joined: Fri Nov 18, 2011 10:49 am
by mung » Wed Jun 27, 2012 12:22 pm
I am getting ever less sure about weather I have any idea about what is possible or if I am just creating a large pile of crap??

I have a fuzzy memory at the best of times and now wonder where I got details of compiling 2.6 kernels for RPI and thinking maybe I misunderstood and downloaded 2.6 and patches for some other architecture.

I tried a compile last night on the scratchbox VM with patches from xenomai, I think maybe my mind is not working correctly as this caused much confusion.

basically steps were similar to this:
Code: Select all
wget http://www.anticore.org/ratgentoo/files/kernels/xenomai/linux-2.6.35.7.tar.bz2
tar xjf linux-2.6.35.7.tar.bz2
tar xjf xenomai-2.6.0.tar.bz2
cd linux-2.6.35.7
sb2 ../xenomai-2.6.0/scripts/prepare-kernel.sh
patch -p0 < ../raspberrypi.patch
sb2 make ARCH=arm CROSS_COMPILE=/usr/bin/arm-none-linux-gnueabi- oldconfig
sb2 make ARCH=arm CROSS_COMPILE=/usr/bin/arm-none-linux-gnueabi- bzImage



LD kernel/time/built-in.o
CC kernel/xenomai/arch/generic/hal.o
In file included from kernel/xenomai/arch/generic/hal.c:45:0:
/home/raspberry/raspberry_pi_development/kern2.6/linux-2.6.35.7/arch/arm/include/asm/xenomai/hal.h:91:2: error: #error "Unsupported ARM machine"
make[4]: *** [kernel/xenomai/arch/generic/hal.o] Error 1
make[3]: *** [kernel/xenomai/arch/generic] Error 2
make[2]: *** [kernel/xenomai/arch] Error 2
make[1]: *** [kernel/xenomai] Error 2
make: *** [kernel] Error 2


So I have no idea what I am doing but think maybe I need to use the adeos ipipe patch and config the machine properly (will try with the imx3 first???)

xenomai-2.6.0/ksrc/arch/arm/patches

But then upon checking things again I seem to have made some major mistake as I now realise I was using the wrong scratchbox virtual machine (I have two as there was a second released from http://russelldavis.org/2012/01/20/new- ... t-vm-v0-2/). I should have deleted the old one and transfered any files across but have not and things are very messed and disordered.

I definitly remember seeming an imx3 patch in some directory, but think now think this was from the denx.de source tree as I cannot see anything in the xenomai-2.6 code that I downloaded????

I think I need to clear things out and start again with the source code from the denx.de git repo????


Some more info I have found that may be of use???? :

http://www.mail-archive.com/xenomai-hel ... 12333.html
http://www.xenomai.org/index.php/I-pipe:ArmPorting
http://comments.gmane.org/gmane.linux.r ... sers/11667


I feel like maybe I am just making the waters more muddy, but thought maybe better to post so others can see how incoherent things seem :lol:

I am just hacking things to see what happens and have never used xenomai before, so please make allowances.
Posts: 195
Joined: Fri Nov 18, 2011 10:49 am
by mung » Wed Jun 27, 2012 12:43 pm
Posts: 195
Joined: Fri Nov 18, 2011 10:49 am
by AndrewS » Wed Jun 27, 2012 11:29 pm
mung wrote:
AndrewS wrote:I suspect chasing a 2.6 kernel my be a dead-end? Without a lot of back-porting of the changes made in https://github.com/raspberrypi/linux I dunno if a 2.6 kernel will even boot on the Pi? :?

I wonder what makes you think 2.6 kernels will not run on the RPI???

I did not really put much thought into your reply before and just assumed that you were an expert that knew about such things.

I just had a look on google and found this link that shows 2.6 kernels do work http://www.raspberrypi.org/phpBB3/viewtopic.php?f=66&t=8160

Sorry for causing any confusion :( :oops:
I did attempt to qualify my statements with "I suspect" and "I dunno"...

The reason I assumed that a 2.6 kernel wouldn't boot is that AFAIK a "vanilla kernel" needs a bunch of RPI-specific patches applied to it before it'll boot on the Raspi, and https://github.com/raspberrypi/linux (where the Foundation have been making these changes) is based on a 3.1.9 kernel.
I didn't realise that the effort of back-porting the changes to kernel 2.6.x had A) already been done by plugwash and B) that it would be so relatively straightforward.

Good luck with your RT-linux-on-RPi experiments. I'll go crawl back under my rock ;)
User avatar
Posts: 3022
Joined: Sun Apr 22, 2012 4:50 pm
Location: Cambridge, UK