igc.h (0507ef8a0372b80c30555bbeec7215f2cf874ecd) igc.h (ab4056126813c889ee6c8fb24ca8f75b84c981ab)
1/* SPDX-License-Identifier: GPL-2.0 */
2/* Copyright (c) 2018 Intel Corporation */
3
4#ifndef _IGC_H_
5#define _IGC_H_
6
7#include <linux/kobject.h>
8

--- 117 unchanged lines hidden (view full) ---

126 IGC_TX_FLAGS_TSO = 0x02,
127 IGC_TX_FLAGS_TSTAMP = 0x04,
128
129 /* olinfo flags */
130 IGC_TX_FLAGS_IPV4 = 0x10,
131 IGC_TX_FLAGS_CSUM = 0x20,
132};
133
1/* SPDX-License-Identifier: GPL-2.0 */
2/* Copyright (c) 2018 Intel Corporation */
3
4#ifndef _IGC_H_
5#define _IGC_H_
6
7#include <linux/kobject.h>
8

--- 117 unchanged lines hidden (view full) ---

126 IGC_TX_FLAGS_TSO = 0x02,
127 IGC_TX_FLAGS_TSTAMP = 0x04,
128
129 /* olinfo flags */
130 IGC_TX_FLAGS_IPV4 = 0x10,
131 IGC_TX_FLAGS_CSUM = 0x20,
132};
133
134enum igc_boards {
135 board_base,
136};
137
134/* The largest size we can write to the descriptor is 65535. In order to
135 * maintain a power of two alignment we have to limit ourselves to 32K.
136 */
137#define IGC_MAX_TXD_PWR 15
138#define IGC_MAX_DATA_PER_TXD BIT(IGC_MAX_TXD_PWR)
139
140/* Tx Descriptors needed, worst case */
141#define TXD_USE_COUNT(S) DIV_ROUND_UP((S), IGC_MAX_DATA_PER_TXD)

--- 195 unchanged lines hidden (view full) ---

337 u32 *shadow_vfta;
338
339 u32 rss_queues;
340
341 /* lock for RX network flow classification filter */
342 spinlock_t nfc_lock;
343
344 struct igc_mac_addr *mac_table;
138/* The largest size we can write to the descriptor is 65535. In order to
139 * maintain a power of two alignment we have to limit ourselves to 32K.
140 */
141#define IGC_MAX_TXD_PWR 15
142#define IGC_MAX_DATA_PER_TXD BIT(IGC_MAX_TXD_PWR)
143
144/* Tx Descriptors needed, worst case */
145#define TXD_USE_COUNT(S) DIV_ROUND_UP((S), IGC_MAX_DATA_PER_TXD)

--- 195 unchanged lines hidden (view full) ---

341 u32 *shadow_vfta;
342
343 u32 rss_queues;
344
345 /* lock for RX network flow classification filter */
346 spinlock_t nfc_lock;
347
348 struct igc_mac_addr *mac_table;
349
350 struct igc_info ei;
345};
346
347/* igc_desc_unused - calculate if we have unused descriptors */
348static inline u16 igc_desc_unused(const struct igc_ring *ring)
349{
350 u16 ntc = ring->next_to_clean;
351 u16 ntu = ring->next_to_use;
352

--- 56 unchanged lines hidden ---
351};
352
353/* igc_desc_unused - calculate if we have unused descriptors */
354static inline u16 igc_desc_unused(const struct igc_ring *ring)
355{
356 u16 ntc = ring->next_to_clean;
357 u16 ntu = ring->next_to_use;
358

--- 56 unchanged lines hidden ---