#define can_spin_unlock_irqrestore spin_unlock_irqrestore
#define can_spin_lock_init spin_lock_init
+#ifndef DEFINE_SPINLOCK
+#define CAN_DEFINE_SPINLOCK(x) can_spinlock_t x = SPIN_LOCK_UNLOCKED
+#else /*DEFINE_SPINLOCK*/
+#define CAN_DEFINE_SPINLOCK DEFINE_SPINLOCK
+#endif /*DEFINE_SPINLOCK*/
+
#if defined(CONFIG_PREEMPT) || (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,0))
#define can_preempt_disable preempt_disable
#define can_preempt_enable preempt_enable
#define can_spin_unlock_irqrestore rtl_spin_unlock_irqrestore
#define can_spin_lock_init rtl_spin_lock_init
+#define CAN_DEFINE_SPINLOCK(x) can_spinlock_t x = SPIN_LOCK_UNLOCKED
+
#define can_preempt_disable() do { } while (0)
#define can_preempt_enable() do { } while (0)