Lines Matching refs:read_idx
91 atomic_t read_idx; member
160 int read_idx; in iowarrior_callback() local
182 read_idx = atomic_read(&dev->read_idx); in iowarrior_callback()
185 if ((intr_idx != read_idx) in iowarrior_callback()
200 if (read_idx == aux_idx) { in iowarrior_callback()
202 read_idx = (++read_idx == MAX_INTERRUPT_BUFFER) ? 0 : read_idx; in iowarrior_callback()
203 atomic_set(&dev->read_idx, read_idx); in iowarrior_callback()
268 int intr_idx, read_idx; in read_index() local
270 read_idx = atomic_read(&dev->read_idx); in read_index()
273 return (read_idx == intr_idx ? -1 : read_idx); in read_index()
283 int read_idx; in iowarrior_read() local
302 if ((read_idx = read_index(dev)) == -1) { in iowarrior_read()
310 || (read_idx = in iowarrior_read()
322 if (read_idx == -1) { in iowarrior_read()
329 offset = read_idx * (dev->report_size + 1); in iowarrior_read()
335 read_idx = ++read_idx == MAX_INTERRUPT_BUFFER ? 0 : read_idx; in iowarrior_read()
336 atomic_set(&dev->read_idx, read_idx); in iowarrior_read()
782 atomic_set(&dev->read_idx, 0); in iowarrior_probe()