⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 pthread_wakeup_np.3

📁 rtlinux-3.1源代码
💻 3
字号:
.\" This -*- nroff -*- file has been generated from.\" DocBook SGML with docbook-to-man on Debian GNU/Linux....\"...\"	transcript compatibility for postscript use....\"...\"	synopsis:  .P! <file.ps>...\".de P!\\&..fl			\" force out current output buffer\\!%PB\\!/showpage{}def...\" the following is from Ken Flowers -- it prevents dictionary overflows\\!/tempdict 200 dict def tempdict begin.fl			\" prolog.sy cat \\$1\" bring in postscript file...\" the following line matches the tempdict above\\!end % tempdict %\\!PE\\!..sp \\$2u	\" move below the image...de pF.ie     \\*(f1 .ds f1 \\n(.f.el .ie \\*(f2 .ds f2 \\n(.f.el .ie \\*(f3 .ds f3 \\n(.f.el .ie \\*(f4 .ds f4 \\n(.f.el .tm ? font overflow.ft \\$1...de fP.ie     !\\*(f4 \{\.	ft \\*(f4.	ds f4\"'	br \}.el .ie !\\*(f3 \{\.	ft \\*(f3.	ds f3\"'	br \}.el .ie !\\*(f2 \{\.	ft \\*(f2.	ds f2\"'	br \}.el .ie !\\*(f1 \{\.	ft \\*(f1.	ds f1\"'	br \}.el .tm ? font underflow...ds f1\".ds f2\".ds f3\".ds f4\"'\" t .ta 8n 16n 24n 32n 40n 48n 56n 64n 72n  .TH "pthread_wakeup_np" "3" .SH "NAME" pthread_wakeup_np \(em wake up a realtime thread. .SH "SYNOPSIS" .PP .nf .ta 8n 16n 24n 32n 40n 48n 56n 64n 72n #include <rtl_sched.h>  int \fBpthread_wakeup_np\fP(pthread_t \fBthread\fR); .fi .SH "DESCRIPTION" .PP This function is a non-portable Realtime Linux extension.  \fBpthread_wakeup_np\fP wakes up the realtime thread \fBthread\fR. .SH "RETURN VALUE" .PP Always returns 0. .SH "ERRORS" .PP None. .SH "NOTES" .PP This function is safe to call from interrupt handlers and threads, but not from the Linux kernel. Calling the function will cause a thread switch if the awakened thread is higher priority than the current thread and they are both on the same processor. In this case,  \fBpthread_wakeup\fP  called  from an interrupt handler will suspend the current thread at once. The handler will complete when there are no more runnable higher priority  threads. .PP To illustrate, suppose we want to have very simple interrupt handlers (always a good idea), but we need complex processing done after each interrupt.  We can designate a thread to do this processing and give it the highest priority. Then the interrupt handlers may push some data into a queue and call  \fBpthread_wakeup\fP,  to wake up the thread and switch to it at once. (WARNING: Do not leave any critical hardware handshaking until after the return from  \fBpthread_wakeup_np\fP, unless it is okay for the handshaking to be  postponed until the interrupted thread is scheduled again.) .SH "AUTHOR" .PP Michael Barabanov and Victor Yodaiken (\fIsupport@fsmlabs.com (link to URL mailto:support@fsmlabs.com) \fR) .SH "SEE ALSO" \fIpthread_suspend_np(3) (link to URL pthread_suspend_np.3.html) \fR, \fIpthread_make_periodic_np(3) (link to URL pthread_make_periodic_np.3.html) \fR, \fIpthread_wait_np(3) (link to URL pthread_wait_np.3.html) \fR .PP \(co2001 FSMLabs Inc. .PP All rights reserved. ...\" created by instant / docbook-to-man, Thu 26 Jul 2001, 11:19 

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -