linux/arch/um/include
Benjamin Berg b2f9b77c7f um: chan: use blocking IO for console output for time-travel
When in time-travel mode (infinite-cpu or external) time should not pass
for writing to the console. As such, it makes sense to put the FD for
the output side into blocking mode and simply let any write to it hang.

If we did not do this, then time could pass waiting for the console to
become writable again. This is not desirable as it has random effects on
the clock between runs.

Implement this by duplicating the FD if output is active in a relevant
mode and setting the duplicate to be blocking. This avoids changing the
input channel to be blocking should it exists. After this, use the
blocking FD for all write operations and do not allocate an IRQ it is
set.

Without time-travel mode fd_out will always match fd_in and IRQs are
registered.

Signed-off-by: Benjamin Berg <benjamin.berg@intel.com>
Link: https://patch.msgid.link/20231018123643.1255813-4-benjamin@sipsolutions.net
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2024-07-03 12:18:02 +02:00
..
asm This pull request contains the following changes for UML: 2024-05-25 13:17:48 -07:00
linux um: virtio/pci: enable suspend/resume 2021-06-17 21:45:44 +02:00
shared um: chan: use blocking IO for console output for time-travel 2024-07-03 12:18:02 +02:00
uapi/asm um: Fix W=1 missing-include-dirs warnings 2021-04-15 23:10:57 +02:00