Thinkpad smapi and Realtime Linux

The tp_smapi driver provides for Battery charge/discharge control and improved stability for the HDAPS driver. However the latest version (as of writing 0.40) does not work with a real-time patched Linux-kernel.

The problem is that rt-linux uses a new mechanism for mutex-locking, which allows preemption and is incompatible with current Linux-mainline. In order to get the tp_smapi driver compile with rt-linux you need to replace the MUTEX locks. I came up with a simple patch that applies to tp_smapi 0.40 to just do that.

Tested with linux 2.6.31.6-rt19. More information on tp_smapi can be found at http://www.thinkwiki.org/wiki/Tp_smapi

Enjoy.

Discussion

Sebastian, 24.01.2010 16:29

Thank you so much! I was not able to solve this, but with you patch it runs like a charm :D

kkk, 10.03.2010 20:40

awesome \o/

Tasmine, 03.11.2011 22:56

Your answer was just what I nedeed. It's made my day!

Enter your comment (wiki syntax is allowed):
 
blog/thinkpad_smapi_and_realtime_linux.txt · Last modified: 12.11.2009 21:26 by rgareus
   |