Regression due to d9581c7dcac15c02ad4d47c60c60f4d8f197db55 en/fb: allow xenfb initialization for hvm guest
This has been in queue for some time.
In our kernels (UEK3) we had to revert said patch. The patch says:
" xen/fb: allow xenfb initialization for hvm guests
There is no reasons why an HVM guest shouldn't be allowed to use xenfb. As a matter of fact ARM guests, HVM from Linux POV, can use xenfb. Given that no Xen toolstacks configure a xenfb backend for x86 HVM guests, they are not affected.
Please note that at this time QEMU needs few outstanding fixes to provide xenfb on ARM:
http://marc.info/?l=qemu-devel&m=138739419700837&w=2
"
which is a lie. The "no Xen toolstacks configure a xenfb backend for x86 HVM" is actually a lie. If you try to boot this kernel under Xen with Xend it will be a problem - as Xend does setup an 'vfb' device.
The end result is that during the bootup - up until X starts, there is no console output on the VNC window. As the Linux kernel tries to use the vfb console driver.
Any suggestsion on how to fix this? Should we just wrap the whole thing with #ifdef, like this?
drivers/video/fbdev/xen-fbfront.c +4 -1
@@ -696,7 +696,10 @@ static int __init xenfb_init(void) {if (!xen_domain ())return -ENODEV ; - +#ifdef CONFIG_X86 +if (!xen_pv_domain ()) +return -ENODEV ; +#endif /* Nothing to do if running in dom0. */ if (xen_initial_domain ())return -ENODEV ;
Quoted 22 lines · Konrad Rzeszutek Wilk
This has been in queue for some time.
In our kernels (UEK3) we had to revert said patch. The patch says:
" xen/fb: allow xenfb initialization for hvm guests
There is no reasons why an HVM guest shouldn't be allowed to use xenfb. As a matter of fact ARM guests, HVM from Linux POV, can use xenfb. Given that no Xen toolstacks configure a xenfb backend for x86 HVM guests, they are not affected.
Please note that at this time QEMU needs few outstanding fixes to provide xenfb on ARM:
http://marc.info/?l=qemu-devel&m=138739419700837&w=2
"which is a lie. The "no Xen toolstacks configure a xenfb backend for x86 HVM" is actually a lie. If you try to boot this kernel under Xen with Xend it will be a problem - as Xend does setup an 'vfb' device.
Quoted 6 lines
The end result is that during the bootup - up until X starts, there is no console output on the VNC window. As the Linux kernel tries to use the vfb console driver.
Any suggestsion on how to fix this? Should we just wrap the whole thing with #ifdef, like this?
Is vfb properly setup by Xend? Does the console show on the vfb framebuffer?
If the vfb console works but is undesirable because the user expects the output on the main vnc window (the vga framebuffer), then could we find a way to prioritize the vga console over vfb on x86?
If the vfb console doesn't work, for example because the backend is not running, then maybe we could find a way in Linux to avoid vfb if it is not actually "connected".
Quoted 17 lines
drivers/video/fbdev/xen-fbfront.c +4
-1@@ -696,7 +696,10 @@ static int __init xenfb_init(void) {if (!xen_domain ())return -ENODEV ; - +#ifdef CONFIG_X86 +if (!xen_pv_domain ()) +return -ENODEV ; +#endif /* Nothing to do if running in dom0. */ if (xen_initial_domain ())return -ENODEV ;
Quoted 23 lines · Stefano Stabellini
Quoted 22 lines · Konrad Rzeszutek Wilk
This has been in queue for some time.
In our kernels (UEK3) we had to revert said patch. The patch says:
" xen/fb: allow xenfb initialization for hvm guests
There is no reasons why an HVM guest shouldn't be allowed to use xenfb. As a matter of fact ARM guests, HVM from Linux POV, can use xenfb. Given that no Xen toolstacks configure a xenfb backend for x86 HVM guests, they are not affected.
Please note that at this time QEMU needs few outstanding fixes to provide xenfb on ARM:
http://marc.info/?l=qemu-devel&m=138739419700837&w=2
"which is a lie. The "no Xen toolstacks configure a xenfb backend for x86 HVM" is actually a lie. If you try to boot this kernel under Xen with Xend it will be a problem - as Xend does setup an 'vfb' device.
Quoted 8 lines
Quoted 6 lines
The end result is that during the bootup - up until X starts, there is no console output on the VNC window. As the Linux kernel tries to use the vfb console driver.
Any suggestsion on how to fix this? Should we just wrap the whole thing with #ifdef, like this?
Is vfb properly setup by Xend? Does the console show on the vfb framebuffer?
The vfb xenstore keys are. The VFB framebuffer (QEMU) is not - as it in most cases runs as qemu-traditional which would not set it up.
Quoted 4 lines
If the vfb console works but is undesirable because the user expects the output on the main vnc window (the vga framebuffer), then could we find a way to prioritize the vga console over vfb on x86?
This is all about Xend and QEMU traditional. Fixing the bug in Xend would be nice but I don't see anybody accepting the patch as those are kind of 'dead'.
Quoted 4 lines
If the vfb console doesn't work, for example because the backend is not running, then maybe we could find a way in Linux to avoid vfb if it is not actually "connected".
That sounds complicated. Especially during early bootup.
Quoted 19 lines
Quoted 19 lines
drivers/video/fbdev/xen-fbfront.c +4
-1@@ -696,7 +696,10 @@ static int __init xenfb_init(void) {if (!xen_domain ())return -ENODEV ; - +#ifdef CONFIG_X86 +if (!xen_pv_domain ()) +return -ENODEV ; +#endif /* Nothing to do if running in dom0. */ if (xen_initial_domain ())return -ENODEV ;
Quoted 17 lines · Konrad Rzeszutek Wilk
This has been in queue for some time.
In our kernels (UEK3) we had to revert said patch. The patch says:
" xen/fb: allow xenfb initialization for hvm guests
There is no reasons why an HVM guest shouldn't be allowed to use xenfb. As a matter of fact ARM guests, HVM from Linux POV, can use xenfb. Given that no Xen toolstacks configure a xenfb backend for x86 HVM guests, they are not affected.
Please note that at this time QEMU needs few outstanding fixes to provide xenfb on ARM:
Quoted 8 lines
which is a lie. The "no Xen toolstacks configure a xenfb backend for x86 HVM" is actually a lie. If you try to boot this kernel under Xen with Xend it will be a problem - as Xend does setup an 'vfb' device.
The end result is that during the bootup - up until X starts, there is no console output on the VNC window. As the Linux kernel tries to use the vfb console driver.
This looks like a toolstack bug to me. If the toolstack has configured a vfb backend surely that should be preferred to the emulated VGA?
Quoted 2 lines
Any suggestsion on how to fix this? Should we just wrap the whole thing with #ifdef, like this?
No. We want to avoid frontend drivers behaving differently on different architectures.
David
Quoted 23 lines · David Vrabel
Quoted 22 lines · Konrad Rzeszutek Wilk
This has been in queue for some time.
In our kernels (UEK3) we had to revert said patch. The patch says:
" xen/fb: allow xenfb initialization for hvm guests
There is no reasons why an HVM guest shouldn't be allowed to use xenfb. As a matter of fact ARM guests, HVM from Linux POV, can use xenfb. Given that no Xen toolstacks configure a xenfb backend for x86 HVM guests, they are not affected.
Please note that at this time QEMU needs few outstanding fixes to provide xenfb on ARM:
http://marc.info/?l=qemu-devel&m=138739419700837&w=2
"which is a lie. The "no Xen toolstacks configure a xenfb backend for x86 HVM" is actually a lie. If you try to boot this kernel under Xen with Xend it will be a problem - as Xend does setup an 'vfb' device.
Quoted 6 lines
Quoted 3 lines
The end result is that during the bootup - up until X starts, there is no console output on the VNC window. As the Linux kernel tries to use the vfb console driver.
This looks like a toolstack bug to me. If the toolstack has configured a vfb backend surely that should be preferred to the emulated VGA?
This is Xend. It is a bit brain dead in this category.
Quoted 6 lines
Quoted 3 lines
Any suggestsion on how to fix this? Should we just wrap the whole thing with #ifdef, like this?
No. We want to avoid frontend drivers behaving differently on different architectures.
We could try detecting that it is Xend (not sure how?) - or that it is Xen 4.4 or below - which would be the only versions that could be run with Xend.
Quoted 2 lines
David
Quoted 37 lines · Konrad Rzeszutek Wilk
Quoted 23 lines · David Vrabel
Quoted 22 lines · Konrad Rzeszutek Wilk
This has been in queue for some time.
In our kernels (UEK3) we had to revert said patch. The patch says:
" xen/fb: allow xenfb initialization for hvm guests
There is no reasons why an HVM guest shouldn't be allowed to use xenfb. As a matter of fact ARM guests, HVM from Linux POV, can use xenfb. Given that no Xen toolstacks configure a xenfb backend for x86 HVM guests, they are not affected.
Please note that at this time QEMU needs few outstanding fixes to provide xenfb on ARM:
http://marc.info/?l=qemu-devel&m=138739419700837&w=2
"which is a lie. The "no Xen toolstacks configure a xenfb backend for x86 HVM" is actually a lie. If you try to boot this kernel under Xen with Xend it will be a problem - as Xend does setup an 'vfb' device.
Quoted 6 lines
Quoted 3 lines
The end result is that during the bootup - up until X starts, there is no console output on the VNC window. As the Linux kernel tries to use the vfb console driver.
This looks like a toolstack bug to me. If the toolstack has configured a vfb backend surely that should be preferred to the emulated VGA?
This is Xend. It is a bit brain dead in this category.
Quoted 4 lines
Quoted 3 lines
Any suggestsion on how to fix this? Should we just wrap the whole thing with #ifdef, like this?
Quoted 6 lines
Quoted 2 lines
No. We want to avoid frontend drivers behaving differently on different architectures.
We could try detecting that it is Xend (not sure how?) - or that it is Xen 4.4 or below - which would be the only versions that could be run with Xend.
That's even worse. Please just fix your toolstack to not create the vfb backend if you don't want to use it.
David
Quoted 41 lines · David Vrabel
Quoted 40 lines · Konrad Rzeszutek Wilk
Quoted 23 lines · David Vrabel
Quoted 22 lines · Konrad Rzeszutek Wilk
This has been in queue for some time.
In our kernels (UEK3) we had to revert said patch. The patch says:
" xen/fb: allow xenfb initialization for hvm guests
There is no reasons why an HVM guest shouldn't be allowed to use xenfb. As a matter of fact ARM guests, HVM from Linux POV, can use xenfb. Given that no Xen toolstacks configure a xenfb backend for x86 HVM guests, they are not affected.
Please note that at this time QEMU needs few outstanding fixes to provide xenfb on ARM:
http://marc.info/?l=qemu-devel&m=138739419700837&w=2
"which is a lie. The "no Xen toolstacks configure a xenfb backend for x86 HVM" is actually a lie. If you try to boot this kernel under Xen with Xend it will be a problem - as Xend does setup an 'vfb' device.
Quoted 6 lines
Quoted 3 lines
The end result is that during the bootup - up until X starts, there is no console output on the VNC window. As the Linux kernel tries to use the vfb console driver.
This looks like a toolstack bug to me. If the toolstack has configured a vfb backend surely that should be preferred to the emulated VGA?
This is Xend. It is a bit brain dead in this category.
Quoted 6 lines
Quoted 3 lines
Any suggestsion on how to fix this? Should we just wrap the whole thing with #ifdef, like this?
No. We want to avoid frontend drivers behaving differently on different architectures.
Quoted 6 lines
Quoted 3 lines
We could try detecting that it is Xend (not sure how?) - or that it is Xen 4.4 or below - which would be the only versions that could be run with Xend.
That's even worse. Please just fix your toolstack to not create the vfb backend if you don't want to use it.
That is mighty hard from me looking at the code. Xend treats the 'vfb' as au dumping ground for VNC and VFB configurations - and it depends on them when an migration is progress.
I am afraid that Xend is still widespread enough that we need some way to deal with it.
The #idef hackery - while not a nice way can make this work.
Or we can add this in an header/function as a quirk.
boolean xen_pvfb_dont_init_quirk(void)
{
#ifdef CONFIG_X86
if (xen_running_on_version_or_later(4, 5) && xen_hvm_domain())
{
/* Do some XenStore keys to check if we might be running
a brain dead Xend. */
if (xen_keys_blah_blah(''))..
return true;
}
#else
return false;#endif
}
Quoted 2 lines
David
Quoted 56 lines · Konrad Rzeszutek Wilk
Quoted 41 lines · David Vrabel
Quoted 40 lines · Konrad Rzeszutek Wilk
Quoted 23 lines · David Vrabel
Quoted 22 lines · Konrad Rzeszutek Wilk
This has been in queue for some time.
In our kernels (UEK3) we had to revert said patch. The patch says:
" xen/fb: allow xenfb initialization for hvm guests
There is no reasons why an HVM guest shouldn't be allowed to use xenfb. As a matter of fact ARM guests, HVM from Linux POV, can use xenfb. Given that no Xen toolstacks configure a xenfb backend for x86 HVM guests, they are not affected.
Please note that at this time QEMU needs few outstanding fixes to provide xenfb on ARM:
http://marc.info/?l=qemu-devel&m=138739419700837&w=2
"which is a lie. The "no Xen toolstacks configure a xenfb backend for x86 HVM" is actually a lie. If you try to boot this kernel under Xen with Xend it will be a problem - as Xend does setup an 'vfb' device.
Quoted 6 lines
Quoted 3 lines
The end result is that during the bootup - up until X starts, there is no console output on the VNC window. As the Linux kernel tries to use the vfb console driver.
This looks like a toolstack bug to me. If the toolstack has configured a vfb backend surely that should be preferred to the emulated VGA?
This is Xend. It is a bit brain dead in this category.
Quoted 6 lines
Quoted 3 lines
Any suggestsion on how to fix this? Should we just wrap the whole thing with #ifdef, like this?
No. We want to avoid frontend drivers behaving differently on different architectures.
Quoted 6 lines
Quoted 3 lines
We could try detecting that it is Xend (not sure how?) - or that it is Xen 4.4 or below - which would be the only versions that could be run with Xend.
That's even worse. Please just fix your toolstack to not create the vfb backend if you don't want to use it.
That is mighty hard from me looking at the code. Xend treats the 'vfb' as au dumping ground for VNC and VFB configurations - and it depends on them when an migration is progress.
I am afraid that Xend is still widespread enough that we need some way to deal with it.
Quoted 7 lines
The #idef hackery - while not a nice way can make this work.
Or we can add this in an header/function as a quirk.
boolean
xen_pvfb_dont_init_quirk(void)
{
#ifdefCONFIG_X86
I would be OK with having such a quirk without the ifdef (no xend has been known to work on ARM anyway).
Quoted 1 line
if (xen_running_on_version_or_later(4, 5) && xen_hvm_domain())
Shouldn't this be xen_running_on_version_or_earlier(4, 4)? Xend has been removed in 4.5.
Quoted 11 lines
{ /* Do some XenStore keys to check if we might be running a brain dead Xend. */ if (xen_keys_blah_blah('')).. return true; } #else return false;#endif
}
Quoted 65 lines · Stefano Stabellini
Quoted 56 lines · Konrad Rzeszutek Wilk
Quoted 41 lines · David Vrabel
Quoted 40 lines · Konrad Rzeszutek Wilk
Quoted 23 lines · David Vrabel
Quoted 22 lines · Konrad Rzeszutek Wilk
This has been in queue for some time.
In our kernels (UEK3) we had to revert said patch. The patch says:
" xen/fb: allow xenfb initialization for hvm guests
There is no reasons why an HVM guest shouldn't be allowed to use xenfb. As a matter of fact ARM guests, HVM from Linux POV, can use xenfb. Given that no Xen toolstacks configure a xenfb backend for x86 HVM guests, they are not affected.
Please note that at this time QEMU needs few outstanding fixes to provide xenfb on ARM:
http://marc.info/?l=qemu-devel&m=138739419700837&w=2
"which is a lie. The "no Xen toolstacks configure a xenfb backend for x86 HVM" is actually a lie. If you try to boot this kernel under Xen with Xend it will be a problem - as Xend does setup an 'vfb' device.
Quoted 6 lines
Quoted 3 lines
The end result is that during the bootup - up until X starts, there is no console output on the VNC window. As the Linux kernel tries to use the vfb console driver.
This looks like a toolstack bug to me. If the toolstack has configured a vfb backend surely that should be preferred to the emulated VGA?
This is Xend. It is a bit brain dead in this category.
Quoted 6 lines
Quoted 3 lines
Any suggestsion on how to fix this? Should we just wrap the whole thing with #ifdef, like this?
No. We want to avoid frontend drivers behaving differently on different architectures.
Quoted 6 lines
Quoted 3 lines
We could try detecting that it is Xend (not sure how?) - or that it is Xen 4.4 or below - which would be the only versions that could be run with Xend.
That's even worse. Please just fix your toolstack to not create the vfb backend if you don't want to use it.
That is mighty hard from me looking at the code. Xend treats the 'vfb' as au dumping ground for VNC and VFB configurations - and it depends on them when an migration is progress.
I am afraid that Xend is still widespread enough that we need some way to deal with it.
Quoted 7 lines
The #idef hackery - while not a nice way can make this work.
Or we can add this in an header/function as a quirk.
boolean
xen_pvfb_dont_init_quirk(void)
{
#ifdefCONFIG_X86
Quoted 8 lines
I would be OK with having such a quirk without the ifdef (no xend has been known to work on ARM anyway).
Quoted 1 line
if (xen_running_on_version_or_later(4, 5) && xen_hvm_domain())Shouldn't this be
xen_running_on_version_or_earlier(4, 4)? Xend has been removed in 4.5.
This all sounds pretty gross, but if it is the way folks want to go, shouldn't it try and determine that it is running on xend somehow instead of guessing based on version number? 4.4 had xl in it too for instance...
Quoted 18 lines
Quoted 11 lines
{ /* Do some XenStore keys to check if we might be running a brain dead Xend. */ if (xen_keys_blah_blah('')).. return true; } #else return false;Quoted 2 lines
#endif
}_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel
Quoted 17 lines
Quoted 17 lines
Quoted 10 lines
I am afraid that Xend is still widespread enough that we need some way to deal with it.
The #idef hackery - while not a nice way can make this work.
Or we can add this in an header/function as a quirk.
boolean
xen_pvfb_dont_init_quirk(void)
{
#ifdefCONFIG_X86I would be OK with having such a quirk without the ifdef (no xend has been known to work on ARM anyway).
Quoted 1 line
if (xen_running_on_version_or_later(4, 5) && xen_hvm_domain())
Quoted 7 lines
Quoted 2 lines
Shouldn't this be
xen_running_on_version_or_earlier(4, 4)? Xend has been removed in 4.5.This all sounds pretty gross, but if it is the way folks want to go, shouldn't it try and determine that it is running on xend somehow instead of guessing based on version number? 4.4 had xl in it too for instance...
Right, so the secondary check would be to see if there is something extra that Xend puts in the XenStore. And it looks to always put 'protocol' in every device:
xm:
0 = ""
protocol = "x86_32-abi"
state = "1"
backend-id = "0"
backend = "/local/domain/0/backend/vfb/7/0"
While xl:
vfb = ""
0 = ""
backend = "/local/domain/0/backend/vfb/1/0"
backend-id = "0"
state = "1"
Quoted 20 lines · Konrad Rzeszutek Wilk
Quoted 20 lines
Quoted 19 lines
Quoted 10 lines
I am afraid that Xend is still widespread enough that we need some way to deal with it.
The #idef hackery - while not a nice way can make this work.
Or we can add this in an header/function as a quirk.
boolean
xen_pvfb_dont_init_quirk(void)
{
#ifdefCONFIG_X86I would be OK with having such a quirk without the ifdef (no xend has been known to work on ARM anyway).
Quoted 1 line
if (xen_running_on_version_or_later(4, 5) && xen_hvm_domain())Shouldn't this be
xen_running_on_version_or_earlier(4, 4)? Xend has been removed in 4.5.
Quoted 8 lines
Quoted 4 lines
This all sounds pretty gross, but if it is the way folks want to go, shouldn't it try and determine that it is running on xend somehow instead of guessing based on version number? 4.4 had xl in it too for instance...
Right, so the secondary check would be to see if there is something extra that Xend puts in the XenStore. And it looks to always put 'protocol' in every device:
protocol is also written by guest kernels, and I wouldn't be surprised if libxl or other toolstakcs write it on oocasion too. So I'm afraid that particualr key is not suitable/
Quoted 20 lines
xm:
0 = ""
protocol = "x86_32-abi"
state = "1"
backend-id = "0"
backend = "/local/domain/0/backend/vfb/7/0"While xl:
vfb = ""
0 = ""
backend = "/local/domain/0/backend/vfb/1/0"
backend-id = "0"
state = "1"_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel