Hi Attilio I have updated to the upstream Xen and try to boot into OVMF bios. Instead of fetching the OVMF code from the git mirror, I just copy the OVMF bios to ovmf directory. I use the bios="ovmf" in the HVM config file. But, there is an error when I create the domain. root@gavin-laptop:~# xl create hvm_ubuntu.hvm Parsing config file /root/hvm_ubuntu.hvm WARNING: specifying "tsc_mode" as an integer is deprecated. Please use the named parameter variant. e.g. tsc_mode="default" failed to free memory for the domain So, do you have any ideas about this problem? Thank you very much. Best Regards, Bei Guan _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel
On 21/03/12 15:36, Bei Guan wrote:> Hi Attilio > > I have updated to the upstream Xen and try to boot into OVMF bios. > Instead of fetching the OVMF code from the git mirror, I just copy > the OVMF bios to ovmf directory. > I use the bios="ovmf" in the HVM config file. But, there is an error > when I create the domain. > > root@gavin-laptop:~# xl create hvm_ubuntu.hvm > Parsing config file /root/hvm_ubuntu.hvm > WARNING: specifying "tsc_mode" as an integer is deprecated. Please use > the named parameter variant. e.g. tsc_mode="default" > failed to free memory for the domain >Really not, can you try to build the ovmf from the mirror please? Attilio _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel
2012/3/22 Attilio Rao <attilio.rao@citrix.com>> ** > On 21/03/12 15:36, Bei Guan wrote: > > Hi Attilio > > I have updated to the upstream Xen and try to boot into OVMF bios. > Instead of fetching the OVMF code from the git mirror, I just copy the > OVMF bios to ovmf directory. > I use the bios="ovmf" in the HVM config file. But, there is an error when > I create the domain. > > root@gavin-laptop:~# xl create hvm_ubuntu.hvm > Parsing config file /root/hvm_ubuntu.hvm > WARNING: specifying "tsc_mode" as an integer is deprecated. Please use the > named parameter variant. e.g. tsc_mode="default" > failed to free memory for the domain > > > Really not, can you try to build the ovmf from the mirror please? >I just used your latest patch "[PATCH v4] Fetch the OVMF repository from specific git mirror and enable it", and compiled the firmware successfully. It''s OK for me now. I can get the right OVMF bios in tools/firmware/ovmf. I provide my environment. It''s Ubuntu 10.04 and X86_64 bit kernel. However, I still cannot not boot into the OVMF bios. The error is the same as the above. Could anyone tell me how this error "failed to free memory for the domain" came about? Thanks.> > > Attilio >-- Best Regards, Bei Guan _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel
Hi, I trace the code and there seems to be something error in the function libxl__domain_build_info_setdefault() in libxl_create.c. int libxl__domain_build_info_setdefault(libxl__gc *gc, libxl_domain_build_info *b_info) { ... if (b_info->type == LIBXL_DOMAIN_TYPE_HVM) { if (!b_info->u.hvm.bios) switch (b_info->device_model_version) { case 1: b_info->u.hvm.bios = LIBXL_BIOS_TYPE_ROMBIOS; break; case 2: b_info->u.hvm.bios = LIBXL_BIOS_TYPE_SEABIOS; break; default:return ERROR_INVAL; } /* Enforce BIOS<->Device Model version relationship */ switch (b_info->device_model_version) { case 1: if (b_info->u.hvm.bios != LIBXL_BIOS_TYPE_ROMBIOS) return ERROR_INVAL; break; case 2: if (b_info->u.hvm.bios == LIBXL_BIOS_TYPE_ROMBIOS) return ERROR_INVAL; break; default:abort(); } } Note the red part of the code above. If we set the option bios="ovmf" in HVM config file, the vale of b_info->u.hvm.bios is 3. And the variable LIBXL_BIOS_TYPE_ROMBIOS is always 1. So, in the xl_cmdimpl.c, we get the error "failed to free memory for the domain". Maybe this error will also happen when we boot into the Seabios. Please correct me if possible. Thank you very much. Bei Guan 2012/3/22 Attilio Rao <attilio.rao@citrix.com>> ** > On 21/03/12 15:36, Bei Guan wrote: > > Hi Attilio > > I have updated to the upstream Xen and try to boot into OVMF bios. > Instead of fetching the OVMF code from the git mirror, I just copy the > OVMF bios to ovmf directory. > I use the bios="ovmf" in the HVM config file. But, there is an error when > I create the domain. > > root@gavin-laptop:~# xl create hvm_ubuntu.hvm > Parsing config file /root/hvm_ubuntu.hvm > WARNING: specifying "tsc_mode" as an integer is deprecated. Please use the > named parameter variant. e.g. tsc_mode="default" > failed to free memory for the domain > > > Really not, can you try to build the ovmf from the mirror please? > > Attilio >-- Best Regards, Bei Guan _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel
On Thu, 2012-03-22 at 05:21 +0000, Bei Guan wrote:> Hi, > > > I trace the code and there seems to be something error in the > function libxl__domain_build_info_setdefault() in libxl_create.c. > > > int libxl__domain_build_info_setdefault(libxl__gc *gc, > libxl_domain_build_info > *b_info) > { > ... > > > if (b_info->type == LIBXL_DOMAIN_TYPE_HVM) { > if (!b_info->u.hvm.bios) > switch (b_info->device_model_version) { > case 1: b_info->u.hvm.bios = LIBXL_BIOS_TYPE_ROMBIOS; > break; > case 2: b_info->u.hvm.bios = LIBXL_BIOS_TYPE_SEABIOS; > break; > default:return ERROR_INVAL; > } > > > /* Enforce BIOS<->Device Model version relationship */ > switch (b_info->device_model_version) { > case 1: > if (b_info->u.hvm.bios != LIBXL_BIOS_TYPE_ROMBIOS) > return ERROR_INVAL; > break; > case 2: > if (b_info->u.hvm.bios == LIBXL_BIOS_TYPE_ROMBIOS) > return ERROR_INVAL; > break; > default:abort(); > } > } > > > Note the red part of the code above. If we set the option bios="ovmf" > in HVM config file, the vale of b_info->u.hvm.bios is 3. And the > variable LIBXL_BIOS_TYPE_ROMBIOS is always 1.OVMF and SeaBIOS are only going to be supported with upstream qemu and ROMBIOS will only be supported with the traditional qemu tree. Naughty of me to use the bare numbers there, I should have used the enum names. Will send out a patch.> So, in the xl_cmdimpl.c, we get the error "failed to free memory for > the domain". Maybe this error will also happen when we boot into the > Seabios.This sounds like bad error handling in xl to me. Ian.> > > Please correct me if possible. Thank you very much. > > > > > Bei Guan > > > 2012/3/22 Attilio Rao <attilio.rao@citrix.com> > On 21/03/12 15:36, Bei Guan wrote: > > Hi Attilio > > > > > > I have updated to the upstream Xen and try to boot into OVMF > > bios. Instead of fetching the OVMF code from the git > > mirror, I just copy the OVMF bios to ovmf directory. > > I use the bios="ovmf" in the HVM config file. But, there is > > an error when I create the domain. > > > > > > root@gavin-laptop:~# xl create hvm_ubuntu.hvm > > Parsing config file /root/hvm_ubuntu.hvm > > WARNING: specifying "tsc_mode" as an integer is deprecated. > > Please use the named parameter variant. e.g. > > tsc_mode="default" > > failed to free memory for the domain > > > > > > > Really not, can you try to build the ovmf from the mirror > please? > > Attilio > > > > > > -- > Best Regards, > Bei Guan >
Seemingly Similar Threads
- [PATCH] Allow 4 MB of video RAM for Cirrus graphics on traditional QEMU
- [PATCH] libxl: fix rtc_timeoffset setting
- [PATCH v4] tools/libxl: Improve videoram setting
- xl doesn't honour the parameter cpu_weight from my config file while xm does honour it
- xl doesn't honour the parameter cpu_weight from my config file while xm does honour it