Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
libvirt
提交
a82bd078
L
libvirt
项目概览
openeuler
/
libvirt
通知
3
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
L
libvirt
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
a82bd078
编写于
9月 09, 2008
作者:
C
Cole Robinson
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Fix reading vncdisplay from xend, add several test cases for xen vnc corner case
s.
上级
bf3e2132
变更
13
隐藏空白更改
内联
并排
Showing
13 changed file
with
175 addition
and
1 deletion
+175
-1
ChangeLog
ChangeLog
+13
-0
src/xend_internal.c
src/xend_internal.c
+10
-1
tests/sexpr2xmldata/sexpr2xml-pv-vfb-new-vncdisplay.sexpr
tests/sexpr2xmldata/sexpr2xml-pv-vfb-new-vncdisplay.sexpr
+2
-0
tests/sexpr2xmldata/sexpr2xml-pv-vfb-new-vncdisplay.xml
tests/sexpr2xmldata/sexpr2xml-pv-vfb-new-vncdisplay.xml
+29
-0
tests/sexpr2xmltest.c
tests/sexpr2xmltest.c
+1
-0
tests/xmconfigdata/test-paravirt-new-pvfb-vncdisplay.cfg
tests/xmconfigdata/test-paravirt-new-pvfb-vncdisplay.cfg
+12
-0
tests/xmconfigdata/test-paravirt-new-pvfb-vncdisplay.xml
tests/xmconfigdata/test-paravirt-new-pvfb-vncdisplay.xml
+32
-0
tests/xmconfigdata/test-paravirt-old-pvfb-vncdisplay.cfg
tests/xmconfigdata/test-paravirt-old-pvfb-vncdisplay.cfg
+17
-0
tests/xmconfigdata/test-paravirt-old-pvfb-vncdisplay.xml
tests/xmconfigdata/test-paravirt-old-pvfb-vncdisplay.xml
+32
-0
tests/xmconfigtest.c
tests/xmconfigtest.c
+2
-0
tests/xml2sexprdata/xml2sexpr-pv-vfb-new-auto.sexpr
tests/xml2sexprdata/xml2sexpr-pv-vfb-new-auto.sexpr
+1
-0
tests/xml2sexprdata/xml2sexpr-pv-vfb-new-auto.xml
tests/xml2sexprdata/xml2sexpr-pv-vfb-new-auto.xml
+23
-0
tests/xml2sexprtest.c
tests/xml2sexprtest.c
+1
-0
未找到文件。
ChangeLog
浏览文件 @
a82bd078
Tue Sep 9 09:50:00 EST 2008 Cole Robinson <crobinso@redhat.com>
* src/xend_internal.c: fix reading vncdisplay from xend domain
* tests/sexpr2xmldata/sexpr2xml-pv-vfb-new-vncdisplay.sexpr
tests/sexpr2xmldata/sexpr2xml-pv-vfb-new-vncdisplay.xml,
tests/xmconfigdata/test-paravirt-new-pvfb-vncdisplay.cfg,
tests/xmconfigdata/test-paravirt-new-pvfb-vncdisplay.xml,
tests/xmconfigdata/test-paravirt-old-pvfb-vncdisplay.cfg,
tests/xmconfigdata/test-paravirt-old-pvfb-vncdisplay.xml,
tests/xml2sexprdata/xml2sexpr-pv-vfb-new-auto.sexpr,
tests/xml2sexprdata/xml2sexpr-pv-vfb-new-auto.xml:
Add tests for various xen vnc cases.
Tue Sep 9 09:42:00 EST 2008 Cole Robinson <crobinso@redhat.com>
Tue Sep 9 09:42:00 EST 2008 Cole Robinson <crobinso@redhat.com>
* src/qemu_conf.c : fix a segfault if no qemu emulator is passed
* src/qemu_conf.c : fix a segfault if no qemu emulator is passed
...
...
src/xend_internal.c
浏览文件 @
a82bd078
...
@@ -2121,13 +2121,22 @@ xenDaemonParseSxprGraphicsNew(virConnectPtr conn,
...
@@ -2121,13 +2121,22 @@ xenDaemonParseSxprGraphicsNew(virConnectPtr conn,
goto
no_memory
;
goto
no_memory
;
}
else
{
}
else
{
int
port
=
xenStoreDomainGetVNCPort
(
conn
,
def
->
id
);
int
port
=
xenStoreDomainGetVNCPort
(
conn
,
def
->
id
);
if
(
port
==
-
1
)
{
// Didn't find port entry in xenstore
port
=
sexpr_int
(
node
,
"device/vfb/vncdisplay"
);
}
const
char
*
listenAddr
=
sexpr_node
(
node
,
"device/vfb/vnclisten"
);
const
char
*
listenAddr
=
sexpr_node
(
node
,
"device/vfb/vnclisten"
);
const
char
*
vncPasswd
=
sexpr_node
(
node
,
"device/vfb/vncpasswd"
);;
const
char
*
vncPasswd
=
sexpr_node
(
node
,
"device/vfb/vncpasswd"
);;
const
char
*
keymap
=
sexpr_node
(
node
,
"device/vfb/keymap"
);
const
char
*
keymap
=
sexpr_node
(
node
,
"device/vfb/keymap"
);
const
char
*
unused
=
sexpr_node
(
node
,
"device/vfb/vncunused"
);
const
char
*
unused
=
sexpr_node
(
node
,
"device/vfb/vncunused"
);
if
((
unused
&&
STREQ
(
unused
,
"1"
))
||
port
==
-
1
)
if
((
unused
&&
STREQ
(
unused
,
"1"
))
||
port
==
-
1
)
{
graphics
->
data
.
vnc
.
autoport
=
1
;
graphics
->
data
.
vnc
.
autoport
=
1
;
port
=
-
1
;
}
if
(
port
>=
0
&&
port
<
5900
)
port
+=
5900
;
graphics
->
data
.
vnc
.
port
=
port
;
graphics
->
data
.
vnc
.
port
=
port
;
if
(
listenAddr
&&
if
(
listenAddr
&&
...
...
tests/sexpr2xmldata/sexpr2xml-pv-vfb-new-vncdisplay.sexpr
0 → 100644
浏览文件 @
a82bd078
(domain (domid 6)(name 'pvtest')(memory 420)(maxmem 420)(vcpus 2)(uuid '596a5d2171f48fb2e068e2386a5c413e')(on_poweroff 'destroy')(on_reboot 'destroy')(on_crash 'destroy')(image (linux (kernel '/var/lib/xen/vmlinuz.2Dn2YT')(ramdisk '/var/lib/xen/initrd.img.0u-Vhq')(args ' method=http://download.fedora.devel.redhat.com/pub/fedora/linux/core/test/5.91/x86_64/os ')))(device (vbd (dev 'xvda')(uname 'file:/root/some.img')(mode 'w')))(device (vfb (type vnc)(vncunused 0)(vnclisten 0.0.0.0)(vncpasswd 123456)(keymap ja)(vncdisplay 25)))))
tests/sexpr2xmldata/sexpr2xml-pv-vfb-new-vncdisplay.xml
0 → 100644
浏览文件 @
a82bd078
<domain
type=
'xen'
id=
'6'
>
<name>
pvtest
</name>
<uuid>
596a5d21-71f4-8fb2-e068-e2386a5c413e
</uuid>
<memory>
430080
</memory>
<currentMemory>
430080
</currentMemory>
<vcpu>
2
</vcpu>
<os>
<type>
linux
</type>
<kernel>
/var/lib/xen/vmlinuz.2Dn2YT
</kernel>
<initrd>
/var/lib/xen/initrd.img.0u-Vhq
</initrd>
<cmdline>
method=http://download.fedora.devel.redhat.com/pub/fedora/linux/core/test/5.91/x86_64/os
</cmdline>
</os>
<clock
offset=
'utc'
/>
<on_poweroff>
destroy
</on_poweroff>
<on_reboot>
destroy
</on_reboot>
<on_crash>
destroy
</on_crash>
<devices>
<disk
type=
'file'
device=
'disk'
>
<driver
name=
'file'
/>
<source
file=
'/root/some.img'
/>
<target
dev=
'xvda'
bus=
'xen'
/>
</disk>
<console
type=
'pty'
>
<target
port=
'0'
/>
</console>
<input
type=
'mouse'
bus=
'xen'
/>
<graphics
type=
'vnc'
port=
'5925'
autoport=
'no'
listen=
'0.0.0.0'
keymap=
'ja'
/>
</devices>
</domain>
tests/sexpr2xmltest.c
浏览文件 @
a82bd078
...
@@ -106,6 +106,7 @@ mymain(int argc, char **argv)
...
@@ -106,6 +106,7 @@ mymain(int argc, char **argv)
DO_TEST
(
"fv-v2"
,
"fv-v2"
,
2
);
DO_TEST
(
"fv-v2"
,
"fv-v2"
,
2
);
DO_TEST
(
"pv-vfb-orig"
,
"pv-vfb-orig"
,
2
);
DO_TEST
(
"pv-vfb-orig"
,
"pv-vfb-orig"
,
2
);
DO_TEST
(
"pv-vfb-new"
,
"pv-vfb-new"
,
3
);
DO_TEST
(
"pv-vfb-new"
,
"pv-vfb-new"
,
3
);
DO_TEST
(
"pv-vfb-new-vncdisplay"
,
"pv-vfb-new-vncdisplay"
,
3
);
DO_TEST
(
"pv-bootloader"
,
"pv-bootloader"
,
1
);
DO_TEST
(
"pv-bootloader"
,
"pv-bootloader"
,
1
);
DO_TEST
(
"disk-file"
,
"disk-file"
,
2
);
DO_TEST
(
"disk-file"
,
"disk-file"
,
2
);
...
...
tests/xmconfigdata/test-paravirt-new-pvfb-vncdisplay.cfg
0 → 100644
浏览文件 @
a82bd078
name = "XenGuest1"
uuid = "c7a5fdb0-cdaf-9455-926a-d65c16db1809"
maxmem = 579
memory = 394
vcpus = 1
bootloader = "/usr/bin/pygrub"
on_poweroff = "destroy"
on_reboot = "restart"
on_crash = "restart"
vfb = [ "type=vnc,vncunused=0,vncdisplay=25,vnclisten=127.0.0.1,vncpasswd=123poi" ]
disk = [ "phy:/dev/HostVG/XenGuest1,xvda,w" ]
vif = [ "mac=00:16:3e:66:94:9c,bridge=br0" ]
tests/xmconfigdata/test-paravirt-new-pvfb-vncdisplay.xml
0 → 100644
浏览文件 @
a82bd078
<domain
type=
'xen'
>
<name>
XenGuest1
</name>
<uuid>
c7a5fdb0-cdaf-9455-926a-d65c16db1809
</uuid>
<memory>
592896
</memory>
<currentMemory>
403456
</currentMemory>
<vcpu>
1
</vcpu>
<bootloader>
/usr/bin/pygrub
</bootloader>
<os>
<type
arch=
'i686'
machine=
'xenpv'
>
linux
</type>
</os>
<clock
offset=
'utc'
/>
<on_poweroff>
destroy
</on_poweroff>
<on_reboot>
restart
</on_reboot>
<on_crash>
restart
</on_crash>
<devices>
<emulator>
/usr/lib/xen/bin/qemu-dm
</emulator>
<disk
type=
'block'
device=
'disk'
>
<driver
name=
'phy'
/>
<source
dev=
'/dev/HostVG/XenGuest1'
/>
<target
dev=
'xvda'
bus=
'xen'
/>
</disk>
<interface
type=
'bridge'
>
<mac
address=
'00:16:3e:66:94:9c'
/>
<source
bridge=
'br0'
/>
</interface>
<console
type=
'pty'
>
<target
port=
'0'
/>
</console>
<input
type=
'mouse'
bus=
'xen'
/>
<graphics
type=
'vnc'
port=
'5925'
autoport=
'no'
listen=
'127.0.0.1'
passwd=
'123poi'
/>
</devices>
</domain>
tests/xmconfigdata/test-paravirt-old-pvfb-vncdisplay.cfg
0 → 100644
浏览文件 @
a82bd078
name = "XenGuest1"
uuid = "c7a5fdb0-cdaf-9455-926a-d65c16db1809"
maxmem = 579
memory = 394
vcpus = 1
bootloader = "/usr/bin/pygrub"
on_poweroff = "destroy"
on_reboot = "restart"
on_crash = "restart"
sdl = 0
vnc = 1
vncunused = 0
vncdisplay = 25
vnclisten = "127.0.0.1"
vncpasswd = "123poi"
disk = [ "phy:/dev/HostVG/XenGuest1,xvda,w" ]
vif = [ "mac=00:16:3e:66:94:9c,bridge=br0" ]
tests/xmconfigdata/test-paravirt-old-pvfb-vncdisplay.xml
0 → 100644
浏览文件 @
a82bd078
<domain
type=
'xen'
>
<name>
XenGuest1
</name>
<uuid>
c7a5fdb0-cdaf-9455-926a-d65c16db1809
</uuid>
<memory>
592896
</memory>
<currentMemory>
403456
</currentMemory>
<vcpu>
1
</vcpu>
<bootloader>
/usr/bin/pygrub
</bootloader>
<os>
<type
arch=
'i686'
machine=
'xenpv'
>
linux
</type>
</os>
<clock
offset=
'utc'
/>
<on_poweroff>
destroy
</on_poweroff>
<on_reboot>
restart
</on_reboot>
<on_crash>
restart
</on_crash>
<devices>
<emulator>
/usr/lib/xen/bin/qemu-dm
</emulator>
<disk
type=
'block'
device=
'disk'
>
<driver
name=
'phy'
/>
<source
dev=
'/dev/HostVG/XenGuest1'
/>
<target
dev=
'xvda'
bus=
'xen'
/>
</disk>
<interface
type=
'bridge'
>
<mac
address=
'00:16:3e:66:94:9c'
/>
<source
bridge=
'br0'
/>
</interface>
<console
type=
'pty'
>
<target
port=
'0'
/>
</console>
<input
type=
'mouse'
bus=
'xen'
/>
<graphics
type=
'vnc'
port=
'5925'
autoport=
'no'
listen=
'127.0.0.1'
passwd=
'123poi'
/>
</devices>
</domain>
tests/xmconfigtest.c
浏览文件 @
a82bd078
...
@@ -215,7 +215,9 @@ mymain(int argc, char **argv)
...
@@ -215,7 +215,9 @@ mymain(int argc, char **argv)
} while (0)
} while (0)
DO_TEST
(
"paravirt-old-pvfb"
,
2
);
DO_TEST
(
"paravirt-old-pvfb"
,
2
);
DO_TEST
(
"paravirt-old-pvfb-vncdisplay"
,
2
);
DO_TEST
(
"paravirt-new-pvfb"
,
3
);
DO_TEST
(
"paravirt-new-pvfb"
,
3
);
DO_TEST
(
"paravirt-new-pvfb-vncdisplay"
,
3
);
DO_TEST
(
"paravirt-net-e1000"
,
3
);
DO_TEST
(
"paravirt-net-e1000"
,
3
);
DO_TEST
(
"fullvirt-old-cdrom"
,
1
);
DO_TEST
(
"fullvirt-old-cdrom"
,
1
);
DO_TEST
(
"fullvirt-new-cdrom"
,
2
);
DO_TEST
(
"fullvirt-new-cdrom"
,
2
);
...
...
tests/xml2sexprdata/xml2sexpr-pv-vfb-new-auto.sexpr
0 → 100644
浏览文件 @
a82bd078
(vm (name 'pvtest')(memory 420)(maxmem 420)(vcpus 2)(uuid '596a5d21-71f4-8fb2-e068-e2386a5c413e')(on_poweroff 'destroy')(on_reboot 'destroy')(on_crash 'destroy')(image (linux (kernel '/var/lib/xen/vmlinuz.2Dn2YT')(ramdisk '/var/lib/xen/initrd.img.0u-Vhq')(args ' method=http://download.fedora.devel.redhat.com/pub/fedora/linux/core/test/5.91/x86_64/os ')(device_model '/usr/lib/xen/bin/qemu-dm')))(device (vbd (dev 'xvda')(uname 'file:/root/some.img')(mode 'w')))(device (vkbd))(device (vfb (type vnc)(vncunused 1)(vnclisten '127.0.0.1')(vncpasswd '123456')(keymap 'ja'))))
\ No newline at end of file
tests/xml2sexprdata/xml2sexpr-pv-vfb-new-auto.xml
0 → 100644
浏览文件 @
a82bd078
<domain
type=
'xen'
id=
'6'
>
<name>
pvtest
</name>
<uuid>
596a5d2171f48fb2e068e2386a5c413e
</uuid>
<os>
<type>
linux
</type>
<kernel>
/var/lib/xen/vmlinuz.2Dn2YT
</kernel>
<initrd>
/var/lib/xen/initrd.img.0u-Vhq
</initrd>
<cmdline>
method=http://download.fedora.devel.redhat.com/pub/fedora/linux/core/test/5.91/x86_64/os
</cmdline>
</os>
<memory>
430080
</memory>
<vcpu>
2
</vcpu>
<on_poweroff>
destroy
</on_poweroff>
<on_reboot>
destroy
</on_reboot>
<on_crash>
destroy
</on_crash>
<devices>
<disk
type=
'file'
device=
'disk'
>
<driver
name=
'file'
/>
<source
file=
'/root/some.img'
/>
<target
dev=
'xvda'
/>
</disk>
<graphics
type=
'vnc'
port=
'-1'
autoport=
'yes'
listen=
"127.0.0.1"
passwd=
"123456"
keymap=
"ja"
/>
</devices>
</domain>
tests/xml2sexprtest.c
浏览文件 @
a82bd078
...
@@ -111,6 +111,7 @@ mymain(int argc, char **argv)
...
@@ -111,6 +111,7 @@ mymain(int argc, char **argv)
DO_TEST
(
"fv-vncunused"
,
"fv-vncunused"
,
"fvtest"
,
2
);
DO_TEST
(
"fv-vncunused"
,
"fv-vncunused"
,
"fvtest"
,
2
);
DO_TEST
(
"pv-vfb-orig"
,
"pv-vfb-orig"
,
"pvtest"
,
2
);
DO_TEST
(
"pv-vfb-orig"
,
"pv-vfb-orig"
,
"pvtest"
,
2
);
DO_TEST
(
"pv-vfb-new"
,
"pv-vfb-new"
,
"pvtest"
,
3
);
DO_TEST
(
"pv-vfb-new"
,
"pv-vfb-new"
,
"pvtest"
,
3
);
DO_TEST
(
"pv-vfb-new-auto"
,
"pv-vfb-new-auto"
,
"pvtest"
,
3
);
DO_TEST
(
"pv-bootloader"
,
"pv-bootloader"
,
"pvtest"
,
1
);
DO_TEST
(
"pv-bootloader"
,
"pv-bootloader"
,
"pvtest"
,
1
);
DO_TEST
(
"disk-file"
,
"disk-file"
,
"pvtest"
,
2
);
DO_TEST
(
"disk-file"
,
"disk-file"
,
"pvtest"
,
2
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录