Changeset 132ab5d1 in mainline for uspace/lib/c/generic/iplink_srv.c


Ignore:
Timestamp:
2018-01-30T03:20:45Z (7 years ago)
Author:
Jenda <jenda.jzqk73@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
5a6cc679
Parents:
8bfb163 (diff), 6a5d05b (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge commit '6a5d05bd2551e64111bea4f9332dd7448c26ce84' into forwardport

Separate return value from error code in gen_irq_code*().

File:
1 edited

Legend:

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

    r8bfb163 r132ab5d1  
    7878                async_answer_0(callid, rc);
    7979       
    80         async_answer_0(iid, (sysarg_t) rc);
     80        async_answer_0(iid, rc);
    8181}
    8282
     
    8989        ipc_callid_t callid;
    9090
    91         rc = async_data_write_receive(&callid, &size);
    92         if (rc != EOK) {
    93                 async_answer_0(callid, (sysarg_t) rc);
    94                 async_answer_0(iid, (sysarg_t) rc);
     91        if (!async_data_write_receive(&callid, &size)) {
     92                async_answer_0(callid, EREFUSED);
     93                async_answer_0(iid, EREFUSED);
    9594        }
    9695
     
    105104                async_answer_0(callid, rc);
    106105       
    107         async_answer_0(iid, (sysarg_t) rc);
     106        async_answer_0(iid, rc);
    108107}
    109108
     
    128127        int rc = async_data_write_finalize(callid, &addr, size);
    129128        if (rc != EOK) {
    130                 async_answer_0(callid, (sysarg_t) rc);
    131                 async_answer_0(iid, (sysarg_t) rc);
     129                async_answer_0(callid, rc);
     130                async_answer_0(iid, rc);
    132131        }
    133132       
    134133        rc = srv->ops->addr_add(srv, &addr);
    135         async_answer_0(iid, (sysarg_t) rc);
     134        async_answer_0(iid, rc);
    136135}
    137136
     
    156155        int rc = async_data_write_finalize(callid, &addr, size);
    157156        if (rc != EOK) {
    158                 async_answer_0(callid, (sysarg_t) rc);
    159                 async_answer_0(iid, (sysarg_t) rc);
     157                async_answer_0(callid, rc);
     158                async_answer_0(iid, rc);
    160159        }
    161160       
    162161        rc = srv->ops->addr_remove(srv, &addr);
    163         async_answer_0(iid, (sysarg_t) rc);
     162        async_answer_0(iid, rc);
    164163}
    165164
     
    205204        int rc = async_data_write_finalize(callid, &sdu.dest, size);
    206205        if (rc != EOK) {
    207                 async_answer_0(callid, (sysarg_t) rc);
    208                 async_answer_0(iid, (sysarg_t) rc);
     206                async_answer_0(callid, rc);
     207                async_answer_0(iid, rc);
    209208        }
    210209       
     
    322321        }
    323322       
    324         sysarg_t retval;
     323        int retval;
    325324        async_wait_for(req, &retval);
    326325        if (retval != EOK)
     
    348347        }
    349348       
    350         sysarg_t retval;
     349        int retval;
    351350        async_wait_for(req, &retval);
    352351        if (retval != EOK)
Note: See TracChangeset for help on using the changeset viewer.