Changeset 93ad49a8 in mainline


Ignore:
Timestamp:
2011-08-20T15:03:05Z (13 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
422722e
Parents:
0f4532e
Message:

Make the hack more generic to work around problems with callback
sessions as well.

Location:
uspace/lib/c
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/c/generic/async.c

    r0f4532e r93ad49a8  
    16581658}
    16591659
    1660 /** Shift arguments for new connections left by one.
     1660/** Set arguments for new connections.
    16611661 *
    16621662 * FIXME This is an ugly hack to work around the problem that parallel
    16631663 * exchanges are implemented using parallel connections. When we create
    1664  * such a session via a naming server, the naming server shifts the
    1665  * arguments for the initial connection, but not for the latter connections.
     1664 * a callback session, the framework does not know arguments for the new
     1665 * connections.
    16661666 *
    16671667 * The proper solution seems to be to implement parallel exchanges using
    16681668 * tagging.
    16691669 */
    1670 void async_sess_args_shift(async_sess_t *sess)
    1671 {
    1672         sess->arg1 = sess->arg2;
    1673         sess->arg2 = sess->arg3;
    1674         sess->arg3 = 0;
     1670void async_sess_args_set(async_sess_t *sess, sysarg_t arg1, sysarg_t arg2,
     1671    sysarg_t arg3)
     1672{
     1673        sess->arg1 = arg1;
     1674        sess->arg2 = arg2;
     1675        sess->arg3 = arg3;
    16751676}
    16761677
  • uspace/lib/c/generic/ns.c

    r0f4532e r93ad49a8  
    6161         * first argument for non-initial connections.
    6262         */
    63         async_sess_args_shift(sess);
     63        async_sess_args_set(sess, arg2, arg3, 0);
    6464       
    6565        return sess;
  • uspace/lib/c/include/async.h

    r0f4532e r93ad49a8  
    333333extern void async_poke(void);
    334334
    335 void async_sess_args_shift(async_sess_t *sess);
    336 
    337335extern async_exch_t *async_exchange_begin(async_sess_t *);
    338336extern void async_exchange_end(async_exch_t *);
     337
     338/*
     339 * FIXME These functions just work around problems with parallel exchange
     340 * management. Proper solution needs to be implemented.
     341 */
     342void async_sess_args_set(async_sess_t *sess, sysarg_t, sysarg_t, sysarg_t);
    339343
    340344/*
Note: See TracChangeset for help on using the changeset viewer.