Changeset b74959bd in mainline for uspace/srv/kbd


Ignore:
Timestamp:
2007-11-20T21:33:32Z (18 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
8498915
Parents:
3209923
Message:

Modify ipc_answer_*() to make use of all six syscall arguments. The recommended
means of answering calls is via the ipc_answer_m() macros (where m denotes the
number of return arguments) that automatically decide between the fast register
version or the slow universal version of ipc_answer().

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/kbd/generic/kbd.c

    r3209923 rb74959bd  
    6969
    7070        if (cons_connected && phone2cons != -1) {
    71                 /* recode to ASCII - one interrupt can produce more than one code so result is stored in fifo */
     71                /*
     72                 * recode to ASCII - one interrupt can produce more than one
     73                 * code so result is stored in fifo
     74                 */
    7275                while (!keybuffer_empty(&keybuffer)) {
    7376                        if (!keybuffer_pop(&keybuffer, (int *)&chr))
     
    8689
    8790        if (cons_connected) {
    88                 ipc_answer_fast(iid, ELIMIT, 0, 0);
     91                ipc_answer_0(iid, ELIMIT);
    8992                return;
    9093        }
    9194        cons_connected = 1;
    92         ipc_answer_fast(iid, 0, 0, 0);
     95        ipc_answer_0(iid, EOK);
    9396
    9497        while (1) {
     
    99102                        ipc_hangup(phone2cons);
    100103                        phone2cons = -1;
    101                         ipc_answer_fast(callid, 0,0,0);
     104                        ipc_answer_0(callid, EOK);
    102105                        return;
    103106                case IPC_M_CONNECT_TO_ME:
     
    112115                        retval = EINVAL;
    113116                }
    114                 ipc_answer_fast(callid, retval, 0, 0);
     117                ipc_answer_0(callid, retval);
    115118        }       
    116119}
Note: See TracChangeset for help on using the changeset viewer.