Lines Matching defs:delay
23 #include <linux/delay.h>
571 /* calculate runtime delay from LPIB */
578 int delay;
581 delay = pos - lpib_pos;
583 delay = lpib_pos - pos;
584 if (delay < 0) {
585 if (delay >= azx_dev->core.delay_negative_threshold)
586 delay = 0;
588 delay += azx_dev->core.bufsize;
591 if (delay >= azx_dev->core.period_bytes) {
593 "Unstable LPIB (%d >= %d); disabling LPIB delay counting\n",
594 delay, azx_dev->core.period_bytes);
595 delay = 0;
600 return bytes_to_frames(substream->runtime, delay);
635 * Returns 1 if OK to proceed, 0 for delay handling, -1 for skipping update
848 unsigned int pos, delay;
854 runtime->delay = AMD_FIFO_SIZE;
855 delay = frames_to_bytes(runtime, AMD_FIFO_SIZE);
857 if (pos < delay) {
858 delay = pos;
859 runtime->delay = bytes_to_frames(runtime, pos);
867 if (pos < delay)
869 pos -= delay;
881 return substream->runtime->delay;
1828 dev_dbg(chip->card->dev, "Enable delay in RIRB handling\n");