--- kernel/nv-linux.h~	2011-07-27 16:55:54.000000000 -0700
+++ kernel/nv-linux.h	2012-02-18 16:24:12.000000000 -0800
@@ -274,6 +274,18 @@
 #define NV_SPIN_UNLOCK(lock)      atomic_spin_unlock(lock)
 #define NV_SPIN_UNLOCK_WAIT(lock) atomic_spin_unlock_wait(lock)
 #else
+#if defined(CONFIG_PREEMPT_RT_FULL)
+typedef raw_spinlock_t         nv_spinlock_t;
+#define NV_SPIN_LOCK_INIT(lock)   raw_spin_lock_init(lock)
+#define NV_SPIN_LOCK_IRQ(lock)    raw_spin_lock_irq(lock)
+#define NV_SPIN_UNLOCK_IRQ(lock)  raw_spin_unlock_irq(lock)
+#define NV_SPIN_LOCK_IRQSAVE(lock,flags) raw_spin_lock_irqsave(lock,flags)
+#define NV_SPIN_UNLOCK_IRQRESTORE(lock,flags) \
+  raw_spin_unlock_irqrestore(lock,flags)
+#define NV_SPIN_LOCK(lock)        raw_spin_lock(lock)
+#define NV_SPIN_UNLOCK(lock)      raw_spin_unlock(lock)
+#define NV_SPIN_UNLOCK_WAIT(lock) raw_spin_unlock_wait(lock)
+#else
 typedef spinlock_t                nv_spinlock_t;
 #define NV_SPIN_LOCK_INIT(lock)   spin_lock_init(lock)
 #define NV_SPIN_LOCK_IRQ(lock)    spin_lock_irq(lock)
@@ -284,6 +296,7 @@
 #define NV_SPIN_UNLOCK(lock)      spin_unlock(lock)
 #define NV_SPIN_UNLOCK_WAIT(lock) spin_unlock_wait(lock)
 #endif
+#endif
 
 int nv_acpi_init   (void);
 int nv_acpi_uninit (void);
@@ -857,6 +870,9 @@
 #if defined(CONFIG_PREEMPT_RT)
 #define NV_INIT_MUTEX(mutex) semaphore_init(mutex)
 #else
+#if defined(CONFIG_PREEMPT_RT_FULL)
+#define NV_INIT_MUTEX(mutex) sema_init(mutex,1)
+#else
 #if !defined(__SEMAPHORE_INITIALIZER) && defined(__COMPAT_SEMAPHORE_INITIALIZER)
 #define __SEMAPHORE_INITIALIZER __COMPAT_SEMAPHORE_INITIALIZER
 #endif
@@ -867,6 +883,7 @@
         *(mutex) = __mutex;                        \
     }
 #endif
+#endif
 
 #if defined (KERNEL_2_4)
 #  define NV_IS_SUSER()                 suser()