mtd/include/linux/mtd compatmac.h,1.38,1.39

David Woodhouse dwmw2 at infradead.org
Wed Aug 7 07:10:36 EDT 2002


Update of /home/cvs/mtd/include/linux/mtd
In directory phoenix.infradead.org:/tmp/cvs-serv29849

Modified Files:
	compatmac.h 
Log Message:
Fix yield()


Index: compatmac.h
===================================================================
RCS file: /home/cvs/mtd/include/linux/mtd/compatmac.h,v
retrieving revision 1.38
retrieving revision 1.39
diff -u -r1.38 -r1.39
--- compatmac.h	23 Jul 2002 17:14:32 -0000	1.38
+++ compatmac.h	7 Aug 2002 11:10:34 -0000	1.39
@@ -502,7 +502,9 @@
 #endif
 
 #if LINUX_VERSION_CODE < KERNEL_VERSION(2,4,19)
-#define yield() do { current->policy |= SCHED_YIELD; schedule(); } while(0)
+#ifndef yield
+#define yield() do { set_current_state(TASK_RUNNING); schedule(); } while(0)
+#endif
 #define major(d) (MAJOR(to_kdev_t(d)))
 #define minor(d) (MINOR(to_kdev_t(d)))
 #define mk_kdev(ma,mi) MKDEV(ma,mi)





More information about the linux-mtd-cvs mailing list