Changeset 9cd8165 in mainline for uspace/lib/c


Ignore:
Timestamp:
2012-01-27T12:54:09Z (13 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
790d6d1
Parents:
7174403
Message:

NIC does not need nic_device_id_t. Now it exists just inside net. Not sure if
we care to rename it since net is going away soon, anyway.

Location:
uspace/lib/c
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/c/generic/device/nic.c

    r7174403 r9cd8165  
    8181 *
    8282 */
    83 int nic_callback_create(async_sess_t *dev_sess, nic_device_id_t device_id,
    84     async_client_conn_t cfun, void *carg)
     83int nic_callback_create(async_sess_t *dev_sess, async_client_conn_t cfun,
     84    void *carg)
    8585{
    8686        ipc_call_t answer;
     
    8989       
    9090        async_exch_t *exch = async_exchange_begin(dev_sess);
    91         aid_t req = async_send_2(exch, DEV_IFACE_ID(NIC_DEV_IFACE),
    92             NIC_CALLBACK_CREATE, device_id, &answer);
     91        aid_t req = async_send_1(exch, DEV_IFACE_ID(NIC_DEV_IFACE),
     92            NIC_CALLBACK_CREATE, &answer);
    9393       
    9494        rc = async_connect_to_me(exch, 0, 0, 0, cfun, carg);
  • uspace/lib/c/include/device/nic.h

    r7174403 r9cd8165  
    9191
    9292extern int nic_send_frame(async_sess_t *, void *, size_t);
    93 extern int nic_callback_create(async_sess_t *, nic_device_id_t,
    94     async_client_conn_t, void *);
     93extern int nic_callback_create(async_sess_t *, async_client_conn_t, void *);
    9594extern int nic_get_state(async_sess_t *, nic_device_state_t *);
    9695extern int nic_set_state(async_sess_t *, nic_device_state_t);
  • uspace/lib/c/include/net/device.h

    r7174403 r9cd8165  
    4747#define DEVICE_MAP_IMPLEMENT  INT_MAP_IMPLEMENT
    4848
     49/** Device identifier type. */
     50typedef int nic_device_id_t;
     51
     52/** Invalid device identifier. */
     53#define NIC_DEVICE_INVALID_ID  (-1)
     54
    4955#endif
    5056
  • uspace/lib/c/include/nic/nic.h

    r7174403 r9cd8165  
    6363#define NIC_MAX_ADDRESS_LENGTH  16
    6464
    65 /** Invalid device identifier. */
    66 #define NIC_DEVICE_INVALID_ID  (-1)
    67 
    6865#define NIC_VENDOR_MAX_LENGTH         64
    6966#define NIC_MODEL_MAX_LENGTH          64
     
    8683
    8784#define NIC_DEVICE_PRINT_FMT  "%x"
    88 
    89 /** Device identifier type. */
    90 typedef int nic_device_id_t;
    9185
    9286/**
Note: See TracChangeset for help on using the changeset viewer.