mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
Input: amikbd - allocate temporary keymap buffer on the stack
Allocate the temporary buffer needed for initialization of the console keyboard maps (512 bytes, as NR_KEYS = 256) on the stack instead of statically, to reduce kernel size. add/remove: 0/1 grow/shrink: 0/0 up/down: 0/-512 (-512) function old new delta temp_map 512 - -512 Signed-off-by: Geert Uytterhoeven <[email protected]> Signed-off-by: Dmitry Torokhov <[email protected]>
This commit is contained in:
parent
545e625325
commit
e147af492e
1 changed files with 2 additions and 1 deletions
|
|
@ -147,10 +147,11 @@ static unsigned char amikbd_keycode[0x78] __initdata = {
|
|||
|
||||
static void __init amikbd_init_console_keymaps(void)
|
||||
{
|
||||
/* We can spare 512 bytes on stack for temp_map in init path. */
|
||||
unsigned short temp_map[NR_KEYS];
|
||||
int i, j;
|
||||
|
||||
for (i = 0; i < MAX_NR_KEYMAPS; i++) {
|
||||
static u_short temp_map[NR_KEYS] __initdata;
|
||||
if (!key_maps[i])
|
||||
continue;
|
||||
memset(temp_map, 0, sizeof(temp_map));
|
||||
|
|
|
|||
Loading…
Reference in a new issue