Author: hselasky
Date: Wed Jan 31 13:40:36 2018
New Revision: 328623
URL: https://svnweb.freebsd.org/changeset/base/328623

Log:
  Properly implement the cond_resched() function macro in the LinuxKPI.
  
  MFC after:    1 week
  Sponsored by: Mellanox Technologies

Modified:
  head/sys/compat/linuxkpi/common/include/linux/sched.h

Modified: head/sys/compat/linuxkpi/common/include/linux/sched.h
==============================================================================
--- head/sys/compat/linuxkpi/common/include/linux/sched.h       Wed Jan 31 
11:14:26 2018        (r328622)
+++ head/sys/compat/linuxkpi/common/include/linux/sched.h       Wed Jan 31 
13:40:36 2018        (r328623)
@@ -110,7 +110,7 @@ put_task_struct(struct task_struct *task)
                linux_free_current(task);
 }
 
-#define        cond_resched()  if (!cold)      sched_relinquish(curthread)
+#define        cond_resched()  do { if (!cold) sched_relinquish(curthread); } 
while (0)
 
 #define        yield()         kern_yield(PRI_UNCHANGED)
 #define        sched_yield()   sched_relinquish(curthread)
_______________________________________________
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to