Deleted Added
full compact
efx_tx.c (278839) efx_tx.c (279141)
1/*-
2 * Copyright 2007-2009 Solarflare Communications Inc. All rights reserved.
3 *
4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions
6 * are met:
7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer.

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

19 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
23 * SUCH DAMAGE.
24 */
25
26#include <sys/cdefs.h>
1/*-
2 * Copyright 2007-2009 Solarflare Communications Inc. All rights reserved.
3 *
4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions
6 * are met:
7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer.

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

19 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
23 * SUCH DAMAGE.
24 */
25
26#include <sys/cdefs.h>
27__FBSDID("$FreeBSD: head/sys/dev/sfxge/common/efx_tx.c 278839 2015-02-16 06:12:04Z arybchik $");
27__FBSDID("$FreeBSD: head/sys/dev/sfxge/common/efx_tx.c 279141 2015-02-22 07:08:57Z arybchik $");
28
29#include "efsys.h"
30#include "efx.h"
31#include "efx_types.h"
32#include "efx_regs.h"
33#include "efx_impl.h"
34
35#if EFSYS_OPT_QSTATS

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

284 efx_txq_t *etp;
285 efx_oword_t oword;
286 uint32_t size;
287 int rc;
288
289 EFSYS_ASSERT3U(enp->en_magic, ==, EFX_NIC_MAGIC);
290 EFSYS_ASSERT3U(enp->en_mod_flags, &, EFX_MOD_TX);
291
28
29#include "efsys.h"
30#include "efx.h"
31#include "efx_types.h"
32#include "efx_regs.h"
33#include "efx_impl.h"
34
35#if EFSYS_OPT_QSTATS

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

284 efx_txq_t *etp;
285 efx_oword_t oword;
286 uint32_t size;
287 int rc;
288
289 EFSYS_ASSERT3U(enp->en_magic, ==, EFX_NIC_MAGIC);
290 EFSYS_ASSERT3U(enp->en_mod_flags, &, EFX_MOD_TX);
291
292 EFX_STATIC_ASSERT(EFX_EV_TX_NLABELS == (1 << FRF_AZ_TX_DESCQ_LABEL_WIDTH));
293 /* EFSYS_ASSERT3U(label, <, EFX_EV_TX_NLABELS);*/
292 EFX_STATIC_ASSERT(EFX_EV_TX_NLABELS ==
293 (1 << FRF_AZ_TX_DESCQ_LABEL_WIDTH));
294 EFSYS_ASSERT3U(label, <, EFX_EV_TX_NLABELS);
294 EFSYS_ASSERT3U(enp->en_tx_qcount + 1, <, encp->enc_txq_limit);
295
296 if (!ISP2(n) || !(n & EFX_TXQ_NDESCS_MASK)) {
297 rc = EINVAL;
298 goto fail1;
299 }
300 if (index >= encp->enc_txq_limit) {
301 rc = EINVAL;

--- 134 unchanged lines hidden ---
295 EFSYS_ASSERT3U(enp->en_tx_qcount + 1, <, encp->enc_txq_limit);
296
297 if (!ISP2(n) || !(n & EFX_TXQ_NDESCS_MASK)) {
298 rc = EINVAL;
299 goto fail1;
300 }
301 if (index >= encp->enc_txq_limit) {
302 rc = EINVAL;

--- 134 unchanged lines hidden ---