Changeset f8d5b85 in mainline


Ignore:
Timestamp:
2006-06-13T11:04:16Z (18 years ago)
Author:
Jakub Vana <jakub.vana@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
0384428
Parents:
15039b67
Message:

Kbd patch for gxemul with no framebuffer

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kbd/arch/mips32/src/kbd.c

    r15039b67 rf8d5b85  
    8181
    8282static int msim,gxemul;
     83static int fb_fb;
     84
    8385
    8486int kbd_arch_init(void)
    8587{
     88        fb_fb=sysinfo_value("fb.kind")==1;
    8689        ipc_register_irq(2, &msim_kbd);
    87         msim=sysinfo_value("machine.msim");
    88         gxemul=sysinfo_value("machine.lgxemul");
    8990        return 0;
    9091}
    9192
    9293
    93 //*
     94/*
    9495//*
    9596//* Please preserve this code (it can be used to determine scancodes)
     
    99100        return "0123456789ABCDEF"[v];
    100101}
    101 //*/
    102 
    103 static int kbd_arch_process_msim(keybuffer_t *keybuffer, int scan_code)
     102*/
     103
     104static int kbd_arch_process_no_fb(keybuffer_t *keybuffer, int scan_code)
    104105{
    105106
     
    108109
    109110
    110         //* Please preserve this code (it can be used to determine scancodes)
    111         //*
    112         //keybuffer_push(keybuffer, to_hex((scan_code>>4)&0xf));
    113         //keybuffer_push(keybuffer, to_hex(scan_code&0xf));
    114         //keybuffer_push(keybuffer, ' ');
    115         //keybuffer_push(keybuffer, ' ');
    116         //*/
    117         //return 1;
    118        
     111        /* Please preserve this code (it can be used to determine scancodes)
     112       
     113        keybuffer_push(keybuffer, to_hex((scan_code>>4)&0xf));
     114        keybuffer_push(keybuffer, to_hex(scan_code&0xf));
     115        keybuffer_push(keybuffer, ' ');
     116        keybuffer_push(keybuffer, ' ');
     117       
     118        return 1;
     119        */
    119120       
    120121        if(scan_code==0x7e)
     
    252253
    253254
    254 static int kbd_arch_process_gxemul(keybuffer_t *keybuffer, int scan_code)
     255static int kbd_arch_process_fb(keybuffer_t *keybuffer, int scan_code)
    255256{
    256257
     
    259260
    260261
    261         //* Please preserve this code (it can be used to determine scancodes)
    262         //*
    263         //keybuffer_push(keybuffer, to_hex((scan_code>>4)&0xf));
    264         //keybuffer_push(keybuffer, to_hex(scan_code&0xf));
    265         //keybuffer_push(keybuffer, ' ');
    266         //keybuffer_push(keybuffer, ' ');
    267         //*/
    268         //return 1;
    269        
     262        /* Please preserve this code (it can be used to determine scancodes)
     263       
     264        keybuffer_push(keybuffer, to_hex((scan_code>>4)&0xf));
     265        keybuffer_push(keybuffer, to_hex(scan_code&0xf));
     266        keybuffer_push(keybuffer, ' ');
     267        keybuffer_push(keybuffer, ' ');
     268       
     269        return 1;
     270        */
    270271       
    271272        if ( scan_code == '\r' )
     
    390391        }
    391392
    392         if(msim) return kbd_arch_process_msim(keybuffer, scan_code);
    393         if(gxemul) return kbd_arch_process_gxemul(keybuffer, scan_code);
     393        if(fb_fb) return kbd_arch_process_fb(keybuffer, scan_code);
     394        return kbd_arch_process_no_fb(keybuffer, scan_code);
    394395
    395396        return 0;
    396397}
    397 
    398 /**
    399  * @}
    400  */
     398/** @}
     399*/
Note: See TracChangeset for help on using the changeset viewer.