patch-2.4.20 linux-2.4.20/include/asm-sparc/semaphore.h
Next file: linux-2.4.20/include/asm-sparc/socket.h
Previous file: linux-2.4.20/include/asm-sparc/pconf.h
Back to the patch index
Back to the overall index
-  Lines: 12
-  Date:
Thu Nov 28 15:53:15 2002
-  Orig file: 
linux-2.4.19/include/asm-sparc/semaphore.h
-  Orig date: 
Tue Oct 30 15:08:11 2001
diff -urN linux-2.4.19/include/asm-sparc/semaphore.h linux-2.4.20/include/asm-sparc/semaphore.h
@@ -213,6 +213,11 @@
 	: "g3", "g4", "g7", "memory", "cc");
 }	
 
+static inline int sem_getcount(struct semaphore *sem)
+{
+	return atomic_read(&sem->count);
+}
+
 #endif /* __KERNEL__ */
 
 #endif /* !(_SPARC_SEMAPHORE_H) */
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)