From: Denis Mukhin
Add new emulation flag for virtual UART on x86 and plumb it through the stack.
This change enables NS8250 emulator initialization.
Signed-off-by: Denis Mukhin
---
tools/libs/light/libxl_x86.c | 6 +-
tools/ocaml/libs/xc/xenctrl.ml| 1 +
tools/ocaml/libs/xc/xe
From: Denis Mukhin
Minor update related to virtual UART support.
Also:
s/pv/PV/g
s/hvm/HVM/g
Signed-off-by: Denis Mukhin
---
docs/misc/console.txt | 48 +---
1 file changed, 25 insertions(+), 23 deletions(-)
diff --git a/docs/misc/console.txt b/d
The patch series introduces initial in-hypervisor emulator for
NS8250/NS16x50-compatible UARTs under CONFIG_HAS_VUART_NS8250.
In parallel domain creation scenario (hyperlaunch), NS8520 emulator helps
early guest OS bringup debugging, because it eliminates dependency on the
external emulator being
From: Denis Mukhin
Added missing definitions needed for NS8250 UART emulator.
Signed-off-by: Denis Mukhin
---
xen/include/xen/8250-uart.h | 82 +
1 file changed, 61 insertions(+), 21 deletions(-)
diff --git a/xen/include/xen/8250-uart.h b/xen/includ
From: Denis Mukhin
Move domain_has_vuart() to arch namespace as preparation code change for
architecture-agnostic way of forwarding physical console to the guest OS w/
in-hypervisor UART emulator.
Signed-off-by: Denis Mukhin
---
xen/arch/arm/include/asm/domain.h | 9 +
xen/arch/arm/vpl
From: Denis Mukhin
Introduce definition for IRQ resource checks.
Signed-off-by: Denis Mukhin
---
xen/include/xen/irq.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/xen/include/xen/irq.h b/xen/include/xen/irq.h
index
95034c0d6bb5f0aa7d5bb572aca59872508a438a..aee878293ecc0de6a938bcfea114
From: Denis Mukhin
console_init_owner() is introduced for selecting the boot-time console owner.
Signed-off-by: Denis Mukhin
---
xen/drivers/char/console.c | 27 +--
1 file changed, 17 insertions(+), 10 deletions(-)
diff --git a/xen/drivers/char/console.c b/xen/drivers
From: Denis Mukhin
There are several console drivers which have same checks w.r.t. printable
characters. The check is moved to new isconsole() macro and re-used in
the console drivers.
Signed-off-by: Denis Mukhin
---
xen/arch/arm/vuart.c | 3 +--
xen/arch/x86/hvm/hvm.c | 3 +--
xen/d
From: Denis Mukhin
Use guest_printk() in all current in-hypervisor UART emulators.
That slightly improves the logging as guest_printk() already prints the
domain ID.
Signed-off-by: Denis Mukhin
---
xen/arch/arm/vpl011.c | 2 +-
xen/arch/arm/vuart.c | 2 +-
2 files changed, 2 insertions(+), 2
From: Denis Mukhin
Introduce domain_has_vuart() for x86 port to be used in the console driver.
Signed-off-by: Denis Mukhin
---
xen/arch/x86/include/asm/domain.h | 3 +++
1 file changed, 3 insertions(+)
diff --git a/xen/arch/x86/include/asm/domain.h
b/xen/arch/x86/include/asm/domain.h
index
From: Denis Mukhin
Move resource definitions to a new architecture-agnostic shared header file.
It will be used in follow on NS8250 emulator code to describe legacy
PC COM resources.
Signed-off-by: Denis Mukhin
---
xen/common/device-tree/device-tree.c | 21 +--
xen/drivers/pas
From: Denis Mukhin
Move get_initial_domain_id() to a public API and enable for all architectures.
That is pre-requisite change for console focus switch logic cleanup.
Signed-off-by: Denis Mukhin
---
xen/arch/x86/include/asm/pv/shim.h | 4 ++--
xen/arch/x86/pv/shim.c | 4 ++--
xen
From: Denis Mukhin
Updated the name to highlight the logic of selection the physical console
owner: existing code does not switch only serial console, it also switches
video console and debugging console (debug I/O port and console hypercall).
Signed-off-by: Denis Mukhin
---
xen/drivers/char/c
From: Denis Mukhin
Move max_init_domid to a public API and enable for all architectures.
That is pre-requisite change for console focus switch logic cleanup.
Signed-off-by: Denis Mukhin
---
xen/arch/arm/include/asm/setup.h | 2 --
xen/arch/arm/setup.c | 2 --
xen/arch/ppc/inclu
From: Denis Mukhin
Introduce domain_has_vuart() for PPC port to be used in the console driver.
Signed-off-by: Denis Mukhin
---
xen/arch/ppc/include/asm/domain.h | 2 ++
1 file changed, 2 insertions(+)
diff --git a/xen/arch/ppc/include/asm/domain.h
b/xen/arch/ppc/include/asm/domain.h
index
3
From: Denis Mukhin
While working on console forwarding for virtual NS8250 I stepped into
flask_domain_alloc_security()
where break statement was missing in default case which violates MISRA
rule 16.4.
Fixed everywhere in hooks.c.
Signed-off-by: Denis Mukhin
---
xen/xsm/flask/hooks.c | 4 +++
From: Denis Mukhin
Print d->arch.emulation_flags on the console for better traceability while
debugging in-hypervisor hardware emulators.
Signed-off-by: Denis Mukhin
---
xen/arch/x86/domain.c | 8 ++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/xen/arch/x86/domain.c b/xe
From: Denis Mukhin
Signed-off-by: Denis Mukhin
---
xen/arch/x86/setup.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/xen/arch/x86/setup.c b/xen/arch/x86/setup.c
index
d8661d7ca699c96f38229c75ad0a8626c6f675d4..0a748e2c14122d6c5d692bc5691e8cbe13a32c81
100644
--- a/xen/arc
From: Denis Mukhin
Introduce domain_has_vuart() for RISC-V port to be used in the console driver.
Signed-off-by: Denis Mukhin
---
xen/arch/riscv/include/asm/domain.h | 2 ++
1 file changed, 2 insertions(+)
diff --git a/xen/arch/riscv/include/asm/domain.h
b/xen/arch/riscv/include/asm/domain.h
From: Denis Mukhin
Move existing aliases to a common header so those could be used in the new
code.
The code looks simpler w/ kmalloc(): type specification of the
object being allocated is not required, e.g.:
...
struct my_obj_s *obj;
obj = kmalloc(sizeof(*obj), 0);
...
Signed-off-by: Deni
From: Denis Mukhin
There are few places which check pv_shim console under CONFIG_PV_SHIM in xen
console driver. Instead of #ifdef-ing, use new consoled_is_enabled() to
customize the logic.
Header file now can be included w/o CONFIG_X86.
Signature of consoled_guest_{rx,tx} has changed to account
From: Denis Mukhin
The new command line switch `hwdom_crashconsole=BOOL` allows to switch serial
console input focus to xen for machine state inspection using keyhandler
mechanism after the hardware domain crashes.
The new command line switch is aliased via `dom0=...,crashconsole` knob.
Such fu
From: Denis Mukhin
Preparation for the follow on change to switch console_owner to
domid_t address space.
Signed-off-by: Denis Mukhin
---
xen/drivers/char/console.c | 26 +-
1 file changed, 13 insertions(+), 13 deletions(-)
diff --git a/xen/drivers/char/console.c b/xen
From: Denis Mukhin
console_input_domain() takes an RCU lock to protect domain structure.
That implies call to rcu_unlock_domain() after use.
Rename console_input_domain() to rcu_lock_domain_console_owner() to
highlight the need of calling rcu_unlock_domain().
Signed-off-by: Denis Mukhin
---
x
From: Denis Mukhin
Added convenience wrappers for asserting/de-asserting interrupts in the
hardware emulation code.
That will be used for PCI-based NS8250 emulator.
Signed-off-by: Denis Mukhin
---
xen/arch/x86/hvm/irq.c | 24
xen/arch/x86/include/asm/hvm/i
From: Denis Mukhin
Add separate menu for configuring HVM build-time settings.
That will help organizing HVM-specific options under a separate menu.
Signed-off-by: Denis Mukhin
---
xen/arch/x86/Kconfig | 66 +++-
xen/arch/x86/hvm/Kconfig | 63
From: Denis Mukhin
console_owner_domid() is introduced to obtain the "console owner" domain ID.
The call is used in NS8250 emulator to identify the case when physical xen
console focus is owned by the domain w/ NS8250 emulator, in which case,
messages from guest OS are formatted w/o '(XEN)' pref
From: Denis Mukhin
Update the hint w/ the combination of keys to press to switch physical console
to the next owner.
Signed-off-by: Denis Mukhin
---
xen/drivers/char/console.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/xen/drivers/char/console.c b/xen/drivers/char/
From: Denis Mukhin
Introduce new printk() variant for convenient printouts which skip '(XEN)'
prefix on xen console. This is needed for the case when physical console is
owned by a domain w/ in-hypervisor UART emulation enabled.
Signed-off-by: Denis Mukhin
---
xen/drivers/char/console.c | 8 ++
From: Denis Mukhin
The code now inspects d->is_console flag to decide whether the console focus
should move to the domain w/ console after administrator presses .
To do that max_init_domid is updated in domain_create().
Console owner domain switch logic updated accordingly.
Signed-off-by: Deni
From: Denis Mukhin
PV Linux kernel uses HYPERVISOR_console_io hypercall for early console which
ends up being handled by Xen's console driver's guest_console_write().
guest_console_write() duplicates the code from __putstr(), elimitate code
duplication.
Signed-off-by: Denis Mukhin
---
xen/dri
From: Denis Mukhin
console_set_owner() is introduced for setting the new console owner.
Switches console owner to domain ID vs range of integer numbers mapped to
domain IDs.
This a public API to console driver, will be used in the follow on code change.
Signed-off-by: Denis Mukhin
---
xen/dr
From: Denis Mukhin
Add new CONRING_LOG_SHIFT Kconfig parameter to specify the boot console buffer
size as a power of 2.
Bump default size to 32 KiB.
Link: https://gitlab.com/xen-project/xen/-/issues/185
Signed-off-by: Denis Mukhin
---
xen/drivers/char/Kconfig | 23 +++
x
From: Denis Mukhin
Enable console focus for domains w/ virtual NS8250.
Code change allows to capture the output from the guest OS now and send it to
the physical console device.
Signed-off-by: Denis Mukhin
---
xen/drivers/char/console.c | 5 +
1 file changed, 5 insertions(+)
diff --git a
From: Denis Mukhin
Add initial in-hypervisor emulator for NS8250/NS16x50-compatible UARTs under
CONFIG_HAS_VUART_NS8250.
In parallel domain creation scenario (hyperlaunch), NS8520 emulator helps
early guest OS bringup debugging, because it eliminates dependency on the
external emulator being ope
From: Denis Mukhin
Xen console driver has vpl011-related logic which shall belong vpl011 emulator
code. Move vpl011-related to vpl011.c.
Signed-off-by: Denis Mukhin
---
xen/arch/arm/include/asm/vpl011.h | 2 +-
xen/arch/arm/vpl011.c | 15 ---
xen/drivers/char/console.c
From: Denis Mukhin
With introduction of NS8250 emulator for x86, the logic of switching console
focus gets more convoluted: HVM domain w/ NS8205 must be able to receive the
physical console input for guest VM debugging.
Also, existing code does not honor `hardware_dom=` xen command line paramete
From: Denis Mukhin
Introduce domain_has_vuart() for RISC-V port to be used in the console driver.
Signed-off-by: Denis Mukhin
Reviewed-by: Oleksii Kurochko
---
xen/arch/riscv/include/asm/domain.h | 2 ++
1 file changed, 2 insertions(+)
diff --git a/xen/arch/riscv/include/asm/domain.h
b/xen/
From: Denis Mukhin
Move resource definitions to a new architecture-agnostic shared header file.
It will be used in follow on NS8250 emulator code to describe legacy
PC COM resources.
Signed-off-by: Denis Mukhin
---
xen/common/device-tree/device-tree.c | 21 +--
xen/drivers/pas
From: Denis Mukhin
Minor update related to virtual UART support.
Also:
s/pv/PV/g
s/hvm/HVM/g
Signed-off-by: Denis Mukhin
---
docs/misc/console.txt | 50 ++
1 file changed, 26 insertions(+), 24 deletions(-)
diff --git a/docs/misc/console.txt b
From: Denis Mukhin
Introduce new printk() variant for convenient printouts which skip '(XEN)'
prefix on xen console. This is needed for the case when physical console is
owned by a domain w/ in-hypervisor UART emulation enabled.
Signed-off-by: Denis Mukhin
---
automation/eclair_analysis/ECLAIR
From: Denis Mukhin
Introduce domain_has_vuart() for PPC port to be used in the console driver.
Signed-off-by: Denis Mukhin
---
xen/arch/ppc/include/asm/domain.h | 2 ++
1 file changed, 2 insertions(+)
diff --git a/xen/arch/ppc/include/asm/domain.h
b/xen/arch/ppc/include/asm/domain.h
index
3
From: Denis Mukhin
Use guest_printk() in all current in-hypervisor UART emulators.
That slightly improves the logging as guest_printk() already prints the
domain ID.
Signed-off-by: Denis Mukhin
---
xen/arch/arm/vpl011.c | 2 +-
xen/arch/arm/vuart.c | 2 +-
2 files changed, 2 insertions(+), 2
From: Denis Mukhin
Move max_init_domid to a public API and enable for all architectures.
That is pre-requisite change for console focus switch logic cleanup.
max_init_domid is updated in domain_create().
Signed-off-by: Denis Mukhin
---
xen/arch/arm/include/asm/setup.h | 2 --
xen/arch/arm/s
From: Denis Mukhin
Introduce domain_has_vuart() for x86 port to be used in the console driver.
Signed-off-by: Denis Mukhin
---
xen/arch/x86/include/asm/domain.h | 3 +++
1 file changed, 3 insertions(+)
diff --git a/xen/arch/x86/include/asm/domain.h
b/xen/arch/x86/include/asm/domain.h
index
From: Denis Mukhin
Move get_initial_domain_id() to a public API and enable for all architectures.
That is pre-requisite change for console focus switch logic cleanup.
Signed-off-by: Denis Mukhin
---
xen/arch/x86/include/asm/pv/shim.h | 4 ++--
xen/arch/x86/pv/shim.c | 4 ++--
xen
From: Denis Mukhin
Xen console driver has vpl011-related logic which shall belong vpl011 emulator
code. Move vpl011-related to vpl011.c.
Signed-off-by: Denis Mukhin
---
xen/arch/arm/include/asm/vpl011.h | 2 +-
xen/arch/arm/vpl011.c | 15 +++
xen/drivers/char/console.c
From: Denis Mukhin
The code now inspects d->is_console flag to decide whether the console focus
should move to the domain w/ console after administrator presses .
Console owner domain switch logic updated accordingly.
Signed-off-by: Denis Mukhin
---
xen/arch/arm/dom0less-build.c | 2 +-
xen/
From: Denis Mukhin
Print d->arch.emulation_flags on the console for better traceability while
debugging in-hypervisor hardware emulators.
Signed-off-by: Denis Mukhin
---
xen/arch/x86/domain.c | 8 ++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/xen/arch/x86/domain.c b/xe
From: Denis Mukhin
Updated the name to highlight the logic of selection the physical console
owner: existing code does not switch only serial console, it also switches
video console and debugging console (debug I/O port and console hypercall).
Signed-off-by: Denis Mukhin
---
xen/drivers/char/c
The patch series introduces initial in-hypervisor emulator for
NS8250/NS16x50-compatible UARTs under CONFIG_HAS_VUART_NS8250.
In parallel domain creation scenario (hyperlaunch), NS8520 emulator helps
early guest OS bringup debugging, because it eliminates dependency on the
external emulator being
From: Denis Mukhin
console_owner_domid() is introduced to obtain the "console owner" domain ID.
The call is used in NS8250 emulator to identify the case when physical xen
console focus is owned by the domain w/ NS8250 emulator, in which case,
messages from guest OS are formatted w/o '(XEN)' pref
From: Denis Mukhin
Preparation for the follow on change to switch console_owner to
domid_t address space.
Signed-off-by: Denis Mukhin
---
xen/drivers/char/console.c | 26 +-
1 file changed, 13 insertions(+), 13 deletions(-)
diff --git a/xen/drivers/char/console.c b/xen
From: Denis Mukhin
There are several console drivers which have same checks w.r.t. printable
characters. The check is moved to new isconsole() macro and re-used in
the console drivers.
Signed-off-by: Denis Mukhin
---
xen/arch/arm/vuart.c | 3 +--
xen/arch/x86/hvm/hvm.c | 3 +--
xen/d
From: Denis Mukhin
Introduce definition for IRQ resource checks.
Signed-off-by: Denis Mukhin
---
xen/include/xen/irq.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/xen/include/xen/irq.h b/xen/include/xen/irq.h
index
95034c0d6bb5f0aa7d5bb572aca59872508a438a..aee878293ecc0de6a938bcfea114
From: Denis Mukhin
Move domain_has_vuart() to arch namespace as preparation code change for
architecture-agnostic way of forwarding physical console to the guest OS w/
in-hypervisor UART emulator.
Signed-off-by: Denis Mukhin
---
xen/arch/arm/dom0less-build.c | 2 ++
xen/arch/arm/domain.c
From: Denis Mukhin
There are few places which check pv_shim console under CONFIG_PV_SHIM in xen
console driver. Instead of #ifdef-ing, use new consoled_is_enabled() to
customize the logic.
Header file now can be included w/o CONFIG_X86.
Signature of consoled_guest_{rx,tx} has changed to account
From: Denis Mukhin
console_input_domain() takes an RCU lock to protect domain structure.
That implies call to rcu_unlock_domain() after use.
Rename console_input_domain() to rcu_lock_domain_console_owner() to
highlight the need of calling rcu_unlock_domain().
Signed-off-by: Denis Mukhin
---
x
From: Denis Mukhin
Enable console focus for domains w/ virtual NS8250.
Code change allows to capture the output from the guest OS now and send it to
the physical console device.
Signed-off-by: Denis Mukhin
---
xen/drivers/char/console.c | 5 +
1 file changed, 5 insertions(+)
diff --git a
From: Denis Mukhin
With introduction of NS8250 emulator for x86, the logic of switching console
focus gets more convoluted: HVM domain w/ NS8205 must be able to receive the
physical console input for guest VM debugging.
Also, existing code does not honor `hardware_dom=` xen command line paramete
From: Denis Mukhin
Add new emulation flag for virtual UART on x86 and plumb it through the stack.
This change enables NS8250 emulator initialization.
Signed-off-by: Denis Mukhin
---
tools/libs/light/libxl_x86.c | 6 +-
tools/ocaml/libs/xc/xenctrl.ml| 1 +
tools/ocaml/libs/xc/xe
From: Denis Mukhin
Add separate menu for configuring HVM build-time settings.
That will help organizing HVM-specific options under a separate menu.
Signed-off-by: Denis Mukhin
---
xen/arch/x86/Kconfig | 66 +++-
xen/arch/x86/hvm/Kconfig | 63
From: Denis Mukhin
Update the hint w/ the combination of keys to press to switch physical console
to the next owner.
Signed-off-by: Denis Mukhin
---
xen/drivers/char/console.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/xen/drivers/char/console.c b/xen/drivers/char/
From: Denis Mukhin
There are several console drivers which have same checks w.r.t. printable
characters. The check is moved to new is_console_printable() function and
re-used in the UART emulation / guest logging code.
Also, MISRA rule 21.13 for ctype.h has been exploited while working on
the co
From: Denis Mukhin
Switch console_owner address spaces from integers mapped to domain IDs to
straight domain IDs, which simplifies console focus handling code.
console_set_owner() is introduced for setting the new console owner. This is a
public API to Xen console driver (it will be used in the
From: Denis Mukhin
The new command line switch `hwdom_crashconsole=BOOL` allows to switch serial
console input focus to xen for machine state inspection using keyhandler
mechanism after the hardware domain crashes.
The new command line switch is aliased via `dom0=...,crashconsole` knob.
Such fu
x86 port of Xen lacks vUART facility similar to Arm's vpl011 to support x86
guest OS bring up in the embedded setups.
This patch series introduces initial in-hypervisor emulator for
NS8250/NS16x50-compatible UARTs under CONFIG_VUART_NS16550.
In parallel domain creation scenario (hyperlaunch), NS1
From: Denis Mukhin
Xen console driver has vpl011-related logic which shall belong vpl011 emulator
code (Arm port). Move vpl011-related code from arch-independent console driver
to Arm's vpl011.c.
Signed-off-by: Denis Mukhin
---
xen/arch/arm/include/asm/vpl011.h | 2 +-
xen/arch/arm/vpl011.c
From: Denis Mukhin
Using "vuart" in UART emulator designed for hardware domain debugging
is confusing in generic Arm code (e.g. vpl011 is also "vuart").
Fix that by adding hwdom prefix to all symbols in arm/vuart.c.
Also, remove domain_has_vuart() from arm/vuart.c since it is not needed.
Signed
From: Denis Mukhin
Update the symbol name to prepare for the follow on semantic change of console
owner identifier.
Signed-off-by: Denis Mukhin
---
xen/drivers/char/console.c | 22 +++---
1 file changed, 11 insertions(+), 11 deletions(-)
diff --git a/xen/drivers/char/console.c
From: Denis Mukhin
There are few places which check pv_shim console under CONFIG_PV_SHIM in xen
console driver. Instead of #ifdef-ing, use new consoled_is_enabled() to
customize the logic.
Header file now can be included w/o CONFIG_X86.
Signature of consoled_guest_{rx,tx} has changed so the err
From: Denis Mukhin
Define an architecture-independent location for describing hardware emulation
flags for configuring in-hypervisor emulators.
Print d->arch.emulation_flags from 'q' keyhandler for better traceability while
debugging in-hypervisor hardware emulators.
Also, expanded the error me
From: Denis Mukhin
PV Linux kernel uses HYPERVISOR_console_io hypercall for early console which
ends up being handled by Xen's console driver's guest_console_write().
guest_console_write() duplicates the code from __putstr(), elimitate code
duplication.
Signed-off-by: Denis Mukhin
---
xen/dri
From: Denis Mukhin
Update the hint with the combination of keys to press for the physical console
focus switch between the domains.
Signed-off-by: Denis Mukhin
---
xen/drivers/char/console.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/xen/drivers/char/console.c b/xe
From: Denis Mukhin
Add initial in-hypervisor emulator for NS8250/NS16x50-compatible UARTs under
CONFIG_VUART_NS16550.
x86 port of Xen lacks vUART facility similar to Arm's vpl011 to support x86
guest OS bring up in the embedded setups.
In parallel domain creation scenario (hyperlaunch), NS16550
From: Denis Mukhin
Added missing definitions needed for NS8250 UART emulator.
Re-used newly introduced MSR definitions in the existing ns16550 driver.
Also, fixed indentation in a comment for FCR register.
Signed-off-by: Denis Mukhin
---
xen/drivers/char/ns16550.c | 6 ++--
xen/include/xen
From: Denis Mukhin
If virtual UART prints on the physical console, the behavior is updated to:
- no prefix for Dom0 output;
- DOM$NUM for DomUs when not in focus, otherwise no prefix.
Introduce printk_noprefix() for convenient printouts which skip '(XEN)'
prefix on the physical console. This is
From: Denis Mukhin
Introduce a driver framework to abstract UART emulators in the hypervisor.
That allows for architecture-independent handling of virtual UARTs from Xen
console driver and simplifies enabling new architecture-dependent UART
emulators.
The framework is built under CONFIG_HAS_VUA
From: Denis Mukhin
Updated the name to highlight the physical console input selection logic:
existing code does not switch only serial console, it also switches debugging
console (debug I/O port and console hypercall).
Signed-off-by: Denis Mukhin
---
xen/drivers/char/console.c | 6 +++---
1 fi
From: Denis Mukhin
The code inspects d->is_console flag to decide whether the console focus
should move to the domain with console after administrator uses
key combination to switch the console focus.
Console owner switch logic updated accordingly.
Signed-off-by: Denis Mukhin
---
xen/arch/ar
From: Denis Mukhin
Add separate menu for configuring HVM build-time settings to help organizing
HVM-specific options.
Signed-off-by: Denis Mukhin
---
xen/arch/x86/Kconfig | 76 +---
xen/arch/x86/hvm/Kconfig | 74 ++
From: Denis Mukhin
console_input_domain() takes an RCU lock to protect domain structure.
That implies call to rcu_unlock_domain() after use.
Introduce a pair of console_get_domain() / console_put_domain() to highlight
the correct use of the call within the code interacting with Xen console
drive
From: Denis Mukhin
Introduce new emulation flag for virtual UART on x86 and plumb it through
domain creation code so NS16550 emulator is enabled properly.
Virtual UART facility is enabled for HVM domains only. Enabling it for PVH
domains requires some work, as vPIC is not enabled in PVH.
Also,
From: Denis Mukhin
Honor 'hardware_domid=' parameter across all architectures and update
max_init_domid correctly so that toolstack and, subsequently, console driver
could iterate across known domains more efficiently.
Also, move max_init_domid to arch-independent location.
Signed-off-by: Denis
From: Denis Mukhin
Add new CONRING_SIZE Kconfig parameter to specify the boot console buffer size
in bytes. The value is rounded to the nearest power of 2 to match existing
conring_size= behavior.
The supported range is [16KiB..128MiB].
Bump default size to 32 KiB.
Link: https://gitlab.com/xen
From: Denis Mukhin
Move common resource definitions to a new architecture-agnostic shared header
file.
Signed-off-by: Denis Mukhin
---
It will be used in follow on NS8250 emulator code to describe legacy
PC COM resources.
---
---
xen/common/device-tree/device-tree.c | 21 +
From: Denis Mukhin
Internal console ring is used to hold Xen messages before external consoles
(serial, VGA) consoles are fully initialized.
Ensure all messages are sent to all external consoles after their
initialization is completed.
Link: https://gitlab.com/xen-project/xen/-/issues/184
Signe
From: Denis Mukhin
Minor update related to virtual UART support.
Also:
s/pv/PV/g
s/hvm/HVM/g
Signed-off-by: Denis Mukhin
---
docs/misc/console.txt | 50 ++
1 file changed, 26 insertions(+), 24 deletions(-)
diff --git a/docs/misc/console.txt b
From: Denis Mukhin
Add new CONRING_LOG_SHIFT Kconfig parameter to specify the boot console buffer
size as a power of 2.
Bump default size to 32 KiB.
Link: https://gitlab.com/xen-project/xen/-/issues/185
Signed-off-by: Denis Mukhin
---
xen/drivers/char/Kconfig | 23 +++
x
From: Denis Mukhin
Messages printed before the serial and VGA consoles are initialized end up in
the internal console buffer (conring). Flush contents of conring to all
external consoles after external consoles are fully initialied.
Link: https://gitlab.com/xen-project/xen/-/issues/184
Signed-of
From: Denis Mukhin
Enable keyhandler mechanism for dumping state of emulated NS8250 on the
console.
Signed-off-by: Denis Mukhin
---
xen/arch/x86/hvm/vuart_ns8250.c | 122
1 file changed, 122 insertions(+)
diff --git a/xen/arch/x86/hvm/vuart_ns8250.c b/
From: Denis Mukhin
console_init_owner() is introduced for selecting the boot-time console owner.
Signed-off-by: Denis Mukhin
---
xen/drivers/char/console.c | 27 +--
1 file changed, 17 insertions(+), 10 deletions(-)
diff --git a/xen/drivers/char/console.c b/xen/drivers
From: Denis Mukhin
PV Linux kernel uses HYPERVISOR_console_io hypercall for early console which
ends up being handled by Xen's console driver's guest_console_write().
guest_console_write() duplicates the code from __putstr(), elimitate code
duplication.
Signed-off-by: Denis Mukhin
---
xen/dri
From: Denis Mukhin
Add initial in-hypervisor emulator for NS8250/NS16x50-compatible UARTs under
CONFIG_HAS_VUART_NS8250.
In parallel domain creation scenario (hyperlaunch), NS8520 emulator helps
early guest OS bringup debugging, because it eliminates dependency on the
external emulator being ope
From: Denis Mukhin
console_set_owner() is introduced for setting the new console owner.
Switches console owner to domain ID vs range of integer numbers mapped to
domain IDs.
This a public API to console driver, will be used in the follow on code change.
Signed-off-by: Denis Mukhin
---
xen/dr
From: Denis Mukhin
Added convenience wrappers for asserting/de-asserting interrupts in the
hardware emulation code.
That will be used for PCI-based NS8250 emulator.
Signed-off-by: Denis Mukhin
---
xen/arch/x86/hvm/irq.c | 24
xen/arch/x86/include/asm/hvm/i
From: Denis Mukhin
The new command line switch `hwdom_crashconsole=BOOL` allows to switch serial
console input focus to xen for machine state inspection using keyhandler
mechanism after the hardware domain crashes.
The new command line switch is aliased via `dom0=...,crashconsole` knob.
Such fu
From: Denis Mukhin
Added missing definitions needed for NS8250 UART emulator.
Signed-off-by: Denis Mukhin
---
xen/include/xen/8250-uart.h | 81 +
1 file changed, 60 insertions(+), 21 deletions(-)
diff --git a/xen/include/xen/8250-uart.h b/xen/includ
98 matches
Mail list logo