# \[PATCH 5/9\] xen/x86: make "earlyprintk=xen" work for HVM/PVH DomU

- Subsystems: HYPERVISOR VIRTUAL CONSOLE DRIVER, DOCUMENTATION, THE REST, TTY LAYER AND SERIAL DRIVERS
- Maintainers: Jonathan Corbet, Linus Torvalds, Greg Kroah-Hartman, Jiri Slaby
- Status: SUPERSEDED (Superseded by v2 posted 2021-09-30)
- Superseded by v2 (posted 2021-09-30).
- Revision v1 (2 revisions archived).
- List: linuxppc-dev
- 2 messages, 2 authors
- Page: https://ratatoskr.run/linuxppc-dev/2021/09/1499034/t

## \[PATCH 5/9\] xen/x86: make "earlyprintk=xen" work for HVM/PVH DomU

- From: Jan Beulich \<hidden\>
- Date: 2021-09-07 10:10:25 
- Message: https://ratatoskr.run/linuxppc-dev/2021/09/1499034.md

```text
xenboot_write_console() is dealing with these quite fine so I don't see
why xenboot_console_setup() would return -ENOENT in this case.

Adjust documentation accordingly.

Signed-off-by: Jan Beulich <redacted>

--- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -1266,7 +1266,7 @@
 			The VGA and EFI output is eventually overwritten by
 			the real console.
 
-			The xen output can only be used by Xen PV guests.
+			The xen option can only be used in Xen domains.
 
 			The sclp output can only be used on s390.
 
--- a/drivers/tty/hvc/hvc_xen.c
+++ b/drivers/tty/hvc/hvc_xen.c
@@ -618,10 +618,8 @@ static int __init xenboot_console_setup(
 {
 	static struct xencons_info xenboot;
 
-	if (xen_initial_domain())
+	if (xen_initial_domain() || !xen_pv_domain())
 		return 0;
-	if (!xen_pv_domain())
-		return -ENODEV;
 
 	return xencons_info_pv_init(&xenboot, 0);
 }

```

## Re: \[PATCH 5/9\] xen/x86: make "earlyprintk=xen" work for HVM/PVH DomU

- From: Juergen Gross \<jgross@suse.com\>
- Date: 2021-09-23 14:08:50 
- Message: https://ratatoskr.run/linuxppc-dev/2021/09/1519607.md

```text
On 07.09.21 12:10, Jan Beulich wrote:
> xenboot_write_console() is dealing with these quite fine so I don't see
> why xenboot_console_setup() would return -ENOENT in this case.
>
> Adjust documentation accordingly.
>
> Signed-off-by: Jan Beulich <redacted>

Reviewed-by: Juergen Gross <jgross@suse.com>


Juergen
```
