Remove use of the link change interrupt handling, not all controllers
authorbrad <brad@openbsd.org>
Tue, 20 Jan 2015 04:33:06 +0000 (04:33 +0000)
committerbrad <brad@openbsd.org>
Tue, 20 Jan 2015 04:33:06 +0000 (04:33 +0000)
support this interrupt. Link state changes are noticed via the PHY
status change callback or via the timeout for re_tick().

From FreeBSD

sys/dev/ic/re.c
sys/dev/ic/rtl81x9reg.h

index f7adfa4..b296281 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: re.c,v 1.169 2015/01/20 04:23:33 brad Exp $   */
+/*     $OpenBSD: re.c,v 1.170 2015/01/20 04:33:06 brad Exp $   */
 /*     $FreeBSD: if_re.c,v 1.31 2004/09/04 07:54:05 ru Exp $   */
 /*
  * Copyright (c) 1997, 1998-2003
@@ -1562,12 +1562,6 @@ re_intr(void *arg)
                        re_init(ifp);
                        claimed = 1;
                }
-
-               if (status & RL_ISR_LINKCHG) {
-                       timeout_del(&sc->timer_handle);
-                       re_tick(sc);
-                       claimed = 1;
-               }
        }
 
        if (sc->rl_imtype == RL_IMTYPE_SIM) {
index dba1ad6..c9cc6cb 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: rtl81x9reg.h,v 1.89 2015/01/08 00:49:18 brad Exp $    */
+/*     $OpenBSD: rtl81x9reg.h,v 1.90 2015/01/20 04:33:06 brad Exp $    */
 
 /*
  * Copyright (c) 1997, 1998
 
 #define RL_INTRS_CPLUS \
        (RL_ISR_RX_OK|RL_ISR_RX_ERR|RL_ISR_TX_ERR|                      \
-       RL_ISR_RX_OVERRUN|RL_ISR_FIFO_OFLOW|RL_ISR_LINKCHG|             \
+       RL_ISR_RX_OVERRUN|RL_ISR_FIFO_OFLOW|                            \
        RL_ISR_SYSTEM_ERR|RL_ISR_TX_OK)
 
-#define RL_INTRS_TIMER                                                 \
-       (RL_ISR_RX_ERR|RL_ISR_TX_ERR|                                   \
-       RL_ISR_LINKCHG|RL_ISR_SYSTEM_ERR|                               \
+#define RL_INTRS_TIMER \
+       (RL_ISR_RX_ERR|RL_ISR_TX_ERR|RL_ISR_SYSTEM_ERR|                 \
        RL_ISR_TIMEOUT_EXPIRED)
 
 /*