Changeset 2133e02 in mainline for uspace/srv/ns/service.c


Ignore:
Timestamp:
2015-08-18T20:14:05Z (9 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
1a522e5
Parents:
84dc30c
Message:

canonically reserve the first argument of IPC_M_CONNECT_ME_TO for interface type
naming service: service handle in IPC_M_CONNECT_ME_TO needs to be shifted to the second argument
service connections that use the untyped (fallback) port can only provide one additional argument now

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/ns/service.c

    r84dc30c r2133e02  
    3939#include "service.h"
    4040#include "ns.h"
    41 
    4241
    4342/** Service hash table item. */
     
    8483        sysarg_t service;        /**< Number of the service. */
    8584        ipc_callid_t callid;     /**< Call ID waiting for the connection */
    86         sysarg_t arg2;           /**< Second argument */
     85        sysarg_t iface;          /**< Interface argument */
    8786        sysarg_t arg3;           /**< Third argument */
    8887} pending_conn_t;
     
    112111               
    113112                hashed_service_t *hs = hash_table_get_inst(link, hashed_service_t, link);
    114                 (void) ipc_forward_fast(pr->callid, hs->phone, pr->arg2,
    115                     pr->arg3, 0, IPC_FF_NONE);
     113                (void) ipc_forward_fast(pr->callid, hs->phone, pr->iface, pr->arg3, 0,
     114                    IPC_FF_NONE);
    116115               
    117116                list_remove(&pr->link);
     
    174173                        pr->service = service;
    175174                        pr->callid = callid;
    176                         pr->arg2 = IPC_GET_ARG2(*call);
     175                        pr->iface = IPC_GET_ARG1(*call);
    177176                        pr->arg3 = IPC_GET_ARG3(*call);
    178177                        list_append(&pr->link, &pending_conn);
    179178                        return;
    180179                }
     180               
    181181                retval = ENOENT;
    182182                goto out;
     
    184184       
    185185        hashed_service_t *hs = hash_table_get_inst(link, hashed_service_t, link);
    186         (void) ipc_forward_fast(callid, hs->phone, IPC_GET_ARG2(*call),
     186        (void) ipc_forward_fast(callid, hs->phone, IPC_GET_ARG1(*call),
    187187            IPC_GET_ARG3(*call), 0, IPC_FF_NONE);
    188188        return;
Note: See TracChangeset for help on using the changeset viewer.