Changeset f14291b in mainline for uspace/srv/net/il/arp/arp.c


Ignore:
Timestamp:
2010-10-19T20:55:53Z (14 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
a93d79a
Parents:
1882525 (diff), a7a85d16 (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 mainline changes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/net/il/arp/arp.c

    r1882525 rf14291b  
    4545#include <ipc/ipc.h>
    4646#include <ipc/services.h>
    47 
    48 #include <net_err.h>
    49 #include <net_messages.h>
    50 #include <net_modules.h>
    51 #include <net_byteorder.h>
    52 #include <net_device.h>
     47#include <ipc/net.h>
     48#include <ipc/arp.h>
     49#include <ipc/il.h>
     50#include <byteorder.h>
     51#include <err.h>
     52
     53#include <net/modules.h>
     54#include <net/device.h>
    5355#include <arp_interface.h>
    5456#include <nil_interface.h>
    5557#include <protocol_map.h>
    5658#include <adt/measured_strings.h>
    57 #include <packet/packet.h>
    58 #include <packet/packet_client.h>
     59#include <net/packet.h>
     60#include <packet_client.h>
    5961#include <packet_remote.h>
    60 #include <il_messages.h>
    6162#include <il_interface.h>
    6263#include <il_local.h>
    63 #include <arp_messages.h>
    6464
    6565#include "arp.h"
     
    227227        printf("Device %d cleared\n", device_id);
    228228        fibril_rwlock_write_unlock(&arp_globals.lock);
    229         return EOK;
    230 }
    231 
    232 int arp_connect_module(services_t service){
    233         if(service != SERVICE_ARP){
    234                 return EINVAL;
    235         }
    236229        return EOK;
    237230}
     
    543536}
    544537
    545 task_id_t arp_task_get_id(void){
    546         return task_get_id();
    547 }
    548 
    549538measured_string_ref arp_translate_message(device_id_t device_id, services_t protocol, measured_string_ref target){
    550539        arp_device_ref device;
     
    603592        nil_send_msg(device->phone, device_id, packet, SERVICE_ARP);
    604593        return NULL;
    605 }
    606 
    607 int arp_translate_req(int arp_phone, device_id_t device_id, services_t protocol, measured_string_ref address, measured_string_ref * translation, char ** data){
    608         measured_string_ref tmp;
    609 
    610         fibril_rwlock_read_lock(&arp_globals.lock);
    611         tmp = arp_translate_message(device_id, protocol, address);
    612         if(tmp){
    613                 *translation = measured_string_copy(tmp);
    614                 fibril_rwlock_read_unlock(&arp_globals.lock);
    615                 if(*translation){
    616                         *data = (** translation).value;
    617                         return EOK;
    618                 }else{
    619                         return ENOMEM;
    620                 }
    621         }else{
    622                 fibril_rwlock_read_unlock(&arp_globals.lock);
    623                 return ENOENT;
    624         }
    625594}
    626595
Note: See TracChangeset for help on using the changeset viewer.