Ali Sohanghpurwala <[EMAIL PROTECTED]> writes:

> Patching the 2.6.26-davinci1 kernel with patch-2.6.26-rt1 went smoothly. 
> Unfortunately when I try to compile I get errors:
> 
> kernel/built-in.o(.text+0xdfd4): In function `__tasklet_hi_schedule':
> include/asm-generic/cmpxchg-local.h:42: undefined reference to 
> `wrong_size_cmpxchg'
> kernel/built-in.o(.text+0xe12c): In function `__tasklet_schedule':
> include/asm-generic/cmpxchg-local.h:42: undefined reference to 
> `wrong_size_cmpxchg'
> kernel/built-in.o(.text+0xe404): In function `__tasklet_action':
> include/asm-generic/cmpxchg-local.h:42: undefined reference to 
> `wrong_size_cmpxchg'
> make: *** [.tmp_vmlinux1] Error 1
> 
> On top of the rt-preempt patch, I incorporated changes from this post (the 
> sound driver changes, not the irq/manage.c changes):
> http://tinyurl.com/5awu5s
> 
> Ali
> 
> 

I was able to 'fix' the problem myself.  I simply created a dummy function
wrong_size_cmpxchg which returns 0.  Admittedly this is a dirty hack since I
have no idea what will happen if a wrong size compare/exchange does occur.

If anyone here knows what wrong_size_cmpxchg is supposed to do, or where it is
supposed to be(perhaps in an assembly file?) I would love to know.

Once booted I was getting Kernel BUG warnings every second.  I found the fix in
this patch:
http://lists.blagblagblag.org/message/20080807.213509.3ac33bb0.en.html

So for anyone wanting to run kernel 2.6.26 on a davinci platform here are the
steps to follow:

1.  patch the point release v2.6.26-davinci1 with patch-2.6.26-rt1.bz2:
http://www.kernel.org/pub/linux/kernel/projects/rt/older/patch-2.6.26-rt1.bz2

2.  Add the dummy wrong_size_cmpxchg function to 
    include/asm-generic/cmpxchg-local.h

3.  Incorporate changes from patch detailed here:

http://lists.blagblagblag.org/message/20080807.213509.3ac33bb0.en.html

I had incorporated these into a patch, but the some lines are longer than 80
characters and I don't know how to attach it.  If anyone can tell me how to do
this, I will attach the patch.

Let me know if this works for you, I've tested it on the evm and our custom
board.  I haven't tried any of the rt-preempt functionality yet, but all our
regular drivers and programs work.

Thanks,
Ali


_______________________________________________
Davinci-linux-open-source mailing list
[email protected]
http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source

Reply via email to