From: "Ling, Xiaofeng" <xiaofeng.ling@intel.com>
To: xen-devel <xen-devel@lists.xensource.com>
Subject: [PATCH]add option to disable key repeat in device model for vmx guest
Date: Thu, 01 Dec 2005 16:23:59 +0800 [thread overview]
Message-ID: <438EB31F.9030405@intel.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 320 bytes --]
Add an option for device model to disable key repeat.
On slow network, when creating a vmx guest remotely,
the key repeat feature may make it hard to even type
the user name and password to login in to guest OS.
Signed-off-by: Eddie, Dong <eddie.dong@intel.com>
Signed-off-by: Xiaofeng, Ling <xiaofeng.ling@intel.com>
[-- Attachment #2: repeatkey.patch --]
[-- Type: text/x-patch, Size: 2692 bytes --]
# HG changeset patch
# User Xiaofeng Ling <xiaofeng.ling@intel.com>
# Node ID 1425abd21f8b893ec5d2f1f600f6a0631cc72a08
# Parent 0f2af20b4f5526c03c1fe9634db7eb098f32b964
Add an option for device model to disable key repeat.
On slow network, when creating a vmx guest remotely,
the key repeat feature may make it hard to even type
the user name and password to login in to guest OS.
Signed-off-by: Eddie, Dong <eddie.dong@intel.com>
Signed-off-by: Xiaofeng, Ling <xiaofeng.ling@intel.com>
diff -r 0f2af20b4f55 -r 1425abd21f8b tools/ioemu/sdl.c
--- a/tools/ioemu/sdl.c Thu Dec 1 16:09:57 2005 +0800
+++ b/tools/ioemu/sdl.c Thu Dec 1 16:11:34 2005 +0800
@@ -592,7 +592,8 @@
sdl_resize(ds, 640, 400);
sdl_update_caption();
- SDL_EnableKeyRepeat(250, 50);
+ if(repeat_key)
+ SDL_EnableKeyRepeat(250, 50);
SDL_EnableUNICODE(1);
gui_grab = 0;
diff -r 0f2af20b4f55 -r 1425abd21f8b tools/ioemu/vl.c
--- a/tools/ioemu/vl.c Thu Dec 1 16:09:57 2005 +0800
+++ b/tools/ioemu/vl.c Thu Dec 1 16:11:34 2005 +0800
@@ -144,6 +144,7 @@
int graphic_height = 600;
int graphic_depth = 15;
int full_screen = 0;
+int repeat_key = 1;
TextConsole *vga_console;
CharDriverState *serial_hds[MAX_SERIAL_PORTS];
int xc_handle;
@@ -2248,6 +2249,7 @@
"-std-vga simulate a standard VGA card with VESA Bochs Extensions\n"
" (default is CL-GD5446 PCI VGA)\n"
"-vgaacc [0|1] 1 to accelerate CL-GD5446 speed, default is 1\n"
+ "-no-repeatkey disable key repeat feature for SDL keyboard simulation"
#endif
"-loadvm file start right away with a saved state (loadvm in monitor)\n"
"\n"
@@ -2339,6 +2341,7 @@
QEMU_OPTION_loadvm,
QEMU_OPTION_full_screen,
QEMU_OPTION_vgaacc,
+ QEMU_OPTION_repeatkey,
};
typedef struct QEMUOption {
@@ -2417,6 +2420,7 @@
{ "nic-ne2000", 0, QEMU_OPTION_nic_ne2000 },
{ "cirrusvga", 0, QEMU_OPTION_cirrusvga },
{ "vgaacc", HAS_ARG, QEMU_OPTION_vgaacc },
+ { "no-repeatkey", 0, QEMU_OPTION_repeatkey },
{ NULL },
};
@@ -2968,6 +2972,9 @@
exit(1);
}
}
+ break;
+ case QEMU_OPTION_repeatkey:
+ repeat_key = 0;
break;
case QEMU_OPTION_std_vga:
cirrus_vga_enabled = 0;
diff -r 0f2af20b4f55 -r 1425abd21f8b tools/ioemu/vl.h
--- a/tools/ioemu/vl.h Thu Dec 1 16:09:57 2005 +0800
+++ b/tools/ioemu/vl.h Thu Dec 1 16:11:34 2005 +0800
@@ -612,6 +612,7 @@
void kbd_init(void);
extern const char* keyboard_layout;
+extern int repeat_key;
/* mc146818rtc.c */
[-- Attachment #3: Type: text/plain, Size: 138 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
reply other threads:[~2005-12-01 8:23 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=438EB31F.9030405@intel.com \
--to=xiaofeng.ling@intel.com \
--cc=xen-devel@lists.xensource.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.