Files
@ d6b9b2ac5869
Branch filter:
Location: vmkdrivers/BLD/build/HEADERS/vmkapi-current-all-public-bincomp/vmkernel64/release/vds/vmkapi_vds_ether.h
d6b9b2ac5869
3.1 KiB
text/x-chdr
ESXi-5.5-U2
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 | /* **********************************************************
* Copyright 2008 - 2009 VMware, Inc. All rights reserved.
* **********************************************************/
/*
* @VMKAPIMOD_LICENSE@
*/
/*
***********************************************************************
* Ethernet */ /**
* \addtogroup VDS
* @{
* \defgroup VDSEther VDS-specific Ethernet APIs
*
* In vmkernel, portset is a generic framework capable of handling
* arbitrary traffic. This group defines structures and interfaces
* commonly used for handling ethernet packets.
*
* @{
***********************************************************************
*/
#ifndef _VMKAPI_VDS_ETHER_H_
#define _VMKAPI_VDS_ETHER_H_
/** \cond never */
#ifndef VMK_HEADER_INCLUDED_FROM_VMKAPI_H
#error This vmkapi file should never be included directly but only via vmkapi.h
#endif
/** \endcond never */
#include "net/vmkapi_net_types.h"
#include "net/vmkapi_net_pkt.h"
#include "net/vmkapi_net_pktlist.h"
#define VMK_ETH_LADRF_LEN 2
#define VMK_ETH_MAX_EXACT_MULTICAST_ADDRS 32
/**
* \brief Type of Ethernet address filter.
*/
typedef enum vmk_EthFilterFlags {
/** Pass unicast (directed) frames */
VMK_ETH_FILTER_UNICAST = 0x0001,
/** Pass some multicast frames */
VMK_ETH_FILTER_MULTICAST = 0x0002,
/** Pass *all* multicast frames */
VMK_ETH_FILTER_ALLMULTI = 0x0004,
/** Pass broadcast frames */
VMK_ETH_FILTER_BROADCAST = 0x0008,
/** Pass all frames (i.e. no filter) */
VMK_ETH_FILTER_PROMISC = 0x0010,
/** Use LADRF for multicast filter */
VMK_ETH_FILTER_USE_LADRF = 0x0020
} vmk_EthFilterFlags;
/**
* \brief Ethernet address filter
*/
typedef struct {
/** Type of filter(s) to apply */
vmk_EthFilterFlags flags;
/** Unicast addr to filter on */
vmk_EthAddress unicastAddr;
/** Number of exact multcast addrs */
vmk_uint16 numMulticastAddrs;
/** Multicast addresses to filter on */
vmk_EthAddress multicastAddrs[VMK_ETH_MAX_EXACT_MULTICAST_ADDRS];
/** Lance style logical address filter */
vmk_uint32 ladrf[VMK_ETH_LADRF_LEN];
} vmk_EthFilter;
/**
* \brief Ethernet Frame routing policy
*/
typedef struct {
/** Like the rx filter on a real NIC */
vmk_EthFilter requestedFilter;
/** Restricted to a subset of above */
vmk_EthFilter acceptedFilter;
} vmk_EthFRP;
/*
***********************************************************************
* vmk_EthDestinationFilter -- */ /**
*
* \nativedriversdisallowed
*
* \brief Filter ethernet frames based on the destination address.
*
* \param[in] filter Ethernet address filter
* \param[in,out] pktListIn Input packet list, to be filtered
* \param[out] pktListOut List of packets filtered out
*
* \retval VMK_OK
***********************************************************************
*/
VMK_ReturnStatus vmk_EthDestinationFilter(vmk_EthFilter *filter,
vmk_PktList pktListIn,
vmk_PktList pktListOut);
#endif
/** @} */
/** @} */
|