kvm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] kvm tools: Drop unused vars from int10.c code
@ 2011-05-23 14:39 Cyrill Gorcunov
  0 siblings, 0 replies; only message in thread
From: Cyrill Gorcunov @ 2011-05-23 14:39 UTC (permalink / raw)
  To: Pekka Enberg; +Cc: Sasha Levin, kvm-vger, Ingo Molnar, Prasad Joshi

There is a couple of functions which defines 'ah' variable but
never use it in real so that gcc 4.6.x series does complain on
me as

  CC       bios/bios-rom.bin
  bios/int10.c: In function ‘int10_putchar’:
  bios/int10.c:86:9: error: variable ‘ah’ set but not used [-Werror=unused-but-set-variable]
  bios/int10.c: In function ‘int10_vesa’:
  bios/int10.c:96:9: error: variable ‘ah’ set but not used [-Werror=unused-but-set-variable]
  cc1: all warnings being treated as errors

so get rid of them.

Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
CC: Sasha Levin <levinsasha928@gmail.com>
---
 tools/kvm/bios/int10.c |    8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

Index: linux-2.6.git/tools/kvm/bios/int10.c
===================================================================
--- linux-2.6.git.orig/tools/kvm/bios/int10.c
+++ linux-2.6.git/tools/kvm/bios/int10.c
@@ -83,22 +83,18 @@ static inline void outb(unsigned short p
  */
 static inline void int10_putchar(struct int10_args *args)
 {
-	u8 al, ah;
-
-	al = args->eax & 0xFF;
-	ah = (args->eax & 0xFF00) >> 8;
+	u8 al = args->eax & 0xFF;

 	outb(0x3f8, al);
 }

 static void int10_vesa(struct int10_args *args)
 {
-	u8 al, ah;
+	u8 al;
 	struct vesa_general_info *destination;
 	struct vminfo *vi;

 	al = args->eax;
-	ah = args->eax >> 8;

 	switch (al) {
 	case 0:

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2011-05-23 14:39 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-05-23 14:39 [PATCH] kvm tools: Drop unused vars from int10.c code Cyrill Gorcunov

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).