Changeset View
Changeset View
Standalone View
Standalone View
head/sys/dev/virtio/network/if_vtnetvar.h
Show First 20 Lines • Show All 308 Lines • ▼ Show 20 Lines | |||||
/* | /* | ||||
* Used to preallocate the Vq indirect descriptors. The first segment | * Used to preallocate the Vq indirect descriptors. The first segment | ||||
* is reserved for the header, except for mergeable buffers since the | * is reserved for the header, except for mergeable buffers since the | ||||
* header is placed inline with the data. | * header is placed inline with the data. | ||||
*/ | */ | ||||
#define VTNET_MRG_RX_SEGS 1 | #define VTNET_MRG_RX_SEGS 1 | ||||
#define VTNET_MIN_RX_SEGS 2 | #define VTNET_MIN_RX_SEGS 2 | ||||
#define VTNET_MAX_RX_SEGS 34 | #define VTNET_MAX_RX_SEGS 34 | ||||
#define VTNET_MIN_TX_SEGS 4 | #define VTNET_MIN_TX_SEGS 32 | ||||
#define VTNET_MAX_TX_SEGS 64 | #define VTNET_MAX_TX_SEGS 64 | ||||
/* | /* | ||||
* Assert we can receive and transmit the maximum with regular | * Assert we can receive and transmit the maximum with regular | ||||
* size clusters. | * size clusters. | ||||
*/ | */ | ||||
CTASSERT(((VTNET_MAX_RX_SEGS - 1) * MCLBYTES) >= VTNET_MAX_RX_SIZE); | CTASSERT(((VTNET_MAX_RX_SEGS - 1) * MCLBYTES) >= VTNET_MAX_RX_SIZE); | ||||
CTASSERT(((VTNET_MAX_TX_SEGS - 1) * MCLBYTES) >= VTNET_MAX_MTU); | CTASSERT(((VTNET_MAX_TX_SEGS - 1) * MCLBYTES) >= VTNET_MAX_MTU); | ||||
Show All 34 Lines |