Vxworks增加system call
生活随笔
收集整理的這篇文章主要介紹了
Vxworks增加system call
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
Vxworks中增加system call的偽代碼. 比如用戶層可以獲取kernel中的time tick. #include <syscall.h> #include<syscallLib.h> unsignedshortgettimdsp(void); SYSCALL_RTN_TBL_ENTRYmsGetTbl[] = { {(FUNCPTR) gettimdsp, 1,"gettimdsp", 0} }; unsignedshortgettimdsp(void) { return timetck; } voidusrAppInit (void) { syscallGroupRegister(2,"msgetforrtp", 2, (SYSCALL_RTN_TBL_ENTRY*)&msGetTbl, 0); }
總結
以上是生活随笔為你收集整理的Vxworks增加system call的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 梦到自己去看病是什么兆头
- 下一篇: 梦到蛇被车压死什么预兆