All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Configurable keyboard mapping for HVM
@ 2006-12-18 10:49 Guillaume Rousse
  2006-12-18 11:26 ` Keir Fraser
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Guillaume Rousse @ 2006-12-18 10:49 UTC (permalink / raw)
  To: xen-devel

[-- Attachment #1: Type: text/plain, Size: 114 bytes --]

Current keyboard mapping is hardcoded to en-US in image.py. Attached
patch make this value a configurable option.

[-- Attachment #2: xen-3.0.3.allow_keyboard_mapping.patch --]
[-- Type: text/x-patch, Size: 986 bytes --]

diff -Naur xen-3.0.3_0-src/tools/python/xen/xend/image.py xen-3.0.3_0-src.allow_keyboard_mapping/tools/python/xen/xend/image.py
--- xen-3.0.3_0-src/tools/python/xen/xend/image.py	2006-10-15 14:22:03.000000000 +0200
+++ xen-3.0.3_0-src.allow_keyboard_mapping/tools/python/xen/xend/image.py	2006-12-18 11:45:22.000000000 +0100
@@ -361,11 +361,12 @@
             vncdisplay = sxp.child_value(config, 'vncdisplay',
                                          int(self.vm.getDomid()))
             vncunused = sxp.child_value(config, 'vncunused')
+            keyboard = sxp.child_value(config, 'keyboard')
             if vncunused:
                 ret += ['-vncunused']
             else:
                 ret += ['-vnc', '%d' % vncdisplay]
-            ret += ['-k', 'en-us']
+            ret += ['-k', keyboard]
             vnclisten = sxp.child_value(config, 'vnclisten')
             if not(vnclisten):
                 vnclisten = xen.xend.XendRoot.instance().get_vnclisten_address()

[-- Attachment #3: Type: text/plain, Size: 138 bytes --]

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] Configurable keyboard mapping for HVM
  2006-12-18 10:49 [PATCH] Configurable keyboard mapping for HVM Guillaume Rousse
@ 2006-12-18 11:26 ` Keir Fraser
  2006-12-18 12:10   ` Guillaume Rousse
  2006-12-18 11:45 ` Ewan Mellor
  2006-12-19  4:28 ` Kasai Takanori
  2 siblings, 1 reply; 5+ messages in thread
From: Keir Fraser @ 2006-12-18 11:26 UTC (permalink / raw)
  To: Guillaume Rousse, xen-devel

What happens here if 'keyboard' is undefined in the s-expression?

 -- Keir

On 18/12/06 10:49, "Guillaume Rousse" <Guillaume.Rousse@inria.fr> wrote:

> Current keyboard mapping is hardcoded to en-US in image.py. Attached
> patch make this value a configurable option.
> diff -Naur xen-3.0.3_0-src/tools/python/xen/xend/image.py
> xen-3.0.3_0-src.allow_keyboard_mapping/tools/python/xen/xend/image.py
> --- xen-3.0.3_0-src/tools/python/xen/xend/image.py 2006-10-15
> 14:22:03.000000000 +0200
> +++ 
> xen-3.0.3_0-src.allow_keyboard_mapping/tools/python/xen/xend/image.py 2006-12-
> 18 11:45:22.000000000 +0100
> @@ -361,11 +361,12 @@
>              vncdisplay = sxp.child_value(config, 'vncdisplay',
>                                           int(self.vm.getDomid()))
>              vncunused = sxp.child_value(config, 'vncunused')
> +            keyboard = sxp.child_value(config, 'keyboard')
>              if vncunused:
>                  ret += ['-vncunused']
>              else:
>                  ret += ['-vnc', '%d' % vncdisplay]
> -            ret += ['-k', 'en-us']
> +            ret += ['-k', keyboard]
>              vnclisten = sxp.child_value(config, 'vnclisten')
>              if not(vnclisten):
>                  vnclisten =
> xen.xend.XendRoot.instance().get_vnclisten_address()
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xensource.com
> http://lists.xensource.com/xen-devel

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] Configurable keyboard mapping for HVM
  2006-12-18 10:49 [PATCH] Configurable keyboard mapping for HVM Guillaume Rousse
  2006-12-18 11:26 ` Keir Fraser
@ 2006-12-18 11:45 ` Ewan Mellor
  2006-12-19  4:28 ` Kasai Takanori
  2 siblings, 0 replies; 5+ messages in thread
From: Ewan Mellor @ 2006-12-18 11:45 UTC (permalink / raw)
  To: Guillaume Rousse; +Cc: xen-devel

On Mon, Dec 18, 2006 at 11:49:02AM +0100, Guillaume Rousse wrote:

> Current keyboard mapping is hardcoded to en-US in image.py. Attached
> patch make this value a configurable option.

