Add a TODO.
This commit is contained in:
parent
911429455c
commit
a1366f2b16
1 changed files with 8 additions and 0 deletions
|
@ -170,6 +170,14 @@ void modem_hread(char* cbuf)
|
||||||
}
|
}
|
||||||
pthread_mutex_unlock(&buffermx);
|
pthread_mutex_unlock(&buffermx);
|
||||||
}
|
}
|
||||||
|
/*
|
||||||
|
* XXX: this is inefficient
|
||||||
|
* TODO: move this so we have a global pipe that is select()ed.
|
||||||
|
* Threads lock its mutex, write ONE BYTE to it, and the select() receives it. The calling thread unlocks the pipe mux.
|
||||||
|
* This unlocks the modem mutex, waits, and tries to keep locking (maybe using a conditional)
|
||||||
|
* until it gets it and reselects. DO IT. (thanks jilles)
|
||||||
|
* Do all this after a trylock().
|
||||||
|
*/
|
||||||
void *modem_io(k)
|
void *modem_io(k)
|
||||||
void* k;
|
void* k;
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue