Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 16 Mar 2009 17:46:55 +0000 (UTC)
From:      Robert Watson <rwatson@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org
Subject:   svn commit: r189892 - in stable/7/sys: . contrib/pf dev/ath/ath_hal dev/cxgb
Message-ID:  <200903161746.n2GHktkE067879@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: rwatson
Date: Mon Mar 16 17:46:55 2009
New Revision: 189892
URL: http://svn.freebsd.org/changeset/base/189892

Log:
  Merge r189655 from head to stable/7:
  
    Prefer ENETDOWN to ENXIO when returning queuing errors due to a link
    down, interface down, etc, with if_cxgb's if_transmit routine.
  
    Reviewed by:  kmacy

Modified:
  stable/7/sys/   (props changed)
  stable/7/sys/contrib/pf/   (props changed)
  stable/7/sys/dev/ath/ath_hal/   (props changed)
  stable/7/sys/dev/cxgb/   (props changed)
  stable/7/sys/dev/cxgb/cxgb_multiq.c

Modified: stable/7/sys/dev/cxgb/cxgb_multiq.c
==============================================================================
--- stable/7/sys/dev/cxgb/cxgb_multiq.c	Mon Mar 16 17:30:38 2009	(r189891)
+++ stable/7/sys/dev/cxgb/cxgb_multiq.c	Mon Mar 16 17:46:55 2009	(r189892)
@@ -131,7 +131,7 @@ cxgb_pcpu_enqueue_packet_(struct sge_qse
 	KASSERT(m->m_type == MT_DATA, ("bad mbuf type %d", m->m_type));
 	if (qs->qs_flags & QS_EXITING) {
 		m_freem(m);
-		return (ENXIO);
+		return (ENETDOWN);
 	}
 	txq = &qs->txq[TXQ_ETH];
 	err = buf_ring_enqueue(&txq->txq_mr, m);
@@ -425,13 +425,13 @@ cxgb_pcpu_start_(struct sge_qset *qs, st
 	
  retry:	
 	if (!pi->link_config.link_ok)
-		initerr = ENXIO;
+		initerr = ENETDOWN;
 	else if (qs->qs_flags & QS_EXITING)
-		initerr = ENXIO;
+		initerr = ENETDOWN;
 	else if ((pi->ifp->if_drv_flags & IFF_DRV_RUNNING) == 0)
-		initerr = ENXIO;
+		initerr = ENETDOWN;
 	else if ((pi->ifp->if_flags & IFF_UP) == 0)
-		initerr = ENXIO;
+		initerr = ENETDOWN;
 	else if (immpkt) {
 
 		if (!buf_ring_empty(&txq->txq_mr)) 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200903161746.n2GHktkE067879>