/********************************************************************** * Author: Cavium, Inc. * * Contact: support@cavium.com * Please include "LiquidIO" in the subject. * * Copyright (c) 2003-2016 Cavium, Inc. * * This file is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License, Version 2, as * published by the Free Software Foundation. * * This file is distributed in the hope that it will be useful, but * AS-IS and WITHOUT ANY WARRANTY; without even the implied warranty * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE, TITLE, or * NONINFRINGEMENT. See the GNU General Public License for more details.
***********************************************************************/ /*! \file octeon_config.h * \brief Host Driver: Configuration data structures for the host driver.
*/
/** Structure to define the configuration attributes for each Input queue. * Applicable to all Octeon processors
**/ struct octeon_iq_config { #ifdef __BIG_ENDIAN_BITFIELD
u64 reserved:16;
/** Tx interrupt packets. Applicable to 23xx only */
u64 iq_intr_pkt:16;
/** Minimum ticks to wait before checking for pending instructions. */
u64 db_timeout:16;
/** Minimum number of commands pending to be posted to Octeon * before driver hits the Input queue doorbell.
*/
u64 db_min:8;
/** Minimum number of commands pending to be posted to Octeon * before driver hits the Input queue doorbell.
*/
u64 db_min:8;
/** Minimum ticks to wait before checking for pending instructions. */
u64 db_timeout:16;
/** Tx interrupt packets. Applicable to 23xx only */
u64 iq_intr_pkt:16;
u64 reserved:16; #endif
};
/** Structure to define the configuration attributes for each Output queue. * Applicable to all Octeon processors
**/ struct octeon_oq_config { #ifdef __BIG_ENDIAN_BITFIELD
u64 reserved:16;
u64 pkts_per_intr:16;
/** Interrupt Coalescing (Time Interval). Octeon will interrupt the * host if atleast one packet was sent in the time interval specified * by this field. The driver uses time interval interrupt coalescing * by default. The time is specified in microseconds.
*/
u64 oq_intr_time:16;
/** Interrupt Coalescing (Packet Count). Octeon will interrupt the host * only if it sent as many packets as specified by this field. * The driver * usually does not use packet count interrupt coalescing.
*/
u64 oq_intr_pkt:16;
/** The number of buffers that were consumed during packet processing by * the driver on this Output queue before the driver attempts to * replenish * the descriptor ring with new buffers.
*/
u64 refill_threshold:16;
/* Max number of OQs available */
u64 max_oqs:8;
#else /* Max number of OQs available */
u64 max_oqs:8;
/** The number of buffers that were consumed during packet processing by * the driver on this Output queue before the driver attempts to * replenish * the descriptor ring with new buffers.
*/
u64 refill_threshold:16;
/** Interrupt Coalescing (Packet Count). Octeon will interrupt the host * only if it sent as many packets as specified by this field. * The driver * usually does not use packet count interrupt coalescing.
*/
u64 oq_intr_pkt:16;
/** Interrupt Coalescing (Time Interval). Octeon will interrupt the * host if atleast one packet was sent in the time interval specified * by this field. The driver uses time interval interrupt coalescing * by default. The time is specified in microseconds.
*/
u64 oq_intr_time:16;
u64 pkts_per_intr:16;
u64 reserved:16; #endif
};
/** This structure conatins the NIC link configuration attributes, * common for all the OCTEON Modles.
*/ struct octeon_nic_if_config { #ifdef __BIG_ENDIAN_BITFIELD
u64 reserved:56;
u64 base_queue:16;
u64 gmx_port_id:8;
/* SKB size, We need not change buf size even for Jumbo frames. * Octeon can send jumbo frames in 4 consecutive descriptors,
*/
u64 rx_buf_size:16;
/* Num of desc for tx rings */
u64 num_tx_descs:16;
/* Num of desc for rx rings */
u64 num_rx_descs:16;
/* Actual configured value. Range could be: 1...max_rxqs */
u64 num_rxqs:16;
/* Max Rxqs: Half for each of the two ports :max_oq/2 */
u64 max_rxqs:16;
/* Actual configured value. Range could be: 1...max_txqs */
u64 num_txqs:16;
/* Max Txqs: Half for each of the two ports :max_iq/2 */
u64 max_txqs:16; #else /* Max Txqs: Half for each of the two ports :max_iq/2 */
u64 max_txqs:16;
/* Actual configured value. Range could be: 1...max_txqs */
u64 num_txqs:16;
/* Max Rxqs: Half for each of the two ports :max_oq/2 */
u64 max_rxqs:16;
/* Actual configured value. Range could be: 1...max_rxqs */
u64 num_rxqs:16;
/* Num of desc for rx rings */
u64 num_rx_descs:16;
/* Num of desc for tx rings */
u64 num_tx_descs:16;
/* SKB size, We need not change buf size even for Jumbo frames. * Octeon can send jumbo frames in 4 consecutive descriptors,
*/
u64 rx_buf_size:16;
u64 gmx_port_id:8;
u64 base_queue:16;
u64 reserved:56; #endif
};
/** Structure to define the configuration attributes for meta data. * Applicable to all Octeon processors.
*/
struct octeon_misc_config { #ifdef __BIG_ENDIAN_BITFIELD /** Host link status polling period */
u64 host_link_query_interval:32; /** Oct link status polling period */
u64 oct_link_query_interval:32;
u64 enable_sli_oq_bp:1; /** Control IQ Group */
u64 ctrlq_grp:4; #else /** Control IQ Group */
u64 ctrlq_grp:4; /** BP for SLI OQ */
u64 enable_sli_oq_bp:1; /** Host link status polling period */
u64 oct_link_query_interval:32; /** Oct link status polling period */
u64 host_link_query_interval:32; #endif
};
/** Structure to define the configuration for all OCTEON processors. */ struct octeon_config {
u16 card_type; char *card_name;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.