[<prev] [next>] [day] [month] [year] [list]
Message-Id: <1414325282-32177-1-git-send-email-van.freenix@gmail.com>
Date: Sun, 26 Oct 2014 20:08:02 +0800
From: Peng Fan <van.freenix@...il.com>
To: gregkh@...uxfoundation.org, jslaby@...e.cz
Cc: daniel.vetter@...ll.ch, kilobyte@...band.pl, dh.herrmann@...il.com,
petr.pisar@...as.cz, tiwai@...e.de, van.freenix@...il.com,
linux-kernel@...r.kernel.org
Subject: [PATCH] tty:vt remove obsolete struct initializer
This patch fixes sparse warning:
"obsolete struct initializer, use C99 syntax"
Signed-off-by: Peng Fan <van.freenix@...il.com>
---
drivers/tty/vt/vt.c | 16 ++++++++++------
1 file changed, 10 insertions(+), 6 deletions(-)
diff --git a/drivers/tty/vt/vt.c b/drivers/tty/vt/vt.c
index b33b00b..cf18bd4 100644
--- a/drivers/tty/vt/vt.c
+++ b/drivers/tty/vt/vt.c
@@ -1367,9 +1367,11 @@ static void csi_m(struct vc_data *vc)
rgb_from_256(vc->vc_par[i]));
} else if (vc->vc_par[i] == 2 && /* 24 bit */
i <= vc->vc_npar + 3) {/* extremely rare */
- struct rgb c = {r:vc->vc_par[i+1],
- g:vc->vc_par[i+2],
- b:vc->vc_par[i+3]};
+ struct rgb c = {
+ .r = vc->vc_par[i + 1],
+ .g = vc->vc_par[i + 2],
+ .b = vc->vc_par[i + 3],
+ };
rgb_foreground(vc, c);
i += 3;
}
@@ -1388,9 +1390,11 @@ static void csi_m(struct vc_data *vc)
rgb_from_256(vc->vc_par[i]));
} else if (vc->vc_par[i] == 2 && /* 24 bit */
i <= vc->vc_npar + 3) {
- struct rgb c = {r:vc->vc_par[i+1],
- g:vc->vc_par[i+2],
- b:vc->vc_par[i+3]};
+ struct rgb c = {
+ .r = vc->vc_par[i + 1],
+ .g = vc->vc_par[i + 2],
+ .b = vc->vc_par[i + 3],
+ };
rgb_background(vc, c);
i += 3;
}
--
1.8.4
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists