From: "Marc-André Lureau" <marcandre.lureau@redhat.com>
To: qemu-devel@nongnu.org
Cc: "Paolo Bonzini" <pbonzini@redhat.com>,
armbru@redhat.com, kraxel@redhat.com,
"Marc-André Lureau" <marcandre.lureau@redhat.com>
Subject: [Qemu-devel] [PATCH 1/2] vl: constify VGAInterfaceInfo
Date: Fri, 12 Apr 2019 17:27:12 +0200 [thread overview]
Message-ID: <20190412152713.16018-2-marcandre.lureau@redhat.com> (raw)
In-Reply-To: <20190412152713.16018-1-marcandre.lureau@redhat.com>
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
vl.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/vl.c b/vl.c
index c696ad2a13..0a96232e95 100644
--- a/vl.c
+++ b/vl.c
@@ -2026,7 +2026,7 @@ typedef struct VGAInterfaceInfo {
const char *class_names[2];
} VGAInterfaceInfo;
-static VGAInterfaceInfo vga_interfaces[VGA_TYPE_MAX] = {
+static const VGAInterfaceInfo vga_interfaces[VGA_TYPE_MAX] = {
[VGA_NONE] = {
.opt_name = "none",
},
@@ -2072,7 +2072,7 @@ static VGAInterfaceInfo vga_interfaces[VGA_TYPE_MAX] = {
static bool vga_interface_available(VGAInterfaceType t)
{
- VGAInterfaceInfo *ti = &vga_interfaces[t];
+ const VGAInterfaceInfo *ti = &vga_interfaces[t];
assert(t < VGA_TYPE_MAX);
return !ti->class_names[0] ||
@@ -2087,7 +2087,7 @@ static void select_vgahw(const char *p)
assert(vga_interface_type == VGA_NONE);
for (t = 0; t < VGA_TYPE_MAX; t++) {
- VGAInterfaceInfo *ti = &vga_interfaces[t];
+ const VGAInterfaceInfo *ti = &vga_interfaces[t];
if (ti->opt_name && strstart(p, ti->opt_name, &opts)) {
if (!vga_interface_available(t)) {
error_report("%s not available", ti->name);
--
2.21.0.313.ge35b8cb8e2
WARNING: multiple messages have this Message-ID (diff)
From: "Marc-André Lureau" <marcandre.lureau@redhat.com>
To: qemu-devel@nongnu.org
Cc: "Paolo Bonzini" <pbonzini@redhat.com>,
armbru@redhat.com,
"Marc-André Lureau" <marcandre.lureau@redhat.com>,
kraxel@redhat.com
Subject: [Qemu-devel] [PATCH 1/2] vl: constify VGAInterfaceInfo
Date: Fri, 12 Apr 2019 17:27:12 +0200 [thread overview]
Message-ID: <20190412152713.16018-2-marcandre.lureau@redhat.com> (raw)
Message-ID: <20190412152712.-rPcwdmEPGaFDPdoMV618Fh9UhOxCGW77OsNSTMHd3A@z> (raw)
In-Reply-To: <20190412152713.16018-1-marcandre.lureau@redhat.com>
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
vl.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/vl.c b/vl.c
index c696ad2a13..0a96232e95 100644
--- a/vl.c
+++ b/vl.c
@@ -2026,7 +2026,7 @@ typedef struct VGAInterfaceInfo {
const char *class_names[2];
} VGAInterfaceInfo;
-static VGAInterfaceInfo vga_interfaces[VGA_TYPE_MAX] = {
+static const VGAInterfaceInfo vga_interfaces[VGA_TYPE_MAX] = {
[VGA_NONE] = {
.opt_name = "none",
},
@@ -2072,7 +2072,7 @@ static VGAInterfaceInfo vga_interfaces[VGA_TYPE_MAX] = {
static bool vga_interface_available(VGAInterfaceType t)
{
- VGAInterfaceInfo *ti = &vga_interfaces[t];
+ const VGAInterfaceInfo *ti = &vga_interfaces[t];
assert(t < VGA_TYPE_MAX);
return !ti->class_names[0] ||
@@ -2087,7 +2087,7 @@ static void select_vgahw(const char *p)
assert(vga_interface_type == VGA_NONE);
for (t = 0; t < VGA_TYPE_MAX; t++) {
- VGAInterfaceInfo *ti = &vga_interfaces[t];
+ const VGAInterfaceInfo *ti = &vga_interfaces[t];
if (ti->opt_name && strstart(p, ti->opt_name, &opts)) {
if (!vga_interface_available(t)) {
error_report("%s not available", ti->name);
--
2.21.0.313.ge35b8cb8e2
next prev parent reply other threads:[~2019-04-12 15:27 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-04-12 15:27 [Qemu-devel] [PATCH 0/2] Add -vga help Marc-André Lureau
2019-04-12 15:27 ` Marc-André Lureau
2019-04-12 15:27 ` Marc-André Lureau [this message]
2019-04-12 15:27 ` [Qemu-devel] [PATCH 1/2] vl: constify VGAInterfaceInfo Marc-André Lureau
2019-04-12 16:14 ` Philippe Mathieu-Daudé
2019-04-12 16:14 ` Philippe Mathieu-Daudé
2019-04-12 15:27 ` [Qemu-devel] [PATCH 2/2] vl: add -vga help support Marc-André Lureau
2019-04-12 15:27 ` Marc-André Lureau
2019-04-12 16:15 ` Philippe Mathieu-Daudé
2019-04-12 16:15 ` Philippe Mathieu-Daudé
2019-05-07 7:49 ` [Qemu-devel] [PATCH 0/2] Add -vga help Gerd Hoffmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190412152713.16018-2-marcandre.lureau@redhat.com \
--to=marcandre.lureau@redhat.com \
--cc=armbru@redhat.com \
--cc=kraxel@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).