|
I tried to use sys_open() function in the thread.
But it happend error to the system.
How can I solve this problem?
In the init_module() function, I used sys_* functions.
In the thread, can't I use sys_* function?
===========================================
void *start_routine(void *arg)
{
......
mm_segment_f fs;
fs=get_fs();
set_fs(get_ds());
sys_open("/dev/pbboard0", O_RDONLY, 0);
......
set_fs(fs);
return 0;
}
int init_module(void)
{
pthread_create(&thread, NULL, start_routine,
0);
return 0;
}
...... |