forked from len0rd/rockbox
Make scheduler functions thread safe core wise. A big step towards playback running on COP (not yet possible because more protection on file system level is necessary).
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12926 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
6c487eb5d1
commit
66258a30a4
10 changed files with 368 additions and 148 deletions
|
|
@ -73,6 +73,9 @@ struct event_queue
|
|||
struct thread_entry *thread;
|
||||
unsigned int read;
|
||||
unsigned int write;
|
||||
#if NUM_CORES > 1
|
||||
bool irq_safe;
|
||||
#endif
|
||||
#ifdef HAVE_EXTENDED_MESSAGING_AND_NAME
|
||||
struct queue_sender_list *send;
|
||||
#endif
|
||||
|
|
@ -105,6 +108,11 @@ int tick_add_task(void (*f)(void));
|
|||
int tick_remove_task(void (*f)(void));
|
||||
|
||||
extern void queue_init(struct event_queue *q, bool register_queue);
|
||||
#if NUM_CORES > 1
|
||||
extern void queue_set_irq_safe(struct event_queue *q, bool state);
|
||||
#else
|
||||
#define queue_set_irq_safe(q,state)
|
||||
#endif
|
||||
extern void queue_delete(struct event_queue *q);
|
||||
extern void queue_wait(struct event_queue *q, struct event *ev);
|
||||
extern void queue_wait_w_tmo(struct event_queue *q, struct event *ev, int ticks);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue