发布时间:2012-03-30 20:21:49
本文回答了为什么需要内核模块动态加载LKM,通过一个简单实例描述了插入、卸载模块过程,接着以实例讲述模块间调用问题及应用程序怎样调用模块内函数,最后给出一些关于模块学习资料。......【阅读全文】
发布时间:2011-06-20 09:59:27
本文先回答了为什么需要系统调用,为什么增加系统调用,以及如何编写系统调用。紧接着给出一个简单实例,最后详尽分析系统调用整个过程。......【阅读全文】
发布时间:2011-06-08 17:33:04
有时需要编译低版本内核,但往往高版本Linux发行版无法编译低版本内核,所以采用相应发行版来编译相应版本内核。本文在Ubuntu 6.06LTS(2.6.15)编译2.6.16(为了修改O(1)调度)。并记录了全过程。......【阅读全文】
Jelline2014-09-14 09:24
vosamo007:Jelline大神,有个问题请教你啊。我在cc2538上移植contiki,下面这段程序报错
unsigned long __attribute__((naked)) //Error[Pe079]: expected a type specifier,Error[Pe141]: unnamed prototyped parameters not allowed when body is present
cpu_cpsid(void) //Error[Pe130]: expected a "{"
{
unsigned long ret;
/* Read PRIMASK and disable interrupts */
__asm(" mrs r0, PRIMASK\n"
" cpsid i\n"
" bx lr\n"
: "=r" (ret));
/* The inline asm returns, we never reach here.
* We add a return statement to keep the compiler happy */
return ret;
}
该怎么解决呢?
vosmo007,你好。我很长一时间没弄Contiki,手头也没有源码,你的问题,对现在的我很陌生,很抱歉。
回复 | 举报vosamo0072014-03-27 22:29
Jelline大神,有个问题请教你啊。我在cc2538上移植contiki,下面这段程序报错
unsigned long __attribute__((naked)) //Error[Pe079]: expected a type specifier,Error[Pe141]: unnamed prototyped parameters not allowed when body is present
cpu_cpsid(void) //Error[Pe130]: expected a "{"
{
unsigned long ret;
/* Read PRIMASK and disable interrupts */
__asm(" mrs r0, PRIMASK\n"
" cpsid i\n"
" bx lr\n"
: "=r" (ret));
/* The inline asm returns, we never reach here.
* We add a return statement to keep the compiler happy */
return ret;
}
该怎么解决呢?