Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 29 Jul 2010 02:08:49 +0000 (UTC)
From:      Jeff Roberson <jeff@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-projects@freebsd.org
Subject:   svn commit: r210582 - projects/ofed/head/sys/ofed/include/linux
Message-ID:  <201007290208.o6T28ngL098387@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jeff
Date: Thu Jul 29 02:08:48 2010
New Revision: 210582
URL: http://svn.freebsd.org/changeset/base/210582

Log:
   - Add a linux compatible msleep.
  
  Sponsored by:	Isilon Systems, iX Systems, and Panasas.

Modified:
  projects/ofed/head/sys/ofed/include/linux/delay.h

Modified: projects/ofed/head/sys/ofed/include/linux/delay.h
==============================================================================
--- projects/ofed/head/sys/ofed/include/linux/delay.h	Thu Jul 29 02:08:21 2010	(r210581)
+++ projects/ofed/head/sys/ofed/include/linux/delay.h	Thu Jul 29 02:08:48 2010	(r210582)
@@ -25,3 +25,19 @@
  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
+
+#ifndef _LINUX_DELAY_H_
+#define	_LINUX_DELAY_H_
+
+#include <linux/jiffies.h>
+
+static inline void
+linux_msleep(int ms)
+{
+	pause("lnxsleep", msecs_to_jiffies(ms));
+}
+
+#undef msleep
+#define	msleep	linux_msleep
+
+#endif	/* _LINUX_DELAY_H_ */



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201007290208.o6T28ngL098387>