mirror of
git://projects.qi-hardware.com/openwrt-xburst.git
synced 2024-11-23 18:08:25 +02:00
xburst: ben nanonote: add modify keys and fbcon-color patches
This commit is contained in:
parent
db874d1cb5
commit
44fed9277b
@ -0,0 +1,657 @@
|
||||
From 0126586095ebd44af31f8080e30143a608ab33ca Mon Sep 17 00:00:00 2001
|
||||
From: Xiangfu Liu <xiangfu@macbook.(none)>
|
||||
Date: Fri, 19 Aug 2011 15:40:08 +0800
|
||||
Subject: [PATCH 21/28] 500-modifier-keys.patch
|
||||
|
||||
---
|
||||
drivers/tty/vt/defkeymap.c_shipped | 326 +++++++++++++++++++++++++++---------
|
||||
drivers/tty/vt/defkeymap.map | 88 +++++++---
|
||||
2 files changed, 305 insertions(+), 109 deletions(-)
|
||||
|
||||
diff --git a/drivers/tty/vt/defkeymap.c_shipped b/drivers/tty/vt/defkeymap.c_shipped
|
||||
index d2208dfe..41ea840 100644
|
||||
--- a/drivers/tty/vt/defkeymap.c_shipped
|
||||
+++ b/drivers/tty/vt/defkeymap.c_shipped
|
||||
@@ -9,10 +9,10 @@ u_short plain_map[NR_KEYS] = {
|
||||
0xf200, 0xf01b, 0xf031, 0xf032, 0xf033, 0xf034, 0xf035, 0xf036,
|
||||
0xf037, 0xf038, 0xf039, 0xf030, 0xf02d, 0xf03d, 0xf07f, 0xf009,
|
||||
0xfb71, 0xfb77, 0xfb65, 0xfb72, 0xfb74, 0xfb79, 0xfb75, 0xfb69,
|
||||
- 0xfb6f, 0xfb70, 0xf05b, 0xf05d, 0xf201, 0xf702, 0xfb61, 0xfb73,
|
||||
+ 0xfb6f, 0xfb70, 0xf05b, 0xf05d, 0xf201, 0xf706, 0xfb61, 0xfb73,
|
||||
0xfb64, 0xfb66, 0xfb67, 0xfb68, 0xfb6a, 0xfb6b, 0xfb6c, 0xf03b,
|
||||
0xf027, 0xf060, 0xf700, 0xf05c, 0xfb7a, 0xfb78, 0xfb63, 0xfb76,
|
||||
- 0xfb62, 0xfb6e, 0xfb6d, 0xf02c, 0xf02e, 0xf02f, 0xf700, 0xf30c,
|
||||
+ 0xfb62, 0xfb6e, 0xfb6d, 0xf02c, 0xf02e, 0xf02f, 0xf701, 0xf30c,
|
||||
0xf703, 0xf020, 0xf207, 0xf100, 0xf101, 0xf102, 0xf103, 0xf104,
|
||||
0xf105, 0xf106, 0xf107, 0xf108, 0xf109, 0xf208, 0xf209, 0xf307,
|
||||
0xf308, 0xf309, 0xf30b, 0xf304, 0xf305, 0xf306, 0xf30a, 0xf301,
|
||||
@@ -20,56 +20,104 @@ u_short plain_map[NR_KEYS] = {
|
||||
0xf10b, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
0xf30e, 0xf702, 0xf30d, 0xf01c, 0xf701, 0xf205, 0xf114, 0xf603,
|
||||
0xf118, 0xf601, 0xf602, 0xf117, 0xf600, 0xf119, 0xf115, 0xf116,
|
||||
- 0xf11a, 0xf10c, 0xf10d, 0xf11b, 0xf11c, 0xf110, 0xf311, 0xf11d,
|
||||
+ 0xf11a, 0xf10c, 0xf10b, 0xf10a, 0xf11c, 0xf110, 0xf311, 0xf11d,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
};
|
||||
|
||||
-u_short shift_map[NR_KEYS] = {
|
||||
+static u_short shift_map[NR_KEYS] = {
|
||||
0xf200, 0xf01b, 0xf021, 0xf040, 0xf023, 0xf024, 0xf025, 0xf05e,
|
||||
0xf026, 0xf02a, 0xf028, 0xf029, 0xf05f, 0xf02b, 0xf07f, 0xf009,
|
||||
0xfb51, 0xfb57, 0xfb45, 0xfb52, 0xfb54, 0xfb59, 0xfb55, 0xfb49,
|
||||
- 0xfb4f, 0xfb50, 0xf07b, 0xf07d, 0xf201, 0xf702, 0xfb41, 0xfb53,
|
||||
+ 0xfb4f, 0xfb50, 0xf07b, 0xf07d, 0xf201, 0xf706, 0xfb41, 0xfb53,
|
||||
0xfb44, 0xfb46, 0xfb47, 0xfb48, 0xfb4a, 0xfb4b, 0xfb4c, 0xf03a,
|
||||
0xf022, 0xf07e, 0xf700, 0xf07c, 0xfb5a, 0xfb58, 0xfb43, 0xfb56,
|
||||
- 0xfb42, 0xfb4e, 0xfb4d, 0xf03c, 0xf03e, 0xf03f, 0xf700, 0xf30c,
|
||||
+ 0xfb42, 0xfb4e, 0xfb4d, 0xf03b, 0xf03a, 0xf03f, 0xf701, 0xf30c,
|
||||
0xf703, 0xf020, 0xf207, 0xf10a, 0xf10b, 0xf10c, 0xf10d, 0xf10e,
|
||||
0xf10f, 0xf110, 0xf111, 0xf112, 0xf113, 0xf213, 0xf203, 0xf307,
|
||||
0xf308, 0xf309, 0xf30b, 0xf304, 0xf305, 0xf306, 0xf30a, 0xf301,
|
||||
- 0xf302, 0xf303, 0xf300, 0xf310, 0xf206, 0xf200, 0xf03e, 0xf10a,
|
||||
- 0xf10b, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
- 0xf30e, 0xf702, 0xf30d, 0xf200, 0xf701, 0xf205, 0xf114, 0xf603,
|
||||
+ 0xf302, 0xf303, 0xf300, 0xf310, 0xf206, 0xf200, 0xf03e, 0xf20b,
|
||||
+ 0xf20a, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf30e, 0xf702, 0xf30d, 0xf01c, 0xf701, 0xf205, 0xf114, 0xf603,
|
||||
0xf20b, 0xf601, 0xf602, 0xf117, 0xf600, 0xf20a, 0xf115, 0xf116,
|
||||
- 0xf11a, 0xf10c, 0xf10d, 0xf11b, 0xf11c, 0xf110, 0xf311, 0xf11d,
|
||||
+ 0xf11a, 0xf10c, 0xf20a, 0xf20b, 0xf11c, 0xf110, 0xf311, 0xf11d,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
};
|
||||
|
||||
-u_short altgr_map[NR_KEYS] = {
|
||||
+static u_short altgr_map[NR_KEYS] = {
|
||||
0xf200, 0xf200, 0xf200, 0xf040, 0xf200, 0xf024, 0xf200, 0xf200,
|
||||
- 0xf07b, 0xf05b, 0xf05d, 0xf07d, 0xf05c, 0xf200, 0xf200, 0xf200,
|
||||
- 0xfb71, 0xfb77, 0xf918, 0xfb72, 0xfb74, 0xfb79, 0xfb75, 0xfb69,
|
||||
- 0xfb6f, 0xfb70, 0xf200, 0xf07e, 0xf201, 0xf702, 0xf914, 0xfb73,
|
||||
- 0xf917, 0xf919, 0xfb67, 0xfb68, 0xfb6a, 0xfb6b, 0xfb6c, 0xf200,
|
||||
- 0xf200, 0xf200, 0xf700, 0xf200, 0xfb7a, 0xfb78, 0xf916, 0xfb76,
|
||||
- 0xf915, 0xfb6e, 0xfb6d, 0xf200, 0xf200, 0xf200, 0xf700, 0xf30c,
|
||||
- 0xf703, 0xf200, 0xf207, 0xf50c, 0xf50d, 0xf50e, 0xf50f, 0xf510,
|
||||
- 0xf511, 0xf512, 0xf513, 0xf514, 0xf515, 0xf208, 0xf202, 0xf911,
|
||||
+ 0xf07b, 0xf05b, 0xf05d, 0xf07d, 0xf05c, 0xf07e, 0xf116, 0xf200,
|
||||
+ 0xf021, 0xf040, 0xf023, 0xf024, 0xf025, 0xf05e, 0xf026, 0xf02a,
|
||||
+ 0xf028, 0xf029, 0xf200, 0xf07e, 0xf201, 0xf706, 0xf0b0, 0xf0a8,
|
||||
+ 0xf0a4, 0xf02d, 0xf05f, 0xf07b, 0xf05b, 0xf05d, 0xf07d, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf700, 0xf200, 0xf039, 0xf030, 0xf916, 0xfb76,
|
||||
+ 0xf915, 0xf03c, 0xf03e, 0xf027, 0xf022, 0xf200, 0xf701, 0xf30c,
|
||||
+ 0xf703, 0xf200, 0xf207, 0xf031, 0xf032, 0xf033, 0xf034, 0xf035,
|
||||
+ 0xf036, 0xf037, 0xf038, 0xf514, 0xf515, 0xf208, 0xf202, 0xf911,
|
||||
0xf912, 0xf913, 0xf30b, 0xf90e, 0xf90f, 0xf910, 0xf30a, 0xf90b,
|
||||
0xf90c, 0xf90d, 0xf90a, 0xf310, 0xf206, 0xf200, 0xf07c, 0xf516,
|
||||
0xf517, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
- 0xf30e, 0xf702, 0xf30d, 0xf200, 0xf701, 0xf205, 0xf114, 0xf603,
|
||||
+ 0xf30e, 0xf702, 0xf30d, 0xf01c, 0xf701, 0xf205, 0xf114, 0xf603,
|
||||
0xf118, 0xf601, 0xf602, 0xf117, 0xf600, 0xf119, 0xf115, 0xf116,
|
||||
- 0xf11a, 0xf10c, 0xf10d, 0xf11b, 0xf11c, 0xf110, 0xf311, 0xf11d,
|
||||
+ 0xf11a, 0xf10c, 0xf517, 0xf516, 0xf11c, 0xf110, 0xf311, 0xf11d,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
};
|
||||
|
||||
-u_short ctrl_map[NR_KEYS] = {
|
||||
+static u_short ctrl_map[NR_KEYS] = {
|
||||
0xf200, 0xf200, 0xf200, 0xf000, 0xf01b, 0xf01c, 0xf01d, 0xf01e,
|
||||
- 0xf01f, 0xf07f, 0xf200, 0xf200, 0xf01f, 0xf200, 0xf008, 0xf200,
|
||||
+ 0xf01f, 0xf07f, 0xf200, 0xf200, 0xf01f, 0xf200, 0xf200, 0xf200,
|
||||
0xf011, 0xf017, 0xf005, 0xf012, 0xf014, 0xf019, 0xf015, 0xf009,
|
||||
- 0xf00f, 0xf010, 0xf01b, 0xf01d, 0xf201, 0xf702, 0xf001, 0xf013,
|
||||
+ 0xf00f, 0xf010, 0xf01b, 0xf01d, 0xf201, 0xf706, 0xf001, 0xf013,
|
||||
0xf004, 0xf006, 0xf007, 0xf008, 0xf00a, 0xf00b, 0xf00c, 0xf200,
|
||||
0xf007, 0xf000, 0xf700, 0xf01c, 0xf01a, 0xf018, 0xf003, 0xf016,
|
||||
- 0xf002, 0xf00e, 0xf00d, 0xf200, 0xf20e, 0xf07f, 0xf700, 0xf30c,
|
||||
+ 0xf002, 0xf00e, 0xf00d, 0xf200, 0xf20e, 0xf07f, 0xf701, 0xf30c,
|
||||
0xf703, 0xf000, 0xf207, 0xf100, 0xf101, 0xf102, 0xf103, 0xf104,
|
||||
0xf105, 0xf106, 0xf107, 0xf108, 0xf109, 0xf208, 0xf204, 0xf307,
|
||||
0xf308, 0xf309, 0xf30b, 0xf304, 0xf305, 0xf306, 0xf30a, 0xf301,
|
||||
@@ -77,37 +125,69 @@ u_short ctrl_map[NR_KEYS] = {
|
||||
0xf10b, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
0xf30e, 0xf702, 0xf30d, 0xf01c, 0xf701, 0xf205, 0xf114, 0xf603,
|
||||
0xf118, 0xf601, 0xf602, 0xf117, 0xf600, 0xf119, 0xf115, 0xf116,
|
||||
- 0xf11a, 0xf10c, 0xf10d, 0xf11b, 0xf11c, 0xf110, 0xf311, 0xf11d,
|
||||
+ 0xf11a, 0xf10c, 0xf10b, 0xf10a, 0xf11c, 0xf110, 0xf311, 0xf11d,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
};
|
||||
|
||||
-u_short shift_ctrl_map[NR_KEYS] = {
|
||||
+static u_short shift_ctrl_map[NR_KEYS] = {
|
||||
0xf200, 0xf200, 0xf200, 0xf000, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
0xf200, 0xf200, 0xf200, 0xf200, 0xf01f, 0xf200, 0xf200, 0xf200,
|
||||
0xf011, 0xf017, 0xf005, 0xf012, 0xf014, 0xf019, 0xf015, 0xf009,
|
||||
- 0xf00f, 0xf010, 0xf200, 0xf200, 0xf201, 0xf702, 0xf001, 0xf013,
|
||||
+ 0xf00f, 0xf010, 0xf200, 0xf200, 0xf201, 0xf706, 0xf001, 0xf013,
|
||||
0xf004, 0xf006, 0xf007, 0xf008, 0xf00a, 0xf00b, 0xf00c, 0xf200,
|
||||
0xf200, 0xf200, 0xf700, 0xf200, 0xf01a, 0xf018, 0xf003, 0xf016,
|
||||
- 0xf002, 0xf00e, 0xf00d, 0xf200, 0xf200, 0xf200, 0xf700, 0xf30c,
|
||||
+ 0xf002, 0xf00e, 0xf00d, 0xf200, 0xf200, 0xf200, 0xf701, 0xf30c,
|
||||
0xf703, 0xf200, 0xf207, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf208, 0xf200, 0xf307,
|
||||
0xf308, 0xf309, 0xf30b, 0xf304, 0xf305, 0xf306, 0xf30a, 0xf301,
|
||||
0xf302, 0xf303, 0xf300, 0xf310, 0xf206, 0xf200, 0xf200, 0xf200,
|
||||
0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
- 0xf30e, 0xf702, 0xf30d, 0xf200, 0xf701, 0xf205, 0xf114, 0xf603,
|
||||
+ 0xf30e, 0xf702, 0xf30d, 0xf01c, 0xf701, 0xf205, 0xf114, 0xf603,
|
||||
0xf118, 0xf601, 0xf602, 0xf117, 0xf600, 0xf119, 0xf115, 0xf116,
|
||||
- 0xf11a, 0xf10c, 0xf10d, 0xf11b, 0xf11c, 0xf110, 0xf311, 0xf11d,
|
||||
+ 0xf11a, 0xf10c, 0xf200, 0xf200, 0xf11c, 0xf110, 0xf311, 0xf11d,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
};
|
||||
|
||||
-u_short alt_map[NR_KEYS] = {
|
||||
+static u_short alt_map[NR_KEYS] = {
|
||||
0xf200, 0xf81b, 0xf831, 0xf832, 0xf833, 0xf834, 0xf835, 0xf836,
|
||||
0xf837, 0xf838, 0xf839, 0xf830, 0xf82d, 0xf83d, 0xf87f, 0xf809,
|
||||
0xf871, 0xf877, 0xf865, 0xf872, 0xf874, 0xf879, 0xf875, 0xf869,
|
||||
- 0xf86f, 0xf870, 0xf85b, 0xf85d, 0xf80d, 0xf702, 0xf861, 0xf873,
|
||||
+ 0xf86f, 0xf870, 0xf85b, 0xf85d, 0xf80d, 0xf706, 0xf861, 0xf873,
|
||||
0xf864, 0xf866, 0xf867, 0xf868, 0xf86a, 0xf86b, 0xf86c, 0xf83b,
|
||||
0xf827, 0xf860, 0xf700, 0xf85c, 0xf87a, 0xf878, 0xf863, 0xf876,
|
||||
- 0xf862, 0xf86e, 0xf86d, 0xf82c, 0xf82e, 0xf82f, 0xf700, 0xf30c,
|
||||
+ 0xf862, 0xf86e, 0xf86d, 0xf200, 0xf200, 0xf82f, 0xf701, 0xf30c,
|
||||
0xf703, 0xf820, 0xf207, 0xf500, 0xf501, 0xf502, 0xf503, 0xf504,
|
||||
0xf505, 0xf506, 0xf507, 0xf508, 0xf509, 0xf208, 0xf209, 0xf907,
|
||||
0xf908, 0xf909, 0xf30b, 0xf904, 0xf905, 0xf906, 0xf30a, 0xf901,
|
||||
@@ -115,37 +195,117 @@ u_short alt_map[NR_KEYS] = {
|
||||
0xf50b, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
0xf30e, 0xf702, 0xf30d, 0xf01c, 0xf701, 0xf205, 0xf114, 0xf603,
|
||||
0xf118, 0xf210, 0xf211, 0xf117, 0xf600, 0xf119, 0xf115, 0xf116,
|
||||
- 0xf11a, 0xf10c, 0xf10d, 0xf11b, 0xf11c, 0xf110, 0xf311, 0xf11d,
|
||||
+ 0xf11a, 0xf10c, 0xf50b, 0xf50a, 0xf11c, 0xf110, 0xf311, 0xf11d,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
};
|
||||
|
||||
-u_short ctrl_alt_map[NR_KEYS] = {
|
||||
+static u_short ctrl_alt_map[NR_KEYS] = {
|
||||
0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
0xf811, 0xf817, 0xf805, 0xf812, 0xf814, 0xf819, 0xf815, 0xf809,
|
||||
- 0xf80f, 0xf810, 0xf200, 0xf200, 0xf201, 0xf702, 0xf801, 0xf813,
|
||||
+ 0xf80f, 0xf810, 0xf200, 0xf200, 0xf201, 0xf706, 0xf801, 0xf813,
|
||||
0xf804, 0xf806, 0xf807, 0xf808, 0xf80a, 0xf80b, 0xf80c, 0xf200,
|
||||
0xf200, 0xf200, 0xf700, 0xf200, 0xf81a, 0xf818, 0xf803, 0xf816,
|
||||
- 0xf802, 0xf80e, 0xf80d, 0xf200, 0xf200, 0xf200, 0xf700, 0xf30c,
|
||||
+ 0xf802, 0xf80e, 0xf80d, 0xf200, 0xf200, 0xf200, 0xf701, 0xf30c,
|
||||
0xf703, 0xf200, 0xf207, 0xf500, 0xf501, 0xf502, 0xf503, 0xf504,
|
||||
0xf505, 0xf506, 0xf507, 0xf508, 0xf509, 0xf208, 0xf200, 0xf307,
|
||||
0xf308, 0xf309, 0xf30b, 0xf304, 0xf305, 0xf306, 0xf30a, 0xf301,
|
||||
0xf302, 0xf303, 0xf300, 0xf20c, 0xf206, 0xf200, 0xf200, 0xf50a,
|
||||
0xf50b, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
- 0xf30e, 0xf702, 0xf30d, 0xf200, 0xf701, 0xf205, 0xf114, 0xf603,
|
||||
+ 0xf30e, 0xf702, 0xf30d, 0xf01c, 0xf701, 0xf205, 0xf114, 0xf603,
|
||||
0xf118, 0xf601, 0xf602, 0xf117, 0xf600, 0xf119, 0xf115, 0xf20c,
|
||||
- 0xf11a, 0xf10c, 0xf10d, 0xf11b, 0xf11c, 0xf110, 0xf311, 0xf11d,
|
||||
+ 0xf11a, 0xf10c, 0xf50b, 0xf50a, 0xf11c, 0xf110, 0xf311, 0xf11d,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+};
|
||||
+
|
||||
+static u_short ctl_map[NR_KEYS] = {
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf033, 0xf200, 0xf200,
|
||||
+ 0xfb71, 0xfb77, 0xfb65, 0xfb72, 0xfb74, 0xfb79, 0xf037, 0xf038,
|
||||
+ 0xf039, 0xfb70, 0xf200, 0xf200, 0xf201, 0xf706, 0xfb61, 0xfb73,
|
||||
+ 0xfb64, 0xfb66, 0xfb67, 0xfb68, 0xf034, 0xf035, 0xf036, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf700, 0xf200, 0xfb7a, 0xfb78, 0xfb63, 0xfb76,
|
||||
+ 0xfb62, 0xf031, 0xf032, 0xf200, 0xf200, 0xf030, 0xf701, 0xf30c,
|
||||
+ 0xf703, 0xf200, 0xf207, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf208, 0xf200, 0xf307,
|
||||
+ 0xf308, 0xf309, 0xf30b, 0xf304, 0xf305, 0xf306, 0xf30a, 0xf301,
|
||||
+ 0xf302, 0xf303, 0xf300, 0xf310, 0xf206, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf30e, 0xf702, 0xf30d, 0xf01c, 0xf701, 0xf205, 0xf114, 0xf603,
|
||||
+ 0xf118, 0xf601, 0xf602, 0xf117, 0xf600, 0xf119, 0xf115, 0xf116,
|
||||
+ 0xf11a, 0xf10c, 0xf200, 0xf200, 0xf11c, 0xf110, 0xf311, 0xf11d,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
+ 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200, 0xf200,
|
||||
};
|
||||
|
||||
ushort *key_maps[MAX_NR_KEYMAPS] = {
|
||||
- plain_map, shift_map, altgr_map, NULL,
|
||||
- ctrl_map, shift_ctrl_map, NULL, NULL,
|
||||
- alt_map, NULL, NULL, NULL,
|
||||
- ctrl_alt_map, NULL
|
||||
+ plain_map, shift_map, altgr_map, 0,
|
||||
+ ctrl_map, shift_ctrl_map, 0, 0,
|
||||
+ alt_map, 0, 0, 0,
|
||||
+ ctrl_alt_map, 0, 0, 0,
|
||||
+ 0, 0, 0, 0,
|
||||
+ 0, 0, 0, 0,
|
||||
+ 0, 0, 0, 0,
|
||||
+ 0, 0, 0, 0,
|
||||
+ 0, 0, 0, 0,
|
||||
+ 0, 0, 0, 0,
|
||||
+ 0, 0, 0, 0,
|
||||
+ 0, 0, 0, 0,
|
||||
+ 0, 0, 0, 0,
|
||||
+ 0, 0, 0, 0,
|
||||
+ 0, 0, 0, 0,
|
||||
+ 0, 0, 0, 0,
|
||||
+ ctl_map, 0
|
||||
};
|
||||
|
||||
-unsigned int keymap_count = 7;
|
||||
+unsigned int keymap_count = 8;
|
||||
|
||||
/*
|
||||
* Philosophy: most people do not define more strings, but they who do
|
||||
@@ -216,47 +376,47 @@ char *func_table[MAX_NR_FUNC] = {
|
||||
func_buf + 135,
|
||||
func_buf + 140,
|
||||
func_buf + 145,
|
||||
- NULL,
|
||||
- NULL,
|
||||
+ 0,
|
||||
+ 0,
|
||||
func_buf + 149,
|
||||
- NULL,
|
||||
+ 0,
|
||||
};
|
||||
|
||||
-struct kbdiacruc accent_table[MAX_DIACR] = {
|
||||
- {'`', 'A', 0300}, {'`', 'a', 0340},
|
||||
- {'\'', 'A', 0301}, {'\'', 'a', 0341},
|
||||
- {'^', 'A', 0302}, {'^', 'a', 0342},
|
||||
- {'~', 'A', 0303}, {'~', 'a', 0343},
|
||||
- {'"', 'A', 0304}, {'"', 'a', 0344},
|
||||
- {'O', 'A', 0305}, {'o', 'a', 0345},
|
||||
- {'0', 'A', 0305}, {'0', 'a', 0345},
|
||||
- {'A', 'A', 0305}, {'a', 'a', 0345},
|
||||
- {'A', 'E', 0306}, {'a', 'e', 0346},
|
||||
- {',', 'C', 0307}, {',', 'c', 0347},
|
||||
- {'`', 'E', 0310}, {'`', 'e', 0350},
|
||||
- {'\'', 'E', 0311}, {'\'', 'e', 0351},
|
||||
- {'^', 'E', 0312}, {'^', 'e', 0352},
|
||||
- {'"', 'E', 0313}, {'"', 'e', 0353},
|
||||
- {'`', 'I', 0314}, {'`', 'i', 0354},
|
||||
- {'\'', 'I', 0315}, {'\'', 'i', 0355},
|
||||
- {'^', 'I', 0316}, {'^', 'i', 0356},
|
||||
- {'"', 'I', 0317}, {'"', 'i', 0357},
|
||||
- {'-', 'D', 0320}, {'-', 'd', 0360},
|
||||
- {'~', 'N', 0321}, {'~', 'n', 0361},
|
||||
- {'`', 'O', 0322}, {'`', 'o', 0362},
|
||||
- {'\'', 'O', 0323}, {'\'', 'o', 0363},
|
||||
- {'^', 'O', 0324}, {'^', 'o', 0364},
|
||||
- {'~', 'O', 0325}, {'~', 'o', 0365},
|
||||
- {'"', 'O', 0326}, {'"', 'o', 0366},
|
||||
- {'/', 'O', 0330}, {'/', 'o', 0370},
|
||||
- {'`', 'U', 0331}, {'`', 'u', 0371},
|
||||
- {'\'', 'U', 0332}, {'\'', 'u', 0372},
|
||||
- {'^', 'U', 0333}, {'^', 'u', 0373},
|
||||
- {'"', 'U', 0334}, {'"', 'u', 0374},
|
||||
- {'\'', 'Y', 0335}, {'\'', 'y', 0375},
|
||||
- {'T', 'H', 0336}, {'t', 'h', 0376},
|
||||
- {'s', 's', 0337}, {'"', 'y', 0377},
|
||||
- {'s', 'z', 0337}, {'i', 'j', 0377},
|
||||
+struct kbdiacr accent_table[MAX_DIACR] = {
|
||||
+ {'`', 'A', '\300'}, {'`', 'a', '\340'},
|
||||
+ {'\'', 'A', '\301'}, {'\'', 'a', '\341'},
|
||||
+ {'^', 'A', '\302'}, {'^', 'a', '\342'},
|
||||
+ {'~', 'A', '\303'}, {'~', 'a', '\343'},
|
||||
+ {'"', 'A', '\304'}, {'"', 'a', '\344'},
|
||||
+ {'O', 'A', '\305'}, {'o', 'a', '\345'},
|
||||
+ {'0', 'A', '\305'}, {'0', 'a', '\345'},
|
||||
+ {'A', 'A', '\305'}, {'a', 'a', '\345'},
|
||||
+ {'A', 'E', '\306'}, {'a', 'e', '\346'},
|
||||
+ {',', 'C', '\307'}, {',', 'c', '\347'},
|
||||
+ {'`', 'E', '\310'}, {'`', 'e', '\350'},
|
||||
+ {'\'', 'E', '\311'}, {'\'', 'e', '\351'},
|
||||
+ {'^', 'E', '\312'}, {'^', 'e', '\352'},
|
||||
+ {'"', 'E', '\313'}, {'"', 'e', '\353'},
|
||||
+ {'`', 'I', '\314'}, {'`', 'i', '\354'},
|
||||
+ {'\'', 'I', '\315'}, {'\'', 'i', '\355'},
|
||||
+ {'^', 'I', '\316'}, {'^', 'i', '\356'},
|
||||
+ {'"', 'I', '\317'}, {'"', 'i', '\357'},
|
||||
+ {'-', 'D', '\320'}, {'-', 'd', '\360'},
|
||||
+ {'~', 'N', '\321'}, {'~', 'n', '\361'},
|
||||
+ {'`', 'O', '\322'}, {'`', 'o', '\362'},
|
||||
+ {'\'', 'O', '\323'}, {'\'', 'o', '\363'},
|
||||
+ {'^', 'O', '\324'}, {'^', 'o', '\364'},
|
||||
+ {'~', 'O', '\325'}, {'~', 'o', '\365'},
|
||||
+ {'"', 'O', '\326'}, {'"', 'o', '\366'},
|
||||
+ {'/', 'O', '\330'}, {'/', 'o', '\370'},
|
||||
+ {'`', 'U', '\331'}, {'`', 'u', '\371'},
|
||||
+ {'\'', 'U', '\332'}, {'\'', 'u', '\372'},
|
||||
+ {'^', 'U', '\333'}, {'^', 'u', '\373'},
|
||||
+ {'"', 'U', '\334'}, {'"', 'u', '\374'},
|
||||
+ {'\'', 'Y', '\335'}, {'\'', 'y', '\375'},
|
||||
+ {'T', 'H', '\336'}, {'t', 'h', '\376'},
|
||||
+ {'s', 's', '\337'}, {'"', 'y', '\377'},
|
||||
+ {'s', 'z', '\337'}, {'i', 'j', '\377'},
|
||||
};
|
||||
|
||||
unsigned int accent_table_size = 68;
|
||||
diff --git a/drivers/tty/vt/defkeymap.map b/drivers/tty/vt/defkeymap.map
|
||||
index 50b30ca..732f395 100644
|
||||
--- a/drivers/tty/vt/defkeymap.map
|
||||
+++ b/drivers/tty/vt/defkeymap.map
|
||||
@@ -1,5 +1,5 @@
|
||||
# Default kernel keymap. This uses 7 modifier combinations.
|
||||
-keymaps 0-2,4-5,8,12
|
||||
+keymaps 0-2,4-5,8,12,64
|
||||
# Change the above line into
|
||||
# keymaps 0-2,4-6,8,12
|
||||
# in case you want the entries
|
||||
@@ -45,24 +45,38 @@ keycode 12 = minus underscore backslash
|
||||
control keycode 12 = Control_underscore
|
||||
shift control keycode 12 = Control_underscore
|
||||
alt keycode 12 = Meta_minus
|
||||
-keycode 13 = equal plus
|
||||
+keycode 13 = equal plus
|
||||
alt keycode 13 = Meta_equal
|
||||
+ altgr keycode 13 = asciitilde
|
||||
+ ctrll keycode 13 = three
|
||||
keycode 14 = Delete Delete
|
||||
- control keycode 14 = BackSpace
|
||||
+ altgr keycode 14 = Remove
|
||||
alt keycode 14 = Meta_Delete
|
||||
keycode 15 = Tab Tab
|
||||
alt keycode 15 = Meta_Tab
|
||||
keycode 16 = q
|
||||
+ altgr keycode 16 = exclam
|
||||
keycode 17 = w
|
||||
+ altgr keycode 17 = at
|
||||
keycode 18 = e
|
||||
- altgr keycode 18 = Hex_E
|
||||
+ altgr keycode 18 = numbersign
|
||||
keycode 19 = r
|
||||
+ altgr keycode 19 = dollar
|
||||
keycode 20 = t
|
||||
+ altgr keycode 20 = percent
|
||||
keycode 21 = y
|
||||
+ altgr keycode 21 = asciicircum
|
||||
keycode 22 = u
|
||||
+ altgr keycode 22 = ampersand
|
||||
+ ctrll keycode 22 = seven
|
||||
keycode 23 = i
|
||||
+ altgr keycode 23 = asterisk
|
||||
+ ctrll keycode 23 = eight
|
||||
keycode 24 = o
|
||||
+ altgr keycode 24 = parenleft
|
||||
+ ctrll keycode 24 = nine
|
||||
keycode 25 = p
|
||||
+ altgr keycode 25 = parenright
|
||||
keycode 26 = bracketleft braceleft
|
||||
control keycode 26 = Escape
|
||||
alt keycode 26 = Meta_bracketleft
|
||||
@@ -71,19 +85,28 @@ keycode 27 = bracketright braceright asciitilde
|
||||
alt keycode 27 = Meta_bracketright
|
||||
keycode 28 = Return
|
||||
alt keycode 28 = Meta_Control_m
|
||||
-keycode 29 = Control
|
||||
+keycode 29 = CtrlL
|
||||
keycode 30 = a
|
||||
- altgr keycode 30 = Hex_A
|
||||
+ altgr keycode 30 = U+00B0
|
||||
keycode 31 = s
|
||||
+ altgr keycode 31 = U+00A8
|
||||
keycode 32 = d
|
||||
- altgr keycode 32 = Hex_D
|
||||
+ altgr keycode 32 = U+20AC
|
||||
keycode 33 = f
|
||||
- altgr keycode 33 = Hex_F
|
||||
+ altgr keycode 33 = minus
|
||||
keycode 34 = g
|
||||
+ altgr keycode 34 = underscore
|
||||
keycode 35 = h
|
||||
+ altgr keycode 35 = braceleft
|
||||
keycode 36 = j
|
||||
+ altgr keycode 36 = bracketleft
|
||||
+ ctrll keycode 36 = four
|
||||
keycode 37 = k
|
||||
+ altgr keycode 37 = bracketright
|
||||
+ ctrll keycode 37 = five
|
||||
keycode 38 = l
|
||||
+ altgr keycode 38 = braceright
|
||||
+ ctrll keycode 38 = six
|
||||
keycode 39 = semicolon colon
|
||||
alt keycode 39 = Meta_semicolon
|
||||
keycode 40 = apostrophe quotedbl
|
||||
@@ -97,58 +120,65 @@ keycode 43 = backslash bar
|
||||
control keycode 43 = Control_backslash
|
||||
alt keycode 43 = Meta_backslash
|
||||
keycode 44 = z
|
||||
+ altgr keycode 44 = nine
|
||||
keycode 45 = x
|
||||
+ altgr keycode 45 = zero
|
||||
keycode 46 = c
|
||||
altgr keycode 46 = Hex_C
|
||||
keycode 47 = v
|
||||
keycode 48 = b
|
||||
altgr keycode 48 = Hex_B
|
||||
keycode 49 = n
|
||||
+ altgr keycode 49 = less
|
||||
+ ctrll keycode 49 = one
|
||||
keycode 50 = m
|
||||
-keycode 51 = comma less
|
||||
- alt keycode 51 = Meta_comma
|
||||
-keycode 52 = period greater
|
||||
+ altgr keycode 50 = greater
|
||||
+ ctrll keycode 50 = two
|
||||
+keycode 51 = comma semicolon
|
||||
+ altgr keycode 51 = apostrophe
|
||||
+keycode 52 = period colon
|
||||
control keycode 52 = Compose
|
||||
- alt keycode 52 = Meta_period
|
||||
+ altgr keycode 52 = quotedbl
|
||||
keycode 53 = slash question
|
||||
control keycode 53 = Delete
|
||||
alt keycode 53 = Meta_slash
|
||||
-keycode 54 = Shift
|
||||
+ ctrll keycode 53 = zero
|
||||
+keycode 54 = AltGr
|
||||
keycode 55 = KP_Multiply
|
||||
keycode 56 = Alt
|
||||
keycode 57 = space space
|
||||
control keycode 57 = nul
|
||||
alt keycode 57 = Meta_space
|
||||
keycode 58 = Caps_Lock
|
||||
-keycode 59 = F1 F11 Console_13
|
||||
+keycode 59 = F1 F11 one
|
||||
control keycode 59 = F1
|
||||
alt keycode 59 = Console_1
|
||||
control alt keycode 59 = Console_1
|
||||
-keycode 60 = F2 F12 Console_14
|
||||
+keycode 60 = F2 F12 two
|
||||
control keycode 60 = F2
|
||||
alt keycode 60 = Console_2
|
||||
control alt keycode 60 = Console_2
|
||||
-keycode 61 = F3 F13 Console_15
|
||||
+keycode 61 = F3 F13 three
|
||||
control keycode 61 = F3
|
||||
alt keycode 61 = Console_3
|
||||
control alt keycode 61 = Console_3
|
||||
-keycode 62 = F4 F14 Console_16
|
||||
+keycode 62 = F4 F14 four
|
||||
control keycode 62 = F4
|
||||
alt keycode 62 = Console_4
|
||||
control alt keycode 62 = Console_4
|
||||
-keycode 63 = F5 F15 Console_17
|
||||
+keycode 63 = F5 F15 five
|
||||
control keycode 63 = F5
|
||||
alt keycode 63 = Console_5
|
||||
control alt keycode 63 = Console_5
|
||||
-keycode 64 = F6 F16 Console_18
|
||||
+keycode 64 = F6 F16 six
|
||||
control keycode 64 = F6
|
||||
alt keycode 64 = Console_6
|
||||
control alt keycode 64 = Console_6
|
||||
-keycode 65 = F7 F17 Console_19
|
||||
+keycode 65 = F7 F17 seven
|
||||
control keycode 65 = F7
|
||||
alt keycode 65 = Console_7
|
||||
control alt keycode 65 = Console_7
|
||||
-keycode 66 = F8 F18 Console_20
|
||||
+keycode 66 = F8 F18 eight
|
||||
control keycode 66 = F8
|
||||
alt keycode 66 = Console_8
|
||||
control alt keycode 66 = Console_8
|
||||
@@ -204,11 +234,11 @@ keycode 84 = Last_Console
|
||||
keycode 85 =
|
||||
keycode 86 = less greater bar
|
||||
alt keycode 86 = Meta_less
|
||||
-keycode 87 = F11 F11 Console_23
|
||||
+keycode 87 = F11 Scroll_Backward Console_23
|
||||
control keycode 87 = F11
|
||||
alt keycode 87 = Console_11
|
||||
control alt keycode 87 = Console_11
|
||||
-keycode 88 = F12 F12 Console_24
|
||||
+keycode 88 = F12 Scroll_Forward Console_24
|
||||
control keycode 88 = F12
|
||||
alt keycode 88 = Console_12
|
||||
control alt keycode 88 = Console_12
|
||||
@@ -220,7 +250,7 @@ keycode 93 =
|
||||
keycode 94 =
|
||||
keycode 95 =
|
||||
keycode 96 = KP_Enter
|
||||
-keycode 97 = Control
|
||||
+keycode 97 = Control
|
||||
keycode 98 = KP_Divide
|
||||
keycode 99 = Control_backslash
|
||||
control keycode 99 = Control_backslash
|
||||
@@ -245,8 +275,14 @@ keycode 111 = Remove
|
||||
control alt keycode 111 = Boot
|
||||
keycode 112 = Macro
|
||||
keycode 113 = F13
|
||||
-keycode 114 = F14
|
||||
-keycode 115 = Help
|
||||
+keycode 114 = F12 Scroll_Forward Console_24
|
||||
+ control keycode 114 = F12
|
||||
+ alt keycode 114 = Console_12
|
||||
+ control alt keycode 114 = Console_12
|
||||
+keycode 115 = F11 Scroll_Backward Console_23
|
||||
+ control keycode 115 = F11
|
||||
+ alt keycode 115 = Console_11
|
||||
+ control alt keycode 115 = Console_11
|
||||
keycode 116 = Do
|
||||
keycode 117 = F17
|
||||
keycode 118 = KP_MinPlus
|
||||
--
|
||||
1.7.5.4
|
||||
|
@ -0,0 +1,320 @@
|
||||
From 44cb778f4b2c6febb91631243c73f89a91c2f1ca Mon Sep 17 00:00:00 2001
|
||||
From: Xiangfu Liu <xiangfu@sharism.cc>
|
||||
Date: Tue, 18 Oct 2011 09:21:04 +0800
|
||||
Subject: [PATCH 24/28] fbcon-color-fonts
|
||||
|
||||
---
|
||||
drivers/tty/vt/vt.c | 3 +-
|
||||
drivers/video/console/bitblit.c | 188 +++++++++++++++++++++++++++++++++------
|
||||
drivers/video/console/fbcon.c | 14 +++-
|
||||
3 files changed, 173 insertions(+), 32 deletions(-)
|
||||
|
||||
diff --git a/drivers/tty/vt/vt.c b/drivers/tty/vt/vt.c
|
||||
index e716839..298f727 100644
|
||||
--- a/drivers/tty/vt/vt.c
|
||||
+++ b/drivers/tty/vt/vt.c
|
||||
@@ -4034,6 +4034,7 @@ static int con_font_set(struct vc_data *vc, struct console_font_op *op)
|
||||
struct console_font font;
|
||||
int rc = -EINVAL;
|
||||
int size;
|
||||
+ u8 std_font = *((u32*)op->data) != 0x6a127efd;
|
||||
|
||||
if (vc->vc_mode != KD_TEXT)
|
||||
return -EINVAL;
|
||||
@@ -4063,7 +4064,7 @@ static int con_font_set(struct vc_data *vc, struct console_font_op *op)
|
||||
}
|
||||
if (op->width <= 0 || op->width > 32 || op->height > 32)
|
||||
return -EINVAL;
|
||||
- size = (op->width+7)/8 * 32 * op->charcount;
|
||||
+ size = ( std_font ? (op->width+7)/8 * 32 : 4 * op->width * op->height) * op->charcount;
|
||||
if (size > max_font_size)
|
||||
return -ENOSPC;
|
||||
font.charcount = op->charcount;
|
||||
diff --git a/drivers/video/console/bitblit.c b/drivers/video/console/bitblit.c
|
||||
index 28b1a83..8e559df 100644
|
||||
--- a/drivers/video/console/bitblit.c
|
||||
+++ b/drivers/video/console/bitblit.c
|
||||
@@ -105,6 +105,12 @@ static inline void bit_putcs_aligned(struct vc_data *vc, struct fb_info *info,
|
||||
info->fbops->fb_imageblit(info, image);
|
||||
}
|
||||
|
||||
+/* info: details of the framebuffer
|
||||
+ * image: the off-screen image in which the character (sub)string is being
|
||||
+ * prepared
|
||||
+ * dst: a pointer to the top-left pixel in the off-screen image where the
|
||||
+ * character (sub)string should go
|
||||
+ */
|
||||
static inline void bit_putcs_unaligned(struct vc_data *vc,
|
||||
struct fb_info *info, const u16 *s,
|
||||
u32 attr, u32 cnt, u32 d_pitch,
|
||||
@@ -140,12 +146,62 @@ static inline void bit_putcs_unaligned(struct vc_data *vc,
|
||||
|
||||
}
|
||||
|
||||
+void inline draw_glyph_row_inv( int pixels_across_glyph, u8 *src, u8 *target) {
|
||||
+ u32 *pixel_on_glyph_sheet = (u32*) src;
|
||||
+ u32 *pixel_on_screen = (u32*) target;
|
||||
+
|
||||
+ while( pixels_across_glyph--) {
|
||||
+ *pixel_on_screen = ~(*pixel_on_glyph_sheet);
|
||||
+ ++ pixel_on_glyph_sheet;
|
||||
+ ++ pixel_on_screen;
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
+void inline draw_glyph_row_75( int pixels_across_glyph, u8 *src, u8 *target) {
|
||||
+ u32 pixel;
|
||||
+ u32 *pixel_on_glyph_sheet = (u32*) src;
|
||||
+ u32 *pixel_on_screen = (u32*) target;
|
||||
+ /* Copy the pixels at 75% brightness */
|
||||
+ while( pixels_across_glyph--) {
|
||||
+ pixel = *pixel_on_glyph_sheet;
|
||||
+ /* This is a cheeky way of multiplying by 0.75 */
|
||||
+ pixel = ( pixel >> 1) & 0x7f7f7f7f;
|
||||
+ pixel += ( pixel >> 1) & 0x7f7f7f7f;
|
||||
+ *pixel_on_screen = pixel;
|
||||
+ ++ pixel_on_glyph_sheet;
|
||||
+ ++ pixel_on_screen;
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
+/*
|
||||
+ * width: the number of bytes required to store a single row of pixels from
|
||||
+ * a glyph
|
||||
+ * cellsize: the number of bytes required to store the pixels for a single
|
||||
+ * glyph
|
||||
+ * maxcnt: the maximum number of characters that can be blasted to the screen
|
||||
+ * at one time ( limited by the amount of video RAM available for a
|
||||
+ * (sub)string of characters)
|
||||
+ * The NanoNote has 32-bits per pixel arranged BGRA
|
||||
+ * info->fix.line_length: the number of bytes to advance through the frame
|
||||
+ * buffer in order to get from the address of a pixel to
|
||||
+ * the address of the pixel directly below it
|
||||
+ * screen_row_hop: the number of 32-bit words to advance through the frame
|
||||
+ * buffer in order to get from the address of a pixel to the
|
||||
+ * address of the pixel directly below it on the screen
|
||||
+ * glyph_on_screen: the address of the pixel on screen where the top-left of
|
||||
+ * the next glyph should go
|
||||
+ * row_on_screen: the address of the pixel on screen where the next row of
|
||||
+ * pixels from the glyph should go
|
||||
+ * row_on_glyph_sheet: pointer within font.data ( the glyph sheet) of the
|
||||
+ * left-most pixel from the next row to be drawn
|
||||
+ */
|
||||
static void bit_putcs(struct vc_data *vc, struct fb_info *info,
|
||||
const unsigned short *s, int count, int yy, int xx,
|
||||
int fg, int bg)
|
||||
{
|
||||
struct fb_image image;
|
||||
- u32 width = DIV_ROUND_UP(vc->vc_font.width, 8);
|
||||
+ u8 std_font = *((u32*)vc->vc_font.data) != 0x6a127efd;
|
||||
+ u32 width = std_font ? DIV_ROUND_UP(vc->vc_font.width, 8) : 4 * vc->vc_font.width;
|
||||
u32 cellsize = width * vc->vc_font.height;
|
||||
u32 maxcnt = info->pixmap.size/cellsize;
|
||||
u32 scan_align = info->pixmap.scan_align - 1;
|
||||
@@ -153,6 +209,10 @@ static void bit_putcs(struct vc_data *vc, struct fb_info *info,
|
||||
u32 mod = vc->vc_font.width % 8, cnt, pitch, size;
|
||||
u32 attribute = get_attribute(info, scr_readw(s));
|
||||
u8 *dst, *buf = NULL;
|
||||
+ u32 screen_row_hop;
|
||||
+ u16 charmask;
|
||||
+ u8 *row_on_glyph_sheet, *glyph_on_screen, *row_on_screen;
|
||||
+ u8 code_point, rows_left;
|
||||
|
||||
image.fg_color = fg;
|
||||
image.bg_color = bg;
|
||||
@@ -167,31 +227,73 @@ static void bit_putcs(struct vc_data *vc, struct fb_info *info,
|
||||
return;
|
||||
}
|
||||
|
||||
- while (count) {
|
||||
- if (count > maxcnt)
|
||||
- cnt = maxcnt;
|
||||
- else
|
||||
- cnt = count;
|
||||
-
|
||||
- image.width = vc->vc_font.width * cnt;
|
||||
- pitch = DIV_ROUND_UP(image.width, 8) + scan_align;
|
||||
- pitch &= ~scan_align;
|
||||
- size = pitch * image.height + buf_align;
|
||||
- size &= ~buf_align;
|
||||
- dst = fb_get_buffer_offset(info, &info->pixmap, size);
|
||||
- image.data = dst;
|
||||
-
|
||||
- if (!mod)
|
||||
- bit_putcs_aligned(vc, info, s, attribute, cnt, pitch,
|
||||
- width, cellsize, &image, buf, dst);
|
||||
- else
|
||||
- bit_putcs_unaligned(vc, info, s, attribute, cnt,
|
||||
- pitch, width, cellsize, &image,
|
||||
- buf, dst);
|
||||
-
|
||||
- image.dx += cnt * vc->vc_font.width;
|
||||
- count -= cnt;
|
||||
- s += cnt;
|
||||
+ if ( std_font) {
|
||||
+ while (count) {
|
||||
+ if (count > maxcnt)
|
||||
+ cnt = maxcnt;
|
||||
+ else
|
||||
+ cnt = count;
|
||||
+
|
||||
+ image.width = vc->vc_font.width * cnt;
|
||||
+ pitch = DIV_ROUND_UP(image.width, 8) + scan_align;
|
||||
+ pitch &= ~scan_align;
|
||||
+ size = pitch * image.height + buf_align;
|
||||
+ size &= ~buf_align;
|
||||
+ dst = fb_get_buffer_offset(info, &info->pixmap, size);
|
||||
+ image.data = dst;
|
||||
+
|
||||
+ if (!mod)
|
||||
+ bit_putcs_aligned(vc, info, s, attribute, cnt,
|
||||
+ pitch, width, cellsize,
|
||||
+ &image, buf, dst);
|
||||
+ else
|
||||
+ bit_putcs_unaligned(vc, info, s, attribute, cnt,
|
||||
+ pitch, width, cellsize,
|
||||
+ &image, buf, dst);
|
||||
+
|
||||
+ image.dx += cnt * vc->vc_font.width;
|
||||
+ count -= cnt;
|
||||
+ s += cnt;
|
||||
+ }
|
||||
+ }
|
||||
+ else { /* The font is not a standard 1-bit font */
|
||||
+ charmask = vc->vc_hi_font_mask ? 0x1ff : 0xff;
|
||||
+ screen_row_hop = info->fix.line_length;
|
||||
+ glyph_on_screen = info->screen_base +
|
||||
+ screen_row_hop * image.dy +
|
||||
+ 4 * image.dx;
|
||||
+ /* While there are still characters to draw.. */
|
||||
+ while (count--) {
|
||||
+ code_point = scr_readw(s++) & charmask;
|
||||
+ row_on_glyph_sheet = vc->vc_font.data +
|
||||
+ cellsize * code_point;
|
||||
+ /* Draw every row of the glyph */
|
||||
+ row_on_screen = glyph_on_screen;
|
||||
+ rows_left = vc->vc_font.height;
|
||||
+ while( rows_left--)
|
||||
+ {
|
||||
+ /* If the background color is NOT black then do
|
||||
+ * reverse video */
|
||||
+ if ( 0 < bg) {
|
||||
+ draw_glyph_row_inv( vc->vc_font.width,
|
||||
+ row_on_glyph_sheet,
|
||||
+ row_on_screen);
|
||||
+ }
|
||||
+ /* If the foreground color is high-intensity */
|
||||
+ else if ( 8 <= fg) {
|
||||
+ memcpy( row_on_screen,
|
||||
+ row_on_glyph_sheet, width);
|
||||
+ }
|
||||
+ else {
|
||||
+ draw_glyph_row_75( vc->vc_font.width,
|
||||
+ row_on_glyph_sheet,
|
||||
+ row_on_screen);
|
||||
+ }
|
||||
+ row_on_glyph_sheet += width;
|
||||
+ row_on_screen += screen_row_hop;
|
||||
+ }
|
||||
+ glyph_on_screen += width;
|
||||
+ }
|
||||
}
|
||||
|
||||
/* buf is always NULL except when in monochrome mode, so in this case
|
||||
@@ -234,6 +336,29 @@ static void bit_clear_margins(struct vc_data *vc, struct fb_info *info,
|
||||
}
|
||||
}
|
||||
|
||||
+static void bgra_cursor( struct vc_data *vc, struct fb_info *info, short c,
|
||||
+ struct fb_cursor *cursor)
|
||||
+{
|
||||
+ u32 x = cursor->image.dx;
|
||||
+ u32 y = cursor->image.dy;
|
||||
+ u32 gw = vc->vc_font.width;
|
||||
+ u32 gh = vc->vc_font.height;
|
||||
+ u32 *pixel;
|
||||
+
|
||||
+ /* Draw the glyph to the screen */
|
||||
+ bit_putcs( vc, info, &c, 1, y/gh, x/gw, 0, 0);
|
||||
+
|
||||
+ if ( cursor->enable) {
|
||||
+ /* Invert the last row of pixels */
|
||||
+ pixel = (u32*) ( info->screen_base +
|
||||
+ info->fix.line_length * ( y + gh - 1) + 4 * x);
|
||||
+ while ( gw--) {
|
||||
+ *pixel ^= 0xffffffff;
|
||||
+ ++ pixel;
|
||||
+ }
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
static void bit_cursor(struct vc_data *vc, struct fb_info *info, int mode,
|
||||
int softback_lines, int fg, int bg)
|
||||
{
|
||||
@@ -245,6 +370,7 @@ static void bit_cursor(struct vc_data *vc, struct fb_info *info, int mode,
|
||||
int attribute, use_sw = (vc->vc_cursor_type & 0x10);
|
||||
int err = 1;
|
||||
char *src;
|
||||
+ u8 std_font = *((u32*)vc->vc_font.data) != 0x6a127efd;
|
||||
|
||||
cursor.set = 0;
|
||||
|
||||
@@ -383,8 +509,14 @@ static void bit_cursor(struct vc_data *vc, struct fb_info *info, int mode,
|
||||
if (info->fbops->fb_cursor)
|
||||
err = info->fbops->fb_cursor(info, &cursor);
|
||||
|
||||
- if (err)
|
||||
- soft_cursor(info, &cursor);
|
||||
+ if (err) {
|
||||
+ if ( std_font) {
|
||||
+ soft_cursor(info, &cursor);
|
||||
+ }
|
||||
+ else {
|
||||
+ bgra_cursor( vc, info, c, &cursor);
|
||||
+ }
|
||||
+ }
|
||||
|
||||
ops->cursor_reset = 0;
|
||||
}
|
||||
diff --git a/drivers/video/console/fbcon.c b/drivers/video/console/fbcon.c
|
||||
index 8745637..dea9d2c 100644
|
||||
--- a/drivers/video/console/fbcon.c
|
||||
+++ b/drivers/video/console/fbcon.c
|
||||
@@ -2552,7 +2552,8 @@ static int fbcon_set_font(struct vc_data *vc, struct console_font *font, unsigne
|
||||
int size;
|
||||
int i, csum;
|
||||
u8 *new_data, *data = font->data;
|
||||
- int pitch = (font->width+7) >> 3;
|
||||
+ u8 std_font = *((u32*)data) != 0x6a127efd;
|
||||
+ int pitch = std_font ? (font->width+7) >> 3 : 4 * font->width;
|
||||
|
||||
/* Is there a reason why fbconsole couldn't handle any charcount >256?
|
||||
* If not this check should be changed to charcount < 256 */
|
||||
@@ -2571,6 +2572,7 @@ static int fbcon_set_font(struct vc_data *vc, struct console_font *font, unsigne
|
||||
size = h * pitch * charcount;
|
||||
|
||||
new_data = kmalloc(FONT_EXTRA_WORDS * sizeof(int) + size, GFP_USER);
|
||||
+ DPRINTK(KERN_INFO "fbcon_set_font size:%d\n", size);
|
||||
|
||||
if (!new_data)
|
||||
return -ENOMEM;
|
||||
@@ -2579,8 +2581,14 @@ static int fbcon_set_font(struct vc_data *vc, struct console_font *font, unsigne
|
||||
FNTSIZE(new_data) = size;
|
||||
FNTCHARCNT(new_data) = charcount;
|
||||
REFCOUNT(new_data) = 0; /* usage counter */
|
||||
- for (i=0; i< charcount; i++) {
|
||||
- memcpy(new_data + i*h*pitch, data + i*32*pitch, h*pitch);
|
||||
+ if ( std_font) {
|
||||
+ for (i=0; i< charcount; i++) {
|
||||
+ memcpy(new_data + i*h*pitch, data + i*32*pitch,
|
||||
+ h*pitch);
|
||||
+ }
|
||||
+ }
|
||||
+ else {
|
||||
+ memcpy( new_data, data, size);
|
||||
}
|
||||
|
||||
/* Since linux has a nice crc32 function use it for counting font
|
||||
--
|
||||
1.7.5.4
|
||||
|
Loading…
Reference in New Issue
Block a user