Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/net/nil/eth/eth.h

    rfe8dfa6 r609243f4  
    11/*
    22 * Copyright (c) 2009 Lukas Mejdrech
     3 * Copyright (c) 2011 Radim Vansa
    34 * All rights reserved.
    45 *
     
    3839#define NET_ETH_H_
    3940
     41#include <async.h>
    4042#include <fibril_synch.h>
    4143#include <ipc/services.h>
    42 
    4344#include <net/device.h>
    4445#include <adt/measured_strings.h>
     46#include <devman.h>
    4547
    4648/** Ethernet address length. */
     
    220222struct eth_device {
    221223        /** Device identifier. */
    222         device_id_t device_id;
    223         /** Device driver service. */
    224         services_t service;
    225         /** Driver phone. */
    226         int phone;
     224        nic_device_id_t device_id;
     225        /** Device handle */
     226        devman_handle_t handle;
     227        /** Driver session. */
     228        async_sess_t *sess;
    227229        /** Maximal transmission unit. */
    228230        size_t mtu;
     
    236238       
    237239        /** Actual device hardware address. */
    238         measured_string_t *addr;
    239        
    240         /** Actual device hardware address data. */
    241         uint8_t *addr_data;
     240        nic_address_t addr;
    242241};
    243242
     
    248247        /** Protocol identifier. */
    249248        int protocol;
    250         /** Protocol module phone. */
    251         int phone;
     249        /** Protocol module session. */
     250        async_sess_t *sess;
    252251};
    253252
    254253/** Ethernet global data. */
    255254struct eth_globals {
    256         /** Networking module phone. */
    257         int net_phone;
     255        /** Networking module session. */
     256        async_sess_t *net_sess;
    258257        /** Safety lock for devices. */
    259258        fibril_rwlock_t devices_lock;
     
    265264        /**
    266265         * Protocol map.
    267          * Service phone map for each protocol.
     266         * Service map for each protocol.
    268267         */
    269268        eth_protos_t protos;
    270269       
    271270        /** Broadcast device hardware address. */
    272         measured_string_t *broadcast_addr;
     271        uint8_t broadcast_addr[ETH_ADDR];
    273272};
    274273
Note: See TracChangeset for help on using the changeset viewer.