Fork us on GitHub Follow us on Facebook Follow us on Twitter

Changeset 907bb49 in mainline for uspace/lib/libc/generic/kbd.c


Ignore:
Timestamp:
2009-03-18T22:22:31Z (13 years ago)
Author:
Jiri Svoboda <jirik.svoboda@…>
Branches:
lfn, master, serial
Children:
266daf5a
Parents:
eada065e
Message:

Consolidate console interface.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/libc/generic/kbd.c

    reada065e r907bb49  
    3838#include <ipc/ipc.h>
    3939#include <ipc/console.h>
     40#include <console.h>
    4041#include <async.h>
    4142
    4243int kbd_get_event(kbd_event_t *ev)
    4344{
    44         int console_phone = get_console_phone();
     45        int cons_phone = console_phone_get();
    4546        ipcarg_t r0, r1, r2, r3;
    4647        int rc;
    4748
    48         rc = async_req_0_4(console_phone, CONSOLE_GETKEY, &r0, &r1, &r2, &r3);
     49        if (cons_phone < 0)
     50                return -1;
     51
     52        rc = async_req_0_4(cons_phone, CONSOLE_GETKEY, &r0, &r1, &r2, &r3);
    4953        if (rc < 0)
    5054                return -1;
Note: See TracChangeset for help on using the changeset viewer.