Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/net/inetsrv/inet_link.c

    rac415d50 rb7fd2a0  
    3737#include <stdbool.h>
    3838#include <errno.h>
     39#include <str_error.h>
    3940#include <fibril_synch.h>
    4041#include <inet/iplink.h>
     
    5455static uint16_t ip_ident = 0;
    5556
    56 static int inet_iplink_recv(iplink_t *, iplink_recv_sdu_t *, ip_ver_t);
    57 static int inet_iplink_change_addr(iplink_t *, addr48_t);
     57static errno_t inet_iplink_recv(iplink_t *, iplink_recv_sdu_t *, ip_ver_t);
     58static errno_t inet_iplink_change_addr(iplink_t *, addr48_t);
    5859static inet_link_t *inet_link_get_by_id_locked(sysarg_t);
    5960
     
    8283}
    8384
    84 static int inet_iplink_recv(iplink_t *iplink, iplink_recv_sdu_t *sdu, ip_ver_t ver)
     85static errno_t inet_iplink_recv(iplink_t *iplink, iplink_recv_sdu_t *sdu, ip_ver_t ver)
    8586{
    8687        log_msg(LOG_DEFAULT, LVL_DEBUG, "inet_iplink_recv()");
    8788
    88         int rc;
     89        errno_t rc;
    8990        inet_packet_t packet;
    9091        inet_link_t *ilink;
     
    114115        log_msg(LOG_DEFAULT, LVL_DEBUG, "call inet_recv_packet()");
    115116        rc = inet_recv_packet(&packet);
    116         log_msg(LOG_DEFAULT, LVL_DEBUG, "call inet_recv_packet -> %d", rc);
     117        log_msg(LOG_DEFAULT, LVL_DEBUG, "call inet_recv_packet -> %s", str_error_name(rc));
    117118        free(packet.data);
    118119
     
    120121}
    121122
    122 static int inet_iplink_change_addr(iplink_t *iplink, addr48_t mac)
     123static errno_t inet_iplink_change_addr(iplink_t *iplink, addr48_t mac)
    123124{
    124125        log_msg(LOG_DEFAULT, LVL_DEBUG, "inet_iplink_change_addr(): "
     
    157158}
    158159
    159 int inet_link_open(service_id_t sid)
     160errno_t inet_link_open(service_id_t sid)
    160161{
    161162        inet_link_t *ilink;
    162163        inet_addr_t iaddr;
    163         int rc;
     164        errno_t rc;
    164165
    165166        log_msg(LOG_DEFAULT, LVL_DEBUG, "inet_link_open()");
     
    311312 *
    312313 */
    313 int inet_link_send_dgram(inet_link_t *ilink, addr32_t lsrc, addr32_t ldest,
     314errno_t inet_link_send_dgram(inet_link_t *ilink, addr32_t lsrc, addr32_t ldest,
    314315    inet_dgram_t *dgram, uint8_t proto, uint8_t ttl, int df)
    315316{
     
    351352        packet.size = dgram->size;
    352353       
    353         int rc;
     354        errno_t rc;
    354355        size_t offs = 0;
    355356       
     
    386387 *
    387388 */
    388 int inet_link_send_dgram6(inet_link_t *ilink, addr48_t ldest,
     389errno_t inet_link_send_dgram6(inet_link_t *ilink, addr48_t ldest,
    389390    inet_dgram_t *dgram, uint8_t proto, uint8_t ttl, int df)
    390391{
     
    424425        packet.size = dgram->size;
    425426       
    426         int rc;
     427        errno_t rc;
    427428        size_t offs = 0;
    428429       
     
    470471
    471472/** Get IDs of all links. */
    472 int inet_link_get_id_list(sysarg_t **rid_list, size_t *rcount)
     473errno_t inet_link_get_id_list(sysarg_t **rid_list, size_t *rcount)
    473474{
    474475        sysarg_t *id_list;
Note: See TracChangeset for help on using the changeset viewer.