fifo8: honour do_pop argument in fifo8_peekpop_buf()
authorMark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Wed, 28 Aug 2024 12:22:55 +0000 (13:22 +0100)
committerPhilippe Mathieu-Daudé <philmd@linaro.org>
Fri, 13 Sep 2024 18:11:13 +0000 (20:11 +0200)
commitcfc65db19bc9f796f338dc7220811471b6ab2f28
treefbb9e4c0363654bf4f7194616d85a0c78b7155e1
parent7fd6866c3c1596f6ff7de9ff2fa64275627f7ffe
fifo8: honour do_pop argument in fifo8_peekpop_buf()

Pass the do_pop value from fifo8_peekpop_buf() to fifo8_peekpop_bufptr()
to allow peeks to the FIFO buffer, including adjusting the skip parameter
to handle the case where the internal FIFO buffer wraps around.

Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Reviewed-by: Octavian Purdila <tavip@google.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Tested-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-ID: <20240828122258.928947-7-mark.cave-ayland@ilande.co.uk>
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
util/fifo8.c