> diff -Naur xen-3.0.3_0-src/tools/python/xen/xend/image.py xen-3.0.3_0-src.allow_keyboard_mapping/tools/python/xen/xend/image.py
> --- xen-3.0.3_0-src/tools/python/xen/xend/image.py	2006-10-15 14:22:03.000000000 +0200
> +++ xen-3.0.3_0-src.allow_keyboard_mapping/tools/python/xen/xend/image.py	2006-12-18 11:45:22.000000000 +0100
> @@ -361,11 +361,12 @@
>              vncdisplay = sxp.child_value(config, 'vncdisplay',
>                                           int(self.vm.getDomid()))
>              vncunused = sxp.child_value(config, 'vncunused')
> +            keyboard = sxp.child_value(config, 'keyboard')
>              if vncunused:
>                  ret += ['-vncunused']
>              else:
>                  ret += ['-vnc', '%d' % vncdisplay]
> -            ret += ['-k', 'en-us']
> +            ret += ['-k', keyboard]
>              vnclisten = sxp.child_value(config, 'vnclisten')
>              if not(vnclisten):
>                  vnclisten = xen.xend.XendRoot.instance().get_vnclisten_address()

Before we can submit this patch, we need a Signed-off-by: line, to indicate
your acceptance of the Developer's Certificate of Origin.

http://www.osdl.org/newsroom/press_releases/2004/2004_05_24_dco.html

Thanks,

Ewan.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] Configurable keyboard mapping for HVM
  2006-12-18 11:26 ` Keir Fraser
@ 2006-12-18 12:10   ` Guillaume Rousse
  0 siblings, 0 replies; 5+ messages in thread
From: Guillaume Rousse @ 2006-12-18 12:10 UTC (permalink / raw)
  To: xen-devel

[-- Attachment #1: Type: text/plain, Size: 204 bytes --]

Keir Fraser wrote:
> What happens here if 'keyboard' is undefined in the s-expression?
Good point. This updated patch uses 'en-us' as default.

Signed-off-by: Guillaume Rousse <Guillaume.Rousse@inria.fr>

[-- Attachment #2: xen-3.0.3.allow_keyboard_mapping.patch --]
[-- Type: text/x-patch, Size: 995 bytes --]

diff -Naur xen-3.0.3_0-src/tools/python/xen/xend/image.py xen-3.0.3_0-src.allow_keyboard_mapping/tools/python/xen/xend/image.py
--- xen-3.0.3_0-src/tools/python/xen/xend/image.py	2006-10-15 14:22:03.000000000 +0200
+++ xen-3.0.3_0-src.allow_keyboard_mapping/tools/python/xen/xend/image.py	2006-12-18 11:45:22.000000000 +0100
@@ -361,11 +361,12 @@
             vncdisplay = sxp.child_value(config, 'vncdisplay',
                                          int(self.vm.getDomid()))
             vncunused = sxp.child_value(config, 'vncunused')
+            keyboard = sxp.child_value(config, 'keyboard', 'en-us')
             if vncunused:
                 ret += ['-vncunused']
             else:
                 ret += ['-vnc', '%d' % vncdisplay]
-            ret += ['-k', 'en-us']
+            ret += ['-k', keyboard]
             vnclisten = sxp.child_value(config, 'vnclisten')
             if not(vnclisten):
                 vnclisten = xen.xend.XendRoot.instance().get_vnclisten_address()

[-- Attachment #3: Type: text/plain, Size: 138 bytes --]

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] Configurable keyboard mapping for HVM
  2006-12-18 10:49 [PATCH] Configurable keyboard mapping for HVM Guillaume Rousse
  2006-12-18 11:26 ` Keir Fraser
  2006-12-18 11:45 ` Ewan Mellor
@ 2006-12-19  4:28 ` Kasai Takanori
  2 siblings, 0 replies; 5+ messages in thread
From: Kasai Takanori @ 2006-12-19  4:28 UTC (permalink / raw)
  To: Guillaume Rousse, xen-devel

Hi Rousse,

> Current keyboard mapping is hardcoded to en-US in image.py. Attached
> patch make this value a configurable option.

I made the patch that corrects the same problem.
It was already applied to xen-unstable.hg.

· xen-unstable.hg : cs 12467
   [Add to select keyboard layout]

To select the keymap, configuration file is defined as follows.
  keymap='ja'

The input keymap is input as an option of qemu-dm.
  qemu-dm -k ja

But it is not applied to xen3.0.3.
If this patch is applied, it is possible to select keyboard.

Thanks

--
Takanori Kasai

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2006-12-19  4:28 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-12-18 10:49 [PATCH] Configurable keyboard mapping for HVM Guillaume Rousse
2006-12-18 11:26 ` Keir Fraser
2006-12-18 12:10   ` Guillaume Rousse
2006-12-18 11:45 ` Ewan Mellor
2006-12-19  4:28 ` Kasai Takanori

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.