Changeset 8a9a41e in mainline for uspace/lib/inet/src/iplink.c


Ignore:
Timestamp:
2021-10-24T08:28:43Z (2 years ago)
Author:
GitHub <noreply@…>
Children:
f628215
Parents:
2ce943a (diff), cd981f2a (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.
git-author:
Erik Kučák <35500848+Riko196@…> (2021-10-24 08:28:43)
git-committer:
GitHub <noreply@…> (2021-10-24 08:28:43)
Message:

Merge branch 'HelenOS:master' into master

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/inet/src/iplink.c

    r2ce943a r8a9a41e  
    11/*
    2  * Copyright (c) 2012 Jiri Svoboda
     2 * Copyright (c) 2021 Jiri Svoboda
    33 * All rights reserved.
    44 *
     
    2727 */
    2828
    29 /** @addtogroup libc
     29/** @addtogroup libinet
    3030 * @{
    3131 */
     
    3838#include <assert.h>
    3939#include <errno.h>
     40#include <inet/addr.h>
     41#include <inet/eth_addr.h>
    4042#include <inet/iplink.h>
    41 #include <inet/addr.h>
    4243#include <ipc/iplink.h>
    4344#include <ipc/services.h>
     
    115116        aid_t req = async_send_0(exch, IPLINK_SEND6, &answer);
    116117
    117         errno_t rc = async_data_write_start(exch, &sdu->dest, sizeof(addr48_t));
     118        errno_t rc = async_data_write_start(exch, &sdu->dest, sizeof(eth_addr_t));
    118119        if (rc != EOK) {
    119120                async_exchange_end(exch);
     
    153154}
    154155
    155 errno_t iplink_get_mac48(iplink_t *iplink, addr48_t *mac)
     156errno_t iplink_get_mac48(iplink_t *iplink, eth_addr_t *mac)
    156157{
    157158        async_exch_t *exch = async_exchange_begin(iplink->sess);
     
    160161        aid_t req = async_send_0(exch, IPLINK_GET_MAC48, &answer);
    161162
    162         errno_t rc = async_data_read_start(exch, mac, sizeof(addr48_t));
     163        errno_t rc = async_data_read_start(exch, mac, sizeof(eth_addr_t));
    163164
    164165        loc_exchange_end(exch);
     
    175176}
    176177
    177 errno_t iplink_set_mac48(iplink_t *iplink, addr48_t mac)
     178errno_t iplink_set_mac48(iplink_t *iplink, eth_addr_t *mac)
    178179{
    179180        async_exch_t *exch = async_exchange_begin(iplink->sess);
     
    182183        aid_t req = async_send_0(exch, IPLINK_GET_MAC48, &answer);
    183184
    184         errno_t rc = async_data_read_start(exch, mac, sizeof(addr48_t));
     185        errno_t rc = async_data_read_start(exch, mac, sizeof(eth_addr_t));
    185186
    186187        loc_exchange_end(exch);
     
    264265static void iplink_ev_change_addr(iplink_t *iplink, ipc_call_t *icall)
    265266{
    266         addr48_t *addr;
     267        eth_addr_t *addr;
    267268        size_t size;
    268269
    269270        errno_t rc = async_data_write_accept((void **) &addr, false,
    270             sizeof(addr48_t), sizeof(addr48_t), 0, &size);
     271            sizeof(eth_addr_t), sizeof(eth_addr_t), 0, &size);
    271272        if (rc != EOK) {
    272273                async_answer_0(icall, rc);
     
    274275        }
    275276
    276         rc = iplink->ev_ops->change_addr(iplink, *addr);
     277        rc = iplink->ev_ops->change_addr(iplink, addr);
    277278        free(addr);
    278279        async_answer_0(icall, EOK);
Note: See TracChangeset for help on using the changeset viewer.