All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 0/5] xen/console: cleanup console input switch logic
@ 2025-05-19 20:12 dmkhn
  2025-05-19 20:12 ` [PATCH v3 1/5] xen/console: rename switch_serial_input() to console_switch_input() dmkhn
                   ` (4 more replies)
  0 siblings, 5 replies; 10+ messages in thread
From: dmkhn @ 2025-05-19 20:12 UTC (permalink / raw)
  To: xen-devel
  Cc: andrew.cooper3, anthony.perard, jbeulich, julien, michal.orzel,
	roger.pau, sstabellini, dmukhin

The patch series originates from the NS16550 UART emulator series [1] (x86)
which requires ability to switch physical console input to a PVH/HVM domain
with an emulated UART.

Currently, on x86, console input can be rotated in round-robin manner only
between dom0, PV shim, and Xen itself. On Arm the input rotation can include
domUs with vpl011.

The main idea of this series is introducing a per-domain permission flag that
is set during domain initialization and used by the console driver to switch
the input across permitted domains.

Patch 1 performs rename of switch_serial_input() to fit the console driver
notation.

Patch 2 simplifies the existing vUART code by using newly introduced API.

Patch 3 introduces a new domain permission flag to mark ownership of the
console input for the console driver.

Patch 4 cleans up the console input switch logic by removing dependency
on max_init_domid. Depends on patches 1, 3 and [2].

Patch 5 performs rename of console_rx to console_domid to match the usage
of the symbol in the code.

[1] https://lore.kernel.org/xen-devel/20250103-vuart-ns8250-v3-v1-0-c5d36b31d66c@ford.com/
[2] https://lore.kernel.org/xen-devel/20250519192306.1364471-1-dmukhin@ford.com/
[3] Link to v2: https://lore.kernel.org/xen-devel/20250331230508.440198-1-dmukhin@ford.com/
[4] Link to CI: https://gitlab.com/xen-project/people/dmukhin/xen/-/pipelines/1825448327

Denis Mukhin (5):
  xen/console: rename switch_serial_input() to console_switch_input()
  xen/console: introduce console_get_domid()
  xen/console: introduce console input permission
  xen/console: remove max_init_domid dependency
  xen/console: rename console_rx to console_domid

 xen/arch/arm/include/asm/setup.h        |   2 -
 xen/arch/arm/setup.c                    |   2 -
 xen/arch/arm/vpl011.c                   |   7 +-
 xen/arch/ppc/include/asm/setup.h        |   2 -
 xen/arch/riscv/include/asm/setup.h      |   2 -
 xen/arch/x86/include/asm/setup.h        |   2 -
 xen/arch/x86/pv/shim.c                  |   2 +
 xen/common/device-tree/dom0less-build.c |   2 -
 xen/common/domain.c                     |  31 +++++++
 xen/drivers/char/console.c              | 105 +++++++++++-------------
 xen/include/xen/console.h               |   3 +-
 xen/include/xen/domain.h                |   1 +
 xen/include/xen/sched.h                 |   8 +-
 13 files changed, 94 insertions(+), 75 deletions(-)

-- 
2.34.1




^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2025-05-22  0:31 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-05-19 20:12 [PATCH v3 0/5] xen/console: cleanup console input switch logic dmkhn
2025-05-19 20:12 ` [PATCH v3 1/5] xen/console: rename switch_serial_input() to console_switch_input() dmkhn
2025-05-20  6:07   ` Jan Beulich
2025-05-19 20:12 ` [PATCH v3 2/5] xen/console: introduce console_get_domid() dmkhn
2025-05-20  6:20   ` Jan Beulich
2025-05-22  0:30     ` dmkhn
2025-05-19 20:12 ` [PATCH v3 3/5] xen/console: introduce console input permission dmkhn
2025-05-19 20:12 ` [PATCH v3 4/5] xen/console: remove max_init_domid dependency dmkhn
2025-05-20  6:28   ` Jan Beulich
2025-05-19 20:12 ` [PATCH v3 5/5] xen/console: rename console_rx to console_domid dmkhn

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.