Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/pci/ixgbe No functional change:



details:   https://anonhg.NetBSD.org/src/rev/85e5e6e687a9
branches:  trunk
changeset: 744529:85e5e6e687a9
user:      msaitoh <msaitoh%NetBSD.org@localhost>
date:      Wed Feb 05 07:45:46 2020 +0000

description:
No functional change:

 - Add debug printf()s.
 - Remove unused macros.
 - Remove extra newline.

diffstat:

 sys/dev/pci/ixgbe/ix_txrx.c      |   4 ++--
 sys/dev/pci/ixgbe/ixgbe.c        |   4 +++-
 sys/dev/pci/ixgbe/ixgbe.h        |  25 +------------------------
 sys/dev/pci/ixgbe/ixgbe_common.c |   4 +++-
 4 files changed, 9 insertions(+), 28 deletions(-)

diffs (100 lines):

diff -r 0e995585787f -r 85e5e6e687a9 sys/dev/pci/ixgbe/ix_txrx.c
--- a/sys/dev/pci/ixgbe/ix_txrx.c       Wed Feb 05 07:37:35 2020 +0000
+++ b/sys/dev/pci/ixgbe/ix_txrx.c       Wed Feb 05 07:45:46 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ix_txrx.c,v 1.61 2020/01/30 14:02:14 thorpej Exp $ */
+/* $NetBSD: ix_txrx.c,v 1.62 2020/02/05 07:45:46 msaitoh Exp $ */
 
 /******************************************************************************
 
@@ -1556,7 +1556,6 @@
                rxbuf->addr = htole64(rxbuf->pmap->dm_segs[0].ds_addr);
        }
 
-
        /* Setup our descriptor indices */
        rxr->next_to_check = 0;
        rxr->next_to_refresh = 0;
@@ -1612,6 +1611,7 @@
        struct rx_ring *rxr = adapter->rx_rings;
        int            j;
 
+       INIT_DEBUGOUT("ixgbe_setup_receive_structures");
        for (j = 0; j < adapter->num_queues; j++, rxr++)
                if (ixgbe_setup_receive_ring(rxr))
                        goto fail;
diff -r 0e995585787f -r 85e5e6e687a9 sys/dev/pci/ixgbe/ixgbe.c
--- a/sys/dev/pci/ixgbe/ixgbe.c Wed Feb 05 07:37:35 2020 +0000
+++ b/sys/dev/pci/ixgbe/ixgbe.c Wed Feb 05 07:45:46 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ixgbe.c,v 1.224 2020/02/05 01:44:53 msaitoh Exp $ */
+/* $NetBSD: ixgbe.c,v 1.225 2020/02/05 07:45:46 msaitoh Exp $ */
 
 /******************************************************************************
 
@@ -677,6 +677,8 @@
        struct ixgbe_hw *hw = &adapter->hw;
        int i;
 
+       INIT_DEBUGOUT("ixgbe_initialize_transmit_units");
+
        /* Setup the Base and Length of the Tx Descriptor Ring */
        for (i = 0; i < adapter->num_queues; i++, txr++) {
                u64 tdba = txr->txdma.dma_paddr;
diff -r 0e995585787f -r 85e5e6e687a9 sys/dev/pci/ixgbe/ixgbe.h
--- a/sys/dev/pci/ixgbe/ixgbe.h Wed Feb 05 07:37:35 2020 +0000
+++ b/sys/dev/pci/ixgbe/ixgbe.h Wed Feb 05 07:45:46 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ixgbe.h,v 1.63 2020/02/04 19:42:55 thorpej Exp $ */
+/* $NetBSD: ixgbe.h,v 1.64 2020/02/05 07:45:46 msaitoh Exp $ */
 
 /******************************************************************************
   SPDX-License-Identifier: BSD-3-Clause
@@ -646,29 +646,6 @@
 #define IXGBE_CORE_LOCK_ASSERT(_sc)       KASSERT(mutex_owned(&(_sc)->core_mtx))
 #define IXGBE_TX_LOCK_ASSERT(_sc)         KASSERT(mutex_owned(&(_sc)->tx_mtx))
 
-/* Stats macros */
-#if __FreeBSD_version >= 1100036
-#define IXGBE_SET_IERRORS(sc, count)     (sc)->ierrors = (count)
-#define IXGBE_SET_OPACKETS(sc, count)    (sc)->opackets = (count)
-#define IXGBE_SET_OERRORS(sc, count)     (sc)->oerrors = (count)
-#define IXGBE_SET_COLLISIONS(sc, count)
-#define IXGBE_SET_IBYTES(sc, count)      (sc)->ibytes = (count)
-#define IXGBE_SET_OBYTES(sc, count)      (sc)->obytes = (count)
-#define IXGBE_SET_IMCASTS(sc, count)     (sc)->imcasts = (count)
-#define IXGBE_SET_OMCASTS(sc, count)     (sc)->omcasts = (count)
-#define IXGBE_SET_IQDROPS(sc, count)     (sc)->iqdrops = (count)
-#else
-#define IXGBE_SET_IERRORS(sc, count)     (sc)->ifp->if_ierrors = (count)
-#define IXGBE_SET_OPACKETS(sc, count)    (sc)->ifp->if_opackets = (count)
-#define IXGBE_SET_OERRORS(sc, count)     (sc)->ifp->if_oerrors = (count)
-#define IXGBE_SET_COLLISIONS(sc, count)  (sc)->ifp->if_collisions = (count)
-#define IXGBE_SET_IBYTES(sc, count)      (sc)->ifp->if_ibytes = (count)
-#define IXGBE_SET_OBYTES(sc, count)      (sc)->ifp->if_obytes = (count)
-#define IXGBE_SET_IMCASTS(sc, count)     (sc)->ifp->if_imcasts = (count)
-#define IXGBE_SET_OMCASTS(sc, count)     (sc)->ifp->if_omcasts = (count)
-#define IXGBE_SET_IQDROPS(sc, count)     (sc)->ifp->if_iqdrops = (count)
-#endif
-
 /* External PHY register addresses */
 #define IXGBE_PHY_CURRENT_TEMP         0xC820
 #define IXGBE_PHY_OVERTEMP_STATUS      0xC830
diff -r 0e995585787f -r 85e5e6e687a9 sys/dev/pci/ixgbe/ixgbe_common.c
--- a/sys/dev/pci/ixgbe/ixgbe_common.c  Wed Feb 05 07:37:35 2020 +0000
+++ b/sys/dev/pci/ixgbe/ixgbe_common.c  Wed Feb 05 07:45:46 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ixgbe_common.c,v 1.26 2019/12/16 02:50:54 msaitoh Exp $ */
+/* $NetBSD: ixgbe_common.c,v 1.27 2020/02/05 07:45:46 msaitoh Exp $ */
 
 /******************************************************************************
   SPDX-License-Identifier: BSD-3-Clause
@@ -464,6 +464,8 @@
        u32 i;
        u32 regval;
 
+       DEBUGFUNC("ixgbe_start_hw_gen2");
+
        /* Clear the rate limiters */
        for (i = 0; i < hw->mac.max_tx_queues; i++) {
                IXGBE_WRITE_REG(hw, IXGBE_RTTDQSEL, i);



Home | Main Index | Thread Index | Old Index