Modifications for Linux v3.18.
authorAnselm Busse <anselm.busse@tu-berlin.de>
Mon, 18 Jan 2016 19:49:03 +0000 (20:49 +0100)
committerAnselm Busse <anselm.busse@tu-berlin.de>
Wed, 20 Jan 2016 10:21:08 +0000 (11:21 +0100)
framework/include/os/linux.h
framework/os/linux/linux_sched.c

index c1f1c7a..80c4e81 100644 (file)
@@ -34,6 +34,7 @@
 #include <linux/list.h>
 #include <linux/delayacct.h>
 
+#include <linux/cpuidle.h>
 #include <linux/cpumask.h>
 
 
@@ -497,5 +498,31 @@ extern void sched_ttwu_pending(void);
 static inline void sched_ttwu_pending(void) { }
 #endif /* CONFIG_SMP */
 
+#ifdef CONFIG_CPU_IDLE
+static inline void idle_set_state(struct rq *rq,
+                                  struct cpuidle_state *idle_state)
+{
+       //rq->idle_state = idle_state;
+       BUG();
+}
+
+static inline struct cpuidle_state *idle_get_state(struct rq *rq)
+{
+       //WARN_ON(!rcu_read_lock_held());
+       //return rq->idle_state;
+       BUG();
+}
+#else
+static inline void idle_set_state(struct rq *rq,
+                                                                 struct cpuidle_state *idle_state)
+{
+}
+
+static inline struct cpuidle_state *idle_get_state(struct rq *rq)
+{
+       return NULL;
+}
+#endif
+
 
 #endif /* LINUX_H_ */
index 4105600..356a88c 100644 (file)
@@ -2288,6 +2288,12 @@ void __init sched_init_smp(void)
        smp_started = 1;
 }
 
+void wake_up_if_idle(int cpu)
+{
+       BUG();
+}
+
+
 bool cpus_share_cache(int this_cpu, int that_cpu)
 {
        return per_cpu(sd_llc_id, this_cpu) == per_cpu(sd_llc_id, that_cpu);