Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
qemu
提交
27143a44
Q
qemu
项目概览
openeuler
/
qemu
通知
10
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
Q
qemu
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
27143a44
编写于
8月 15, 2011
作者:
A
Anthony Liguori
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
char: rename qemu_chr_open() -> qemu_chr_new()
Signed-off-by:
N
Anthony Liguori
<
aliguori@us.ibm.com
>
上级
15f31519
变更
10
隐藏空白更改
内联
并排
Showing
10 changed file
with
18 addition
and
18 deletion
+18
-18
gdbstub.c
gdbstub.c
+1
-1
hw/mips_malta.c
hw/mips_malta.c
+2
-2
hw/omap2.c
hw/omap2.c
+1
-1
hw/omap_uart.c
hw/omap_uart.c
+4
-4
hw/usb-serial.c
hw/usb-serial.c
+2
-2
hw/xen_console.c
hw/xen_console.c
+1
-1
net/slirp.c
net/slirp.c
+1
-1
qemu-char.c
qemu-char.c
+1
-1
qemu-char.h
qemu-char.h
+1
-1
vl.c
vl.c
+4
-4
未找到文件。
gdbstub.c
浏览文件 @
27143a44
...
...
@@ -2764,7 +2764,7 @@ int gdbserver_start(const char *device)
sigaction
(
SIGINT
,
&
act
,
NULL
);
}
#endif
chr
=
qemu_chr_
open
(
"gdb"
,
device
,
NULL
);
chr
=
qemu_chr_
new
(
"gdb"
,
device
,
NULL
);
if
(
!
chr
)
return
-
1
;
...
...
hw/mips_malta.c
浏览文件 @
27143a44
...
...
@@ -443,7 +443,7 @@ static MaltaFPGAState *malta_fpga_init(target_phys_addr_t base, qemu_irq uart_ir
/* 0xa00 is less than a page, so will still get the right offsets. */
cpu_register_physical_memory
(
base
+
0xa00
,
0x100000
-
0xa00
,
malta
);
s
->
display
=
qemu_chr_
open
(
"fpga"
,
"vc:320x200"
,
malta_fpga_led_init
);
s
->
display
=
qemu_chr_
new
(
"fpga"
,
"vc:320x200"
,
malta_fpga_led_init
);
#ifdef TARGET_WORDS_BIGENDIAN
s
->
uart
=
serial_mm_init
(
base
+
0x900
,
3
,
uart_irq
,
230400
,
uart_chr
,
1
,
1
);
...
...
@@ -784,7 +784,7 @@ void mips_malta_init (ram_addr_t ram_size,
if
(
!
serial_hds
[
i
])
{
char
label
[
32
];
snprintf
(
label
,
sizeof
(
label
),
"serial%d"
,
i
);
serial_hds
[
i
]
=
qemu_chr_
open
(
label
,
"null"
,
NULL
);
serial_hds
[
i
]
=
qemu_chr_
new
(
label
,
"null"
,
NULL
);
}
}
...
...
hw/omap2.c
浏览文件 @
27143a44
...
...
@@ -782,7 +782,7 @@ static struct omap_sti_s *omap_sti_init(struct omap_target_agent_s *ta,
s
->
irq
=
irq
;
omap_sti_reset
(
s
);
s
->
chr
=
chr
?:
qemu_chr_
open
(
"null"
,
"null"
,
NULL
);
s
->
chr
=
chr
?:
qemu_chr_
new
(
"null"
,
"null"
,
NULL
);
iomemtype
=
l4_register_io_memory
(
omap_sti_readfn
,
omap_sti_writefn
,
s
);
...
...
hw/omap_uart.c
浏览文件 @
27143a44
...
...
@@ -62,11 +62,11 @@ struct omap_uart_s *omap_uart_init(target_phys_addr_t base,
s
->
irq
=
irq
;
#ifdef TARGET_WORDS_BIGENDIAN
s
->
serial
=
serial_mm_init
(
base
,
2
,
irq
,
omap_clk_getrate
(
fclk
)
/
16
,
chr
?:
qemu_chr_
open
(
label
,
"null"
,
NULL
),
1
,
chr
?:
qemu_chr_
new
(
label
,
"null"
,
NULL
),
1
,
1
);
#else
s
->
serial
=
serial_mm_init
(
base
,
2
,
irq
,
omap_clk_getrate
(
fclk
)
/
16
,
chr
?:
qemu_chr_
open
(
label
,
"null"
,
NULL
),
1
,
chr
?:
qemu_chr_
new
(
label
,
"null"
,
NULL
),
1
,
0
);
#endif
return
s
;
...
...
@@ -185,12 +185,12 @@ void omap_uart_attach(struct omap_uart_s *s, CharDriverState *chr)
#ifdef TARGET_WORDS_BIGENDIAN
s
->
serial
=
serial_mm_init
(
s
->
base
,
2
,
s
->
irq
,
omap_clk_getrate
(
s
->
fclk
)
/
16
,
chr
?:
qemu_chr_
open
(
"null"
,
"null"
,
NULL
),
1
,
chr
?:
qemu_chr_
new
(
"null"
,
"null"
,
NULL
),
1
,
1
);
#else
s
->
serial
=
serial_mm_init
(
s
->
base
,
2
,
s
->
irq
,
omap_clk_getrate
(
s
->
fclk
)
/
16
,
chr
?:
qemu_chr_
open
(
"null"
,
"null"
,
NULL
),
1
,
chr
?:
qemu_chr_
new
(
"null"
,
"null"
,
NULL
),
1
,
0
);
#endif
}
hw/usb-serial.c
浏览文件 @
27143a44
...
...
@@ -538,7 +538,7 @@ static USBDevice *usb_serial_init(const char *filename)
filename
++
;
snprintf
(
label
,
sizeof
(
label
),
"usbserial%d"
,
index
++
);
cdrv
=
qemu_chr_
open
(
label
,
filename
,
NULL
);
cdrv
=
qemu_chr_
new
(
label
,
filename
,
NULL
);
if
(
!
cdrv
)
return
NULL
;
...
...
@@ -561,7 +561,7 @@ static USBDevice *usb_braille_init(const char *unused)
USBDevice
*
dev
;
CharDriverState
*
cdrv
;
cdrv
=
qemu_chr_
open
(
"braille"
,
"braille"
,
NULL
);
cdrv
=
qemu_chr_
new
(
"braille"
,
"braille"
,
NULL
);
if
(
!
cdrv
)
return
NULL
;
...
...
hw/xen_console.c
浏览文件 @
27143a44
...
...
@@ -202,7 +202,7 @@ static int con_init(struct XenDevice *xendev)
con
->
chr
=
serial_hds
[
con
->
xendev
.
dev
];
}
else
{
snprintf
(
label
,
sizeof
(
label
),
"xencons%d"
,
con
->
xendev
.
dev
);
con
->
chr
=
qemu_chr_
open
(
label
,
output
,
NULL
);
con
->
chr
=
qemu_chr_
new
(
label
,
output
,
NULL
);
}
xenstore_store_pv_console_info
(
con
->
xendev
.
dev
,
con
->
chr
);
...
...
net/slirp.c
浏览文件 @
27143a44
...
...
@@ -616,7 +616,7 @@ static int slirp_guestfwd(SlirpState *s, const char *config_str,
fwd
=
g_malloc
(
sizeof
(
struct
GuestFwd
));
snprintf
(
buf
,
sizeof
(
buf
),
"guestfwd.tcp.%d"
,
port
);
fwd
->
hd
=
qemu_chr_
open
(
buf
,
p
,
NULL
);
fwd
->
hd
=
qemu_chr_
new
(
buf
,
p
,
NULL
);
if
(
!
fwd
->
hd
)
{
error_report
(
"could not open guest forwarding device '%s'"
,
buf
);
g_free
(
fwd
);
...
...
qemu-char.c
浏览文件 @
27143a44
...
...
@@ -2603,7 +2603,7 @@ CharDriverState *qemu_chr_open_opts(QemuOpts *opts,
return
chr
;
}
CharDriverState
*
qemu_chr_
open
(
const
char
*
label
,
const
char
*
filename
,
void
(
*
init
)(
struct
CharDriverState
*
s
))
CharDriverState
*
qemu_chr_
new
(
const
char
*
label
,
const
char
*
filename
,
void
(
*
init
)(
struct
CharDriverState
*
s
))
{
const
char
*
p
;
CharDriverState
*
chr
;
...
...
qemu-char.h
浏览文件 @
27143a44
...
...
@@ -80,7 +80,7 @@ struct CharDriverState {
QemuOpts
*
qemu_chr_parse_compat
(
const
char
*
label
,
const
char
*
filename
);
CharDriverState
*
qemu_chr_open_opts
(
QemuOpts
*
opts
,
void
(
*
init
)(
struct
CharDriverState
*
s
));
CharDriverState
*
qemu_chr_
open
(
const
char
*
label
,
const
char
*
filename
,
void
(
*
init
)(
struct
CharDriverState
*
s
));
CharDriverState
*
qemu_chr_
new
(
const
char
*
label
,
const
char
*
filename
,
void
(
*
init
)(
struct
CharDriverState
*
s
));
void
qemu_chr_fe_set_echo
(
struct
CharDriverState
*
chr
,
bool
echo
);
void
qemu_chr_fe_open
(
struct
CharDriverState
*
chr
);
void
qemu_chr_fe_close
(
struct
CharDriverState
*
chr
);
...
...
vl.c
浏览文件 @
27143a44
...
...
@@ -1828,7 +1828,7 @@ static int serial_parse(const char *devname)
exit
(
1
);
}
snprintf
(
label
,
sizeof
(
label
),
"serial%d"
,
index
);
serial_hds
[
index
]
=
qemu_chr_
open
(
label
,
devname
,
NULL
);
serial_hds
[
index
]
=
qemu_chr_
new
(
label
,
devname
,
NULL
);
if
(
!
serial_hds
[
index
])
{
fprintf
(
stderr
,
"qemu: could not open serial device '%s': %s
\n
"
,
devname
,
strerror
(
errno
));
...
...
@@ -1850,7 +1850,7 @@ static int parallel_parse(const char *devname)
exit
(
1
);
}
snprintf
(
label
,
sizeof
(
label
),
"parallel%d"
,
index
);
parallel_hds
[
index
]
=
qemu_chr_
open
(
label
,
devname
,
NULL
);
parallel_hds
[
index
]
=
qemu_chr_
new
(
label
,
devname
,
NULL
);
if
(
!
parallel_hds
[
index
])
{
fprintf
(
stderr
,
"qemu: could not open parallel device '%s': %s
\n
"
,
devname
,
strerror
(
errno
));
...
...
@@ -1881,7 +1881,7 @@ static int virtcon_parse(const char *devname)
qemu_opt_set
(
dev_opts
,
"driver"
,
"virtconsole"
);
snprintf
(
label
,
sizeof
(
label
),
"virtcon%d"
,
index
);
virtcon_hds
[
index
]
=
qemu_chr_
open
(
label
,
devname
,
NULL
);
virtcon_hds
[
index
]
=
qemu_chr_
new
(
label
,
devname
,
NULL
);
if
(
!
virtcon_hds
[
index
])
{
fprintf
(
stderr
,
"qemu: could not open virtio console '%s': %s
\n
"
,
devname
,
strerror
(
errno
));
...
...
@@ -1897,7 +1897,7 @@ static int debugcon_parse(const char *devname)
{
QemuOpts
*
opts
;
if
(
!
qemu_chr_
open
(
"debugcon"
,
devname
,
NULL
))
{
if
(
!
qemu_chr_
new
(
"debugcon"
,
devname
,
NULL
))
{
exit
(
1
);
}
opts
=
qemu_opts_create
(
qemu_find_opts
(
"device"
),
"debugcon"
,
1
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录