| 112 | }; |
| 113 | |
| 114 | void ps2_queue(void *opaque, int b) |
| 115 | { |
| 116 | PS2State *s = (PS2State *)opaque; |
| 117 | PS2Queue *q = &s->queue; |
| 118 | |
| 119 | if (q->count >= PS2_QUEUE_SIZE) |
| 120 | return; |
| 121 | q->data[q->wptr] = b; |
| 122 | if (++q->wptr == PS2_QUEUE_SIZE) |
| 123 | q->wptr = 0; |
| 124 | q->count++; |
| 125 | s->update_irq(s->update_arg, 1); |
| 126 | } |
| 127 | |
| 128 | #define INPUT_MAKE_KEY_MIN 96 |
| 129 | #define INPUT_MAKE_KEY_MAX 127 |
no outgoing calls
no test coverage detected