Date: Mon, 19 Oct 2015 10:57:56 +0000 (UTC) From: Hans Petter Selasky <hselasky@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r289566 - head/sys/ofed/include/linux Message-ID: <201510191057.t9JAvunk052105@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: hselasky Date: Mon Oct 19 10:57:56 2015 New Revision: 289566 URL: https://svnweb.freebsd.org/changeset/base/289566 Log: Merge LinuxKPI changes from DragonflyBSD: - Implement schedule_timeout(). Sponsored by: Mellanox Technologies Modified: head/sys/ofed/include/linux/sched.h Modified: head/sys/ofed/include/linux/sched.h ============================================================================== --- head/sys/ofed/include/linux/sched.h Mon Oct 19 10:56:32 2015 (r289565) +++ head/sys/ofed/include/linux/sched.h Mon Oct 19 10:57:56 2015 (r289566) @@ -107,4 +107,15 @@ do { \ #define sched_yield() sched_relinquish(curthread) +static inline long +schedule_timeout(signed long timeout) +{ + if (timeout < 0) + return 0; + + pause("lstim", timeout); + + return 0; +} + #endif /* _LINUX_SCHED_H_ */
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201510191057.t9JAvunk052105>