Patchwork keymaps: Fix kernel version issue

login
register
mail settings
Submitter Richard Purdie
Date March 17, 2013, 10:51 p.m.
Message ID <1363560698.4315.0.camel@ted>
Download mbox | patch
Permalink /patch/46295/
State New
Headers show

Comments

Richard Purdie - March 17, 2013, 10:51 p.m.
The conditional code here was to switch between 2.4 and 2.6
kernels. Since we no longer support 2.4, we can hardcode
2.6 which ensures the correct keymap will be found.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---

Patch

diff --git a/meta/recipes-bsp/keymaps/files/keymap.sh b/meta/recipes-bsp/keymaps/files/keymap.sh
index 6ebc634..0e5eabc 100755
--- a/meta/recipes-bsp/keymaps/files/keymap.sh
+++ b/meta/recipes-bsp/keymaps/files/keymap.sh
@@ -2,14 +2,13 @@ 
 #
 # load keymap, if existing
 
-KERNEL_MAJMIN=`uname -r | cut -d '.' -f 1,2`
-if [ -e /etc/keymap-$KERNEL_MAJMIN.map ]; then
-	loadkeys /etc/keymap-$KERNEL_MAJMIN.map
+if [ -e /etc/keymap-2.6.map ]; then
+	loadkeys /etc/keymap-2.6.map
 fi
 
-if ( ls "/etc" | grep -q "keymap-extension-${KERNEL_MAJMIN}" )
+if ( ls "/etc" | grep -q "keymap-extension-2.6" )
 then
-	for extension in `ls -1 /etc/keymap-extension-$KERNEL_MAJMIN*` 
+	for extension in `ls -1 /etc/keymap-extension-2.6*` 
 	do	
 		loadkeys "$extension"
 	done