Fork us on GitHub Follow us on Facebook Follow us on Twitter

Changeset 21ae7ee in mainline


Ignore:
Timestamp:
2013-12-31T03:14:49Z (8 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master
Children:
9031228
Parents:
1798e66
Message:

libdrv, nic: Use index initialized arrays.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/drv/generic/remote_nic.c

    r1798e66 r21ae7ee  
    4141#include <sys/time.h>
    4242#include <macros.h>
     43#include <device/nic.h>
    4344
    4445#include "ops/nic.h"
     
    12011202 */
    12021203static const remote_iface_func_ptr_t remote_nic_iface_ops[] = {
    1203         &remote_nic_send_frame,
    1204         &remote_nic_callback_create,
    1205         &remote_nic_get_state,
    1206         &remote_nic_set_state,
    1207         &remote_nic_get_address,
    1208         &remote_nic_set_address,
    1209         &remote_nic_get_stats,
    1210         &remote_nic_get_device_info,
    1211         &remote_nic_get_cable_state,
    1212         &remote_nic_get_operation_mode,
    1213         &remote_nic_set_operation_mode,
    1214         &remote_nic_autoneg_enable,
    1215         &remote_nic_autoneg_disable,
    1216         &remote_nic_autoneg_probe,
    1217         &remote_nic_autoneg_restart,
    1218         &remote_nic_get_pause,
    1219         &remote_nic_set_pause,
    1220         &remote_nic_unicast_get_mode,
    1221         &remote_nic_unicast_set_mode,
    1222         &remote_nic_multicast_get_mode,
    1223         &remote_nic_multicast_set_mode,
    1224         &remote_nic_broadcast_get_mode,
    1225         &remote_nic_broadcast_set_mode,
    1226         &remote_nic_defective_get_mode,
    1227         &remote_nic_defective_set_mode,
    1228         &remote_nic_blocked_sources_get,
    1229         &remote_nic_blocked_sources_set,
    1230         &remote_nic_vlan_get_mask,
    1231         &remote_nic_vlan_set_mask,
    1232         &remote_nic_vlan_set_tag,
    1233         &remote_nic_wol_virtue_add,
    1234         &remote_nic_wol_virtue_remove,
    1235         &remote_nic_wol_virtue_probe,
    1236         &remote_nic_wol_virtue_list,
    1237         &remote_nic_wol_virtue_get_caps,
    1238         &remote_nic_wol_load_info,
    1239         &remote_nic_offload_probe,
    1240         &remote_nic_offload_set,
    1241         &remote_nic_poll_get_mode,
    1242         &remote_nic_poll_set_mode,
    1243         &remote_nic_poll_now
     1204        [NIC_SEND_MESSAGE] = remote_nic_send_frame,
     1205        [NIC_CALLBACK_CREATE] = remote_nic_callback_create,
     1206        [NIC_GET_STATE] = remote_nic_get_state,
     1207        [NIC_SET_STATE] = remote_nic_set_state,
     1208        [NIC_GET_ADDRESS] = remote_nic_get_address,
     1209        [NIC_SET_ADDRESS] = remote_nic_set_address,
     1210        [NIC_GET_STATS] = remote_nic_get_stats,
     1211        [NIC_GET_DEVICE_INFO] = remote_nic_get_device_info,
     1212        [NIC_GET_CABLE_STATE] = remote_nic_get_cable_state,
     1213        [NIC_GET_OPERATION_MODE] = remote_nic_get_operation_mode,
     1214        [NIC_SET_OPERATION_MODE] = remote_nic_set_operation_mode,
     1215        [NIC_AUTONEG_ENABLE] = remote_nic_autoneg_enable,
     1216        [NIC_AUTONEG_DISABLE] = remote_nic_autoneg_disable,
     1217        [NIC_AUTONEG_PROBE] = remote_nic_autoneg_probe,
     1218        [NIC_AUTONEG_RESTART] = remote_nic_autoneg_restart,
     1219        [NIC_GET_PAUSE] = remote_nic_get_pause,
     1220        [NIC_SET_PAUSE] = remote_nic_set_pause,
     1221        [NIC_UNICAST_GET_MODE] = remote_nic_unicast_get_mode,
     1222        [NIC_UNICAST_SET_MODE] = remote_nic_unicast_set_mode,
     1223        [NIC_MULTICAST_GET_MODE] = remote_nic_multicast_get_mode,
     1224        [NIC_MULTICAST_SET_MODE] = remote_nic_multicast_set_mode,
     1225        [NIC_BROADCAST_GET_MODE] = remote_nic_broadcast_get_mode,
     1226        [NIC_BROADCAST_SET_MODE] = remote_nic_broadcast_set_mode,
     1227        [NIC_DEFECTIVE_GET_MODE] = remote_nic_defective_get_mode,
     1228        [NIC_DEFECTIVE_SET_MODE] = remote_nic_defective_set_mode,
     1229        [NIC_BLOCKED_SOURCES_GET] = remote_nic_blocked_sources_get,
     1230        [NIC_BLOCKED_SOURCES_SET] = remote_nic_blocked_sources_set,
     1231        [NIC_VLAN_GET_MASK] = remote_nic_vlan_get_mask,
     1232        [NIC_VLAN_SET_MASK] = remote_nic_vlan_set_mask,
     1233        [NIC_VLAN_SET_TAG] = remote_nic_vlan_set_tag,
     1234        [NIC_WOL_VIRTUE_ADD] = remote_nic_wol_virtue_add,
     1235        [NIC_WOL_VIRTUE_REMOVE] = remote_nic_wol_virtue_remove,
     1236        [NIC_WOL_VIRTUE_PROBE] = remote_nic_wol_virtue_probe,
     1237        [NIC_WOL_VIRTUE_LIST] = remote_nic_wol_virtue_list,
     1238        [NIC_WOL_VIRTUE_GET_CAPS] = remote_nic_wol_virtue_get_caps,
     1239        [NIC_WOL_LOAD_INFO] = remote_nic_wol_load_info,
     1240        [NIC_OFFLOAD_PROBE] = remote_nic_offload_probe,
     1241        [NIC_OFFLOAD_SET] = remote_nic_offload_set,
     1242        [NIC_POLL_GET_MODE] = remote_nic_poll_get_mode,
     1243        [NIC_POLL_SET_MODE] = remote_nic_poll_set_mode,
     1244        [NIC_POLL_NOW] = remote_nic_poll_now
    12441245};
    12451246
Note: See TracChangeset for help on using the changeset viewer.