added functionality for hackbench usage
authorsechting <sechting@kbs09.kbs.local>
Thu, 4 Feb 2016 16:21:46 +0000 (17:21 +0100)
committersechting <sechting@kbs09.kbs.local>
Thu, 4 Feb 2016 16:21:46 +0000 (17:21 +0100)
added __cond_resched_softirq method in os/linux/linux_sched.c for unix
domain sockets. now hackbench is available!

framework/os/linux/linux_sched.c

index 896c812..84792fe 100644 (file)
@@ -1815,6 +1815,20 @@ int __sched _cond_resched(void)
 }
 EXPORT_SYMBOL(_cond_resched);
 
+int __sched __cond_resched_softirq(void)
+{
+       BUG_ON(!in_softirq());
+
+       if (should_resched(SOFTIRQ_DISABLE_OFFSET)) {
+               local_bh_enable();
+               preempt_schedule_common();
+               local_bh_disable();
+               return 1;
+       }
+       return 0;
+}
+EXPORT_SYMBOL(__cond_resched_softirq);
+
 /*
  * kernel/sched/core.c:4333
  */