On Sat, 19 Sept 2026 at 17:47, ~jprx <[email protected]> wrote:
>
> The Exynos 4210 UART FIFO implementation suffers from an overflow that
> can occur when large buffers are sent into it. Specifically, this
> overflow is caused by the underlying circular buffer implementation
> making use of a store and retrieve pointer. When implemented this way, a
> circular buffer's capacity is 1 less than the size of the buffer, but
> the code as written assumes the entire buffer is available for storing
> data.
>
> If a large amount of data is sent into the UART when FIFO mode is
> enabled, the FIFO may overflow before the guest has time to receive the
> data, resulting in the first part of the message being lost.
>
> This patch series includes a qtest that demonstrates the current
> implementation suffers from an overflow that results in data truncation,
> and a fix that switches the Exynos UART FIFO implementation for fifo8,
> which does not suffer from this problem. After applying the suggested
> fix, the test passes.
>
> jprx (2):
>   tests/qtest: add test for exynos4210 uart fifo overflow bug
>   hw/char/exynos4210_uart: fix fifo overflow

Applied to target-arm.next, thanks (with the tweak noted in my
reply to the second patch). I have reversed the order of the two
patches, so that we fix the bug before adding the test case.
Otherwise in the git history there would be a point where "make check"
fails, which is awkward for "git bisect" and similar operations.

thanks
-- PMM

Reply via email to