Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 11 Feb 2009 15:04:37 GMT
From:      John Baldwin <jhb@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 157542 for review
Message-ID:  <200902111504.n1BF4bT4042553@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=157542

Change 157542 by jhb@jhb_jhbbsd on 2009/02/11 15:04:28

	IFC @157539

Affected files ...

.. //depot/projects/smpng/sys/boot/sparc64/loader/main.c#27 integrate
.. //depot/projects/smpng/sys/cam/scsi/scsi_cd.c#36 integrate
.. //depot/projects/smpng/sys/cam/scsi/scsi_da.c#84 integrate
.. //depot/projects/smpng/sys/dev/arcmsr/arcmsr.c#19 integrate
.. //depot/projects/smpng/sys/dev/ath/ath_hal/ar5212/ar5212_ani.c#4 integrate
.. //depot/projects/smpng/sys/dev/ath/if_ath.c#66 integrate
.. //depot/projects/smpng/sys/dev/bge/if_bge.c#104 integrate
.. //depot/projects/smpng/sys/dev/iicbus/if_ic.c#19 integrate
.. //depot/projects/smpng/sys/dev/iicbus/iicbb.c#10 integrate
.. //depot/projects/smpng/sys/dev/iicbus/iicbus.c#14 integrate
.. //depot/projects/smpng/sys/dev/iicbus/iicsmb.c#10 integrate
.. //depot/projects/smpng/sys/dev/ppbus/lpt.c#25 integrate
.. //depot/projects/smpng/sys/dev/ppc/ppc_pci.c#4 integrate
.. //depot/projects/smpng/sys/dev/re/if_re.c#71 integrate
.. //depot/projects/smpng/sys/dev/sdhci/sdhci.c#6 integrate
.. //depot/projects/smpng/sys/dev/sis/if_sis.c#3 integrate
.. //depot/projects/smpng/sys/dev/sound/pci/envy24.c#13 integrate
.. //depot/projects/smpng/sys/dev/sound/pci/envy24ht.c#10 integrate
.. //depot/projects/smpng/sys/dev/sound/pci/spicds.c#4 integrate
.. //depot/projects/smpng/sys/dev/tl/if_tl.c#2 integrate
.. //depot/projects/smpng/sys/dev/tx/if_tx.c#31 integrate
.. //depot/projects/smpng/sys/dev/uart/uart_bus_pci.c#10 integrate
.. //depot/projects/smpng/sys/ia64/ia64/mp_machdep.c#40 integrate
.. //depot/projects/smpng/sys/kern/kern_linker.c#98 integrate
.. //depot/projects/smpng/sys/kern/link_elf.c#48 integrate
.. //depot/projects/smpng/sys/kern/link_elf_obj.c#22 integrate
.. //depot/projects/smpng/sys/kern/subr_bus.c#73 integrate
.. //depot/projects/smpng/sys/net80211/ieee80211_adhoc.c#5 integrate
.. //depot/projects/smpng/sys/net80211/ieee80211_tdma.c#3 integrate
.. //depot/projects/smpng/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c#19 integrate
.. //depot/projects/smpng/sys/pci/if_rlreg.h#50 integrate
.. //depot/projects/smpng/sys/sparc64/include/bus_private.h#8 integrate
.. //depot/projects/smpng/sys/sparc64/include/vmparam.h#18 integrate
.. //depot/projects/smpng/sys/sparc64/sparc64/iommu.c#35 integrate
.. //depot/projects/smpng/sys/sun4v/include/vmparam.h#6 integrate
.. //depot/projects/smpng/sys/sys/kobj.h#8 integrate

Differences ...

==== //depot/projects/smpng/sys/boot/sparc64/loader/main.c#27 (text+ko) ====

@@ -33,7 +33,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/boot/sparc64/loader/main.c,v 1.39 2008/10/05 14:00:44 marius Exp $");
+__FBSDID("$FreeBSD: src/sys/boot/sparc64/loader/main.c,v 1.40 2009/02/10 21:48:42 marius Exp $");
 
 /*
  * FreeBSD/sparc64 kernel loader - machine dependent part
@@ -383,7 +383,7 @@
 		return (error);
 
 	printf("jumping to kernel entry at %#lx.\n", e->e_entry);
-#if LOADER_DEBUG
+#ifdef LOADER_DEBUG
 	pmap_print_tlb_sun4u();
 #endif
 
@@ -499,7 +499,7 @@
 			stxa(AA_IMMU_TAR, ASI_IMMU,
 			     TLB_TAR_VA(vpn) | TLB_TAR_CTX(TLB_CTX_KERNEL));
 			stxa(TLB_DAR_SLOT(i), ASI_ITLB_DATA_ACCESS_REG, data);
-			flush(KERNBASE);
+			flush(PROMBASE);
 			break;
 		}
 		wrpr(pstate, reg, 0);
@@ -511,7 +511,7 @@
 	stxa(AA_IMMU_TAR, ASI_IMMU,
 	     TLB_TAR_VA(vpn) | TLB_TAR_CTX(TLB_CTX_KERNEL));
 	stxa(0, ASI_ITLB_DATA_IN_REG, data);
-	flush(KERNBASE);
+	flush(PROMBASE);
 	wrpr(pstate, reg, 0);
 }
 
@@ -837,7 +837,7 @@
 }
 
 #ifdef LOADER_DEBUG
-static const char *page_sizes[] = {
+static const char *const page_sizes[] = {
 	"  8k", " 64k", "512k", "  4m"
 };
 

==== //depot/projects/smpng/sys/cam/scsi/scsi_cd.c#36 (text+ko) ====

@@ -46,7 +46,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/cam/scsi/scsi_cd.c,v 1.104 2009/01/08 00:45:47 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/cam/scsi/scsi_cd.c,v 1.105 2009/02/10 22:39:44 jhb Exp $");
 
 #include "opt_cd.h"
 
@@ -555,8 +555,6 @@
 	snprintf(tmpstr, sizeof(tmpstr), "CAM CD unit %d", periph->unit_number);
 	snprintf(tmpstr2, sizeof(tmpstr2), "%d", periph->unit_number);
 
-	mtx_lock(&Giant);
-
 	sysctl_ctx_init(&softc->sysctl_ctx);
 	softc->flags |= CD_FLAG_SCTX_INIT;
 	softc->sysctl_tree = SYSCTL_ADD_NODE(&softc->sysctl_ctx,
@@ -565,7 +563,6 @@
 
 	if (softc->sysctl_tree == NULL) {
 		printf("cdsysctlinit: unable to allocate sysctl tree\n");
-		mtx_unlock(&Giant);
 		cam_periph_release(periph);
 		return;
 	}
@@ -579,7 +576,6 @@
 		&softc->minimum_command_size, 0, cdcmdsizesysctl, "I",
 		"Minimum CDB size");
 
-	mtx_unlock(&Giant);
 	cam_periph_release(periph);
 }
 

==== //depot/projects/smpng/sys/cam/scsi/scsi_da.c#84 (text+ko) ====

@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/cam/scsi/scsi_da.c,v 1.233 2009/01/14 21:27:30 trasz Exp $");
+__FBSDID("$FreeBSD: src/sys/cam/scsi/scsi_da.c,v 1.234 2009/02/10 22:39:44 jhb Exp $");
 
 #include <sys/param.h>
 
@@ -1086,7 +1086,6 @@
 	snprintf(tmpstr, sizeof(tmpstr), "CAM DA unit %d", periph->unit_number);
 	snprintf(tmpstr2, sizeof(tmpstr2), "%d", periph->unit_number);
 
-	mtx_lock(&Giant);
 	sysctl_ctx_init(&softc->sysctl_ctx);
 	softc->flags |= DA_FLAG_SCTX_INIT;
 	softc->sysctl_tree = SYSCTL_ADD_NODE(&softc->sysctl_ctx,
@@ -1094,7 +1093,6 @@
 		CTLFLAG_RD, 0, tmpstr);
 	if (softc->sysctl_tree == NULL) {
 		printf("dasysctlinit: unable to allocate sysctl tree\n");
-		mtx_unlock(&Giant);
 		cam_periph_release(periph);
 		return;
 	}
@@ -1108,7 +1106,6 @@
 		&softc->minimum_cmd_size, 0, dacmdsizesysctl, "I",
 		"Minimum CDB size");
 
-	mtx_unlock(&Giant);
 	cam_periph_release(periph);
 }
 

==== //depot/projects/smpng/sys/dev/arcmsr/arcmsr.c#19 (text+ko) ====

@@ -56,7 +56,7 @@
 **                                                       and cause g_vfs_done() read write error
 **     1.20.00.15   10/10/2007         Erich Chen        support new RAID adapter type ARC120x
 ******************************************************************************************
-* $FreeBSD: src/sys/dev/arcmsr/arcmsr.c,v 1.28 2008/09/27 08:51:18 ed Exp $
+* $FreeBSD: src/sys/dev/arcmsr/arcmsr.c,v 1.29 2009/02/10 22:46:36 imp Exp $
 */
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -140,12 +140,12 @@
 */
 static struct CommandControlBlock * arcmsr_get_freesrb(struct AdapterControlBlock *acb);
 static u_int8_t arcmsr_seek_cmd2abort(union ccb * abortccb);
-static u_int32_t arcmsr_probe(device_t dev);
-static u_int32_t arcmsr_attach(device_t dev);
-static u_int32_t arcmsr_detach(device_t dev);
+static int arcmsr_probe(device_t dev);
+static int arcmsr_attach(device_t dev);
+static int arcmsr_detach(device_t dev);
 static u_int32_t arcmsr_iop_ioctlcmd(struct AdapterControlBlock *acb, u_int32_t ioctl_cmd, caddr_t arg);
 static void arcmsr_iop_parking(struct AdapterControlBlock *acb);
-static void arcmsr_shutdown(device_t dev);
+static int arcmsr_shutdown(device_t dev);
 static void arcmsr_interrupt(struct AdapterControlBlock *acb);
 static void arcmsr_polling_srbdone(struct AdapterControlBlock *acb, struct CommandControlBlock *poll_srb);
 static void arcmsr_free_resource(struct AdapterControlBlock *acb);
@@ -3029,7 +3029,7 @@
 ************************************************************************
 ************************************************************************
 */
-static u_int32_t arcmsr_attach(device_t dev)
+static int arcmsr_attach(device_t dev)
 {
 	struct AdapterControlBlock *acb=(struct AdapterControlBlock *)device_get_softc(dev);
 	u_int32_t unit=device_get_unit(dev);
@@ -3152,7 +3152,7 @@
 ************************************************************************
 ************************************************************************
 */
-static u_int32_t arcmsr_probe(device_t dev)
+static int arcmsr_probe(device_t dev)
 {
 	u_int32_t id;
 	static char buf[256];
@@ -3197,7 +3197,7 @@
 ************************************************************************
 ************************************************************************
 */
-static void arcmsr_shutdown(device_t dev)
+static int arcmsr_shutdown(device_t dev)
 {
 	u_int32_t  i;
 	u_int32_t intmask_org;
@@ -3231,13 +3231,13 @@
 	acb->workingsrb_doneindex=0;
 	acb->workingsrb_startindex=0;
 	ARCMSR_LOCK_RELEASE(&acb->qbuffer_lock);
-	return;
+	return (0);
 }
 /*
 ************************************************************************
 ************************************************************************
 */
-static u_int32_t arcmsr_detach(device_t dev)
+static int arcmsr_detach(device_t dev)
 {
 	struct AdapterControlBlock *acb=(struct AdapterControlBlock *)device_get_softc(dev);
 	int i;

==== //depot/projects/smpng/sys/dev/ath/ath_hal/ar5212/ar5212_ani.c#4 (text+ko) ====

@@ -14,7 +14,7 @@
  * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  *
- * $FreeBSD: src/sys/dev/ath/ath_hal/ar5212/ar5212_ani.c,v 1.3 2009/01/28 18:00:22 sam Exp $
+ * $FreeBSD: src/sys/dev/ath/ath_hal/ar5212/ar5212_ani.c,v 1.4 2009/02/10 19:23:25 sam Exp $
  */
 #include "opt_ah.h"
 
@@ -278,14 +278,12 @@
 		if (on) {
 			OS_REG_SET_BIT(ah, AR_PHY_SFCORR_LOW,
 				AR_PHY_SFCORR_LOW_USE_SELF_CORR_LOW);
+			ahp->ah_stats.ast_ani_ofdmon++;
 		} else {
 			OS_REG_CLR_BIT(ah, AR_PHY_SFCORR_LOW,
 				AR_PHY_SFCORR_LOW_USE_SELF_CORR_LOW);
+			ahp->ah_stats.ast_ani_ofdmoff++;
 		}
-		if (on)
-			ahp->ah_stats.ast_ani_ofdmon++;
-		else
-			ahp->ah_stats.ast_ani_ofdmoff++;
 		aniState->ofdmWeakSigDetectOff = !on;
 		break;
 	}

==== //depot/projects/smpng/sys/dev/ath/if_ath.c#66 (text+ko) ====

@@ -28,7 +28,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/ath/if_ath.c,v 1.229 2009/02/07 05:34:41 sam Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/ath/if_ath.c,v 1.233 2009/02/10 23:48:29 sam Exp $");
 
 /*
  * Driver for the Atheros Wireless LAN controller.
@@ -283,6 +283,10 @@
 	    0, "tx buffers allocated");
 TUNABLE_INT("hw.ath.txbuf", &ath_txbuf);
 
+static	int ath_bstuck_threshold = 4;		/* max missed beacons */
+SYSCTL_INT(_hw_ath, OID_AUTO, bstuck, CTLFLAG_RW, &ath_bstuck_threshold,
+	    0, "max missed beacon xmits before chip reset");
+
 #ifdef ATH_DEBUG
 enum {
 	ATH_DEBUG_XMIT		= 0x00000001,	/* basic xmit operation */
@@ -1201,7 +1205,9 @@
 	 * Must reset the chip before we reload the
 	 * keycache as we were powered down on suspend.
 	 */
-	ath_hal_reset(ah, sc->sc_opmode, sc->sc_curchan, AH_FALSE, &status);
+	ath_hal_reset(ah, sc->sc_opmode,
+	    sc->sc_curchan != NULL ? sc->sc_curchan : ic->ic_curchan,
+	    AH_FALSE, &status);
 	ath_reset_keycache(sc);
 	if (sc->sc_resume_up) {
 		if (ic->ic_opmode == IEEE80211_M_STA) {
@@ -1366,29 +1372,34 @@
 static void
 ath_bmiss_vap(struct ieee80211vap *vap)
 {
-	struct ifnet *ifp = vap->iv_ic->ic_ifp;
-	struct ath_softc *sc = ifp->if_softc;
-	u_int64_t lastrx = sc->sc_lastrx;
-	u_int64_t tsf = ath_hal_gettsf64(sc->sc_ah);
-	u_int bmisstimeout =
-		vap->iv_bmissthreshold * vap->iv_bss->ni_intval * 1024;
-
-	DPRINTF(sc, ATH_DEBUG_BEACON,
-	    "%s: tsf %llu lastrx %lld (%llu) bmiss %u\n",
-	    __func__, (unsigned long long) tsf,
-	    (unsigned long long)(tsf - lastrx),
-	    (unsigned long long) lastrx, bmisstimeout);
 	/*
 	 * Workaround phantom bmiss interrupts by sanity-checking
 	 * the time of our last rx'd frame.  If it is within the
 	 * beacon miss interval then ignore the interrupt.  If it's
 	 * truly a bmiss we'll get another interrupt soon and that'll
-	 * be dispatched up for processing.
+	 * be dispatched up for processing.  Note this applies only
+	 * for h/w beacon miss events.
 	 */
-	if (tsf - lastrx > bmisstimeout)
-		ATH_VAP(vap)->av_bmiss(vap);
-	else
-		sc->sc_stats.ast_bmiss_phantom++;
+	if ((vap->iv_flags_ext & IEEE80211_FEXT_SWBMISS) == 0) {
+		struct ifnet *ifp = vap->iv_ic->ic_ifp;
+		struct ath_softc *sc = ifp->if_softc;
+		u_int64_t lastrx = sc->sc_lastrx;
+		u_int64_t tsf = ath_hal_gettsf64(sc->sc_ah);
+		u_int bmisstimeout =
+			vap->iv_bmissthreshold * vap->iv_bss->ni_intval * 1024;
+
+		DPRINTF(sc, ATH_DEBUG_BEACON,
+		    "%s: tsf %llu lastrx %lld (%llu) bmiss %u\n",
+		    __func__, (unsigned long long) tsf,
+		    (unsigned long long)(tsf - lastrx),
+		    (unsigned long long) lastrx, bmisstimeout);
+
+		if (tsf - lastrx <= bmisstimeout) {
+			sc->sc_stats.ast_bmiss_phantom++;
+			return;
+		}
+	}
+	ATH_VAP(vap)->av_bmiss(vap);
 }
 
 static int
@@ -3116,7 +3127,7 @@
 		DPRINTF(sc, ATH_DEBUG_BEACON,
 			"%s: missed %u consecutive beacons\n",
 			__func__, sc->sc_bmisscount);
-		if (sc->sc_bmisscount > 3)		/* NB: 3 is a guess */
+		if (sc->sc_bmisscount >= ath_bstuck_threshold)
 			taskqueue_enqueue(sc->sc_tq, &sc->sc_bstucktask);
 		return;
 	}
@@ -6087,6 +6098,8 @@
 		/* XXX locking? */
 		ni->ni_ucastkey.wk_keyix = keyix;
 		ni->ni_ucastkey.wk_rxkeyix = rxkeyix;
+		/* NB: must mark device key to get called back on delete */
+		ni->ni_ucastkey.wk_flags |= IEEE80211_KEY_DEVKEY;
 		IEEE80211_ADDR_COPY(ni->ni_ucastkey.wk_macaddr, ni->ni_macaddr);
 		/* NB: this will create a pass-thru key entry */
 		ath_keyset(sc, &ni->ni_ucastkey, vap->iv_bss);
@@ -7610,7 +7623,7 @@
 		DPRINTF(sc, ATH_DEBUG_BEACON,
 			"%s: missed %u consecutive beacons\n",
 			__func__, sc->sc_bmisscount);
-		if (sc->sc_bmisscount > 3)		/* NB: 3 is a guess */
+		if (sc->sc_bmisscount >= ath_bstuck_threshold)
 			taskqueue_enqueue(sc->sc_tq, &sc->sc_bstucktask);
 		return;
 	}

==== //depot/projects/smpng/sys/dev/bge/if_bge.c#104 (text+ko) ====

@@ -32,7 +32,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/bge/if_bge.c,v 1.217 2009/02/05 18:43:13 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/bge/if_bge.c,v 1.218 2009/02/10 21:54:23 marius Exp $");
 
 /*
  * Broadcom BCM570x family gigabit ethernet driver for FreeBSD.
@@ -2674,11 +2674,11 @@
 		 * if we get a conflict with the ASF firmware accessing
 		 * the PHY.
 		 */
+		trys = 0;
 		BGE_CLRBIT(sc, BGE_MODE_CTL, BGE_MODECTL_STACKUP);
 again:
 		bge_asf_driver_up(sc);
 
-		trys = 0;
 		if (mii_phy_probe(dev, &sc->bge_miibus,
 		    bge_ifmedia_upd, bge_ifmedia_sts)) {
 			if (trys++ < 4) {

==== //depot/projects/smpng/sys/dev/iicbus/if_ic.c#19 (text+ko) ====

@@ -25,7 +25,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/iicbus/if_ic.c,v 1.28 2009/01/06 17:23:37 nwhitehorn Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/iicbus/if_ic.c,v 1.29 2009/02/10 22:50:23 imp Exp $");
 
 /*
  * I2C bus IP driver
@@ -105,7 +105,7 @@
 static int icoutput(struct ifnet *, struct mbuf *, struct sockaddr *,
 		struct rtentry *);
 
-static void icintr(device_t, int, char *);
+static int icintr(device_t, int, char *);
 
 static device_method_t ic_methods[] = {
 	/* device interface */
@@ -272,7 +272,7 @@
 /*
  * icintr()
  */
-static void
+static int
 icintr(device_t dev, int event, char *ptr)
 {
 	struct ic_softc *sc = (struct ic_softc *)device_get_softc(dev);
@@ -346,7 +346,7 @@
 	}
 
 	mtx_unlock(&sc->ic_lock);
-	return;
+	return (0);
 }
 
 /*

==== //depot/projects/smpng/sys/dev/iicbus/iicbb.c#10 (text+ko) ====

@@ -25,7 +25,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/iicbus/iicbb.c,v 1.20 2008/08/04 20:46:15 jhb Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/iicbus/iicbb.c,v 1.21 2009/02/10 22:50:23 imp Exp $");
 
 /*
  * Generic I2C bit-banging code
@@ -72,7 +72,7 @@
 static int iicbb_callback(device_t, int, caddr_t);
 static int iicbb_start(device_t, u_char, int);
 static int iicbb_stop(device_t);
-static int iicbb_write(device_t, char *, int, int *, int);
+static int iicbb_write(device_t, const char *, int, int *, int);
 static int iicbb_read(device_t, char *, int, int *, int, int);
 static int iicbb_reset(device_t, u_char, u_char, u_char *);
 
@@ -372,7 +372,7 @@
 }
 
 static int
-iicbb_write(device_t dev, char * buf, int len, int *sent, int timeout)
+iicbb_write(device_t dev, const char *buf, int len, int *sent, int timeout)
 {
 	int bytes, error = 0;
 

==== //depot/projects/smpng/sys/dev/iicbus/iicbus.c#14 (text+ko) ====

@@ -25,7 +25,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/iicbus/iicbus.c,v 1.28 2009/01/20 00:05:43 nwhitehorn Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/iicbus/iicbus.c,v 1.29 2009/02/10 22:50:23 imp Exp $");
 
 /*
  * Autoconfiguration and support routines for the Philips serial I2C bus
@@ -173,7 +173,7 @@
 }
 
 static int
-iicbus_read_ivar(device_t bus, device_t child, int which, u_char *result)
+iicbus_read_ivar(device_t bus, device_t child, int which, uintptr_t *result)
 {
 	struct iicbus_ivar *devi = IICBUS_IVAR(child);
 

==== //depot/projects/smpng/sys/dev/iicbus/iicsmb.c#10 (text+ko) ====

@@ -23,7 +23,7 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
- * $FreeBSD: src/sys/dev/iicbus/iicsmb.c,v 1.17 2009/01/06 17:23:37 nwhitehorn Exp $
+ * $FreeBSD: src/sys/dev/iicbus/iicsmb.c,v 1.18 2009/02/10 22:50:23 imp Exp $
  *
  */
 
@@ -84,7 +84,7 @@
 static int iicsmb_detach(device_t);
 static void iicsmb_identify(driver_t *driver, device_t parent);
 
-static void iicsmb_intr(device_t dev, int event, char *buf);
+static int iicsmb_intr(device_t dev, int event, char *buf);
 static int iicsmb_callback(device_t dev, int index, void *data);
 static int iicsmb_quick(device_t dev, u_char slave, int how);
 static int iicsmb_sendb(device_t dev, u_char slave, char byte);
@@ -186,7 +186,7 @@
  *
  * iicbus interrupt handler
  */
-static void
+static int
 iicsmb_intr(device_t dev, int event, char *buf)
 {
 	struct iicsmb_softc *sc = (struct iicsmb_softc *)device_get_softc(dev);
@@ -252,7 +252,7 @@
 	}
 	mtx_unlock(&sc->lock);
 
-	return;
+	return (0);
 }
 
 static int

==== //depot/projects/smpng/sys/dev/ppbus/lpt.c#25 (text+ko) ====

@@ -51,7 +51,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/ppbus/lpt.c,v 1.48 2009/01/26 20:58:05 jhb Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/ppbus/lpt.c,v 1.49 2009/02/11 14:25:09 jhb Exp $");
 
 /*
  * Device Driver for AT parallel printer port
@@ -544,10 +544,10 @@
 	do {
 		/* ran out of waiting for the printer */
 		if (trys++ >= LPINITRDY*4) {
-			sc->sc_state = 0;
 			lprintf(("status %x\n", ppb_rstr(ppbus)));
 
 			lpt_release_ppbus(lptdev);
+			sc->sc_state = 0;
 			ppb_unlock(ppbus);
 			return (EBUSY);
 		}
@@ -555,9 +555,8 @@
 		/* wait 1/4 second, give up if we get a signal */
 		if (ppb_sleep(ppbus, lptdev, LPPRI | PCATCH, "lptinit",
 		    hz / 4) != EWOULDBLOCK) {
+			lpt_release_ppbus(lptdev);
 			sc->sc_state = 0;
-
-			lpt_release_ppbus(lptdev);
 			ppb_unlock(ppbus);
 			return (EBUSY);
 		}
@@ -577,7 +576,8 @@
 
 	ppb_wctr(ppbus, sc->sc_control);
 
-	sc->sc_state = OPEN;
+	sc->sc_state &= ~LPTINIT;
+	sc->sc_state |= OPEN;
 	sc->sc_xfercnt = 0;
 
 	/* only use timeout if using interrupt */
@@ -611,11 +611,8 @@
 	int err;
 
 	ppb_lock(ppbus);
-	if (sc->sc_flags & LP_BYPASS) {
-		sc->sc_state = 0;
-		ppb_unlock(ppbus);
+	if (sc->sc_flags & LP_BYPASS)
 		goto end_close;
-	}
 
 	if ((err = lpt_request_ppbus(lptdev, PPB_WAIT|PPB_INTR)) != 0) {
 		ppb_unlock(ppbus);
@@ -635,16 +632,16 @@
 	sc->sc_state &= ~OPEN;
 	callout_stop(&sc->sc_timer);
 	ppb_wctr(ppbus, LPC_NINIT);
-	sc->sc_state = 0;
-	sc->sc_xfercnt = 0;
 
 	/*
 	 * unregistration of interrupt forced by release
 	 */
 	lpt_release_ppbus(lptdev);
-	ppb_unlock(ppbus);
 
 end_close:
+	sc->sc_state = 0;
+	sc->sc_xfercnt = 0;
+	ppb_unlock(ppbus);
 	lprintf(("closed.\n"));
 	return(0);
 }

==== //depot/projects/smpng/sys/dev/ppc/ppc_pci.c#4 (text) ====

@@ -25,7 +25,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/ppc/ppc_pci.c,v 1.3 2009/01/21 23:10:06 jhb Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/ppc/ppc_pci.c,v 1.4 2009/02/11 00:08:03 kaiw Exp $");
 
 #include <sys/param.h>
 #include <sys/kernel.h>
@@ -84,6 +84,7 @@
 static struct pci_id pci_ids[] = {
 	{ 0x1020131f, "SIIG Cyber Parallel PCI (10x family)", 0x18 },
 	{ 0x2020131f, "SIIG Cyber Parallel PCI (20x family)", 0x10 },
+	{ 0x05111407, "Lava SP BIDIR Parallel PCI", 0x10 },
 	{ 0x80001407, "Lava Computers 2SP-PCI parallel port", 0x10 },
 	{ 0x84031415, "Oxford Semiconductor OX12PCI840 Parallel port", 0x10 },
 	{ 0x95131415, "Oxford Semiconductor OX16PCI954 Parallel port", 0x10 },

==== //depot/projects/smpng/sys/dev/re/if_re.c#71 (text+ko) ====

@@ -31,7 +31,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/re/if_re.c,v 1.152 2009/02/09 04:59:13 yongari Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/re/if_re.c,v 1.153 2009/02/11 00:23:56 yongari Exp $");
 
 /*
  * RealTek 8139C+/8169/8169S/8110S/8168/8111/8101E PCI NIC driver
@@ -1149,7 +1149,8 @@
 		if (bootverbose)
 			device_printf(dev, "MSI count : %d\n", msic);
 	}
-	if (msic == RL_MSI_MESSAGES  && msi_disable == 0) {
+	if (msic > 0 && msi_disable == 0) {
+		msic = 1;
 		if (pci_alloc_msi(dev, &msic) == 0) {
 			if (msic == RL_MSI_MESSAGES) {
 				device_printf(dev, "Using %d MSI messages\n",

==== //depot/projects/smpng/sys/dev/sdhci/sdhci.c#6 (text+ko) ====

@@ -24,7 +24,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/sdhci/sdhci.c,v 1.6 2009/01/28 22:53:41 mav Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/sdhci/sdhci.c,v 1.7 2009/02/10 23:13:48 imp Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -1427,7 +1427,7 @@
 }
 
 static int
-sdhci_read_ivar(device_t bus, device_t child, int which, u_char *result)
+sdhci_read_ivar(device_t bus, device_t child, int which, uintptr_t *result)
 {
 	struct sdhci_slot *slot = device_get_ivars(child);
 

==== //depot/projects/smpng/sys/dev/sis/if_sis.c#3 (text+ko) ====

@@ -32,7 +32,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/sis/if_sis.c,v 1.5 2008/12/09 04:30:47 yongari Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/sis/if_sis.c,v 1.6 2009/02/10 23:17:20 imp Exp $");
 
 /*
  * SiS 900/SiS 7016 fast ethernet PCI NIC driver. Datasheets are
@@ -2257,7 +2257,7 @@
  * Stop all chip I/O so that the kernel's probe routines don't
  * get confused by errant DMAs when rebooting.
  */
-static void
+static int
 sis_shutdown(device_t dev)
 {
 	struct sis_softc	*sc;
@@ -2267,6 +2267,7 @@
 	sis_reset(sc);
 	sis_stop(sc);
 	SIS_UNLOCK(sc);
+	return (0);
 }
 
 static device_method_t sis_methods[] = {

==== //depot/projects/smpng/sys/dev/sound/pci/envy24.c#13 (text+ko) ====

@@ -20,7 +20,7 @@
  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHERIN CONTRACT, STRICT
  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THEPOSSIBILITY OF
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
  */
@@ -35,7 +35,7 @@
 
 #include "mixer_if.h"
 
-SND_DECLARE_FILE("$FreeBSD: src/sys/dev/sound/pci/envy24.c,v 1.14 2007/10/12 06:03:44 kevlo Exp $");
+SND_DECLARE_FILE("$FreeBSD: src/sys/dev/sound/pci/envy24.c,v 1.15 2009/02/11 10:29:45 netchild Exp $");
 
 MALLOC_DEFINE(M_ENVY24, "envy24", "envy24 audio");
 
@@ -278,7 +278,7 @@
 		"Envy24 audio (M Audio Delta Dio 2496)",
 		0x1412, 0xd631,
 		0x10, 0x80, 0xf0, 0x03,
-		0xff, 0x00, 0x00,
+		0x02, 0xc0, 0xfd,
 		0x10, 0x20, 0x40, 0x00, 0x00,
 		0x00,
 		&delta_codec,
@@ -301,6 +301,51 @@
 		0x00,
  		&delta_codec,
  	},
+        {
+                "Envy24 audio (M Audio Delta 66)",
+                0x1412, 0xd632,
+                0x15, 0x80, 0xf0, 0x03,
+                0x02, 0xc0, 0xfd,
+                0x10, 0x20, 0x40, 0x00, 0x00,
+                0x00,
+                &delta_codec,
+        },
+        {
+                "Envy24 audio (M Audio Delta 44)",
+                0x1412, 0xd633,
+                0x15, 0x80, 0xf0, 0x00,
+                0x02, 0xc0, 0xfd,
+                0x10, 0x20, 0x40, 0x00, 0x00,
+                0x00,
+                &delta_codec,
+        },
+        {
+                "Envy24 audio (M Audio Delta 1010)",
+                0x1412, 0xd630,
+                0x1f, 0x80, 0xf0, 0x03,
+                0x22, 0xd0, 0xdd,
+                0x10, 0x20, 0x40, 0x00, 0x00,
+                0x00,
+                &delta_codec,
+        },
+        {
+                "Envy24 audio (M Audio Delta 1010LT)",
+                0x1412, 0xd63b,
+                0x1f, 0x80, 0x72, 0x03,
+                0x04, 0x7e, 0xfb,
+                0x08, 0x02, 0x70, 0x00, 0x00,
+                0x00,
+                &delta_codec,
+        },
+        {
+                "Envy24 audio (Terratec EWX 2496)",
+                0x153b, 0x1130,
+                0x10, 0x80, 0xf0, 0x03,
+                0xc0, 0x3f, 0x3f,
+                0x10, 0x20, 0x01, 0x01, 0x00,
+                0x00,
+                &delta_codec,
+        },
 	{
 		"Envy24 audio (Generic)",
 		0, 0,

==== //depot/projects/smpng/sys/dev/sound/pci/envy24ht.c#10 (text+ko) ====

@@ -47,7 +47,7 @@
 
 #include "mixer_if.h"
 
-SND_DECLARE_FILE("$FreeBSD: src/sys/dev/sound/pci/envy24ht.c,v 1.16 2007/10/12 06:03:44 kevlo Exp $");
+SND_DECLARE_FILE("$FreeBSD: src/sys/dev/sound/pci/envy24ht.c,v 1.17 2009/02/11 10:29:45 netchild Exp $");
 
 MALLOC_DEFINE(M_ENVY24HT, "envy24ht", "envy24ht audio");
 
@@ -323,7 +323,7 @@
                 0x153b, 0x1150,
                 0x10, 0x80, 0xf0, 0xc3,
                 0x7ffbc7, 0x7fffff, 0x438,
-                0x20, 0x10, 0x400, 0x00, 0x00,
+                0x10, 0x20, 0x400, 0x01, 0x00,
                 0,
                 &spi_codec,
         },
@@ -349,7 +349,7 @@
                 "Envy24HT audio (M-Audio Revolution 7.1)",
                 0x1412, 0x3630,
                 0x43, 0x80, 0xf8, 0xc1,
-                0x3fff85, 0x72, 0x4000fa,
+                0x3fff85, 0x400072, 0x4000fa,
                 0x08, 0x02, 0x20, 0x00, 0x04,
                 0,
                 &spi_codec,
@@ -358,7 +358,7 @@
                 "Envy24GT audio (M-Audio Revolution 5.1)",
                 0x1412, 0x3631,
                 0x42, 0x80, 0xf8, 0xc1,
-                0x3fff85, 0x72, 0x4000fa,
+                0x3fff05, 0x4000f0, 0x4000fa,
                 0x08, 0x02, 0x10, 0x00, 0x03,
                 0,
                 &spi_codec,
@@ -391,6 +391,15 @@
                 &spi_codec,
         },
 	{
+                "Envy24HT-S audio (Terrasoniq TS22PCI)",
+                0x153b, 0x117b,
+                0x10, 0x80, 0xf0, 0xc3,
+                0x7ffbc7, 0x7fffff, 0x438,
+                0x10, 0x20, 0x400, 0x01, 0x00,
+                0,
+                &spi_codec,
+	},
+	{
 		"Envy24HT audio (Generic)",
 		0, 0,
 		0x0b, 0x80, 0xfc, 0xc3,

==== //depot/projects/smpng/sys/dev/sound/pci/spicds.c#4 (text+ko) ====

@@ -24,7 +24,7 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THEPOSSIBILITY OF
  * SUCH DAMAGE.
  *
- * $FreeBSD: src/sys/dev/sound/pci/spicds.c,v 1.6 2007/05/27 19:58:39 joel Exp $
+ * $FreeBSD: src/sys/dev/sound/pci/spicds.c,v 1.7 2009/02/11 10:29:45 netchild Exp $
  */
 
 #include <dev/sound/pcm/sound.h>
@@ -234,7 +234,7 @@
 	if (codec->type == SPICDS_TYPE_AK4358) 
 	spicds_wrcd(codec, 0x00, 0x07);		/* I2S, 24bit, power-up */
 	if (codec->type == SPICDS_TYPE_AK4381)
-	spicds_wrcd(codec, 0x00, 0x0f);		/* I2S, 24bit, power-up */
+	spicds_wrcd(codec, 0x00, 0x8f);		/* I2S, 24bit, power-up */
 	if (codec->type == SPICDS_TYPE_AK4396)
 	spicds_wrcd(codec, 0x00, 0x07);		/* I2S, 24bit, power-up */
 	snd_mtxunlock(codec->lock);
@@ -296,7 +296,8 @@
 		case SPICDS_TYPE_WM8770:
                         right = right + 27;
 			break;
-		case SPICDS_TYPE_AK4381 || SPICDS_TYPE_AK4396:
+		case SPICDS_TYPE_AK4381: 
+		case SPICDS_TYPE_AK4396:
 			right = right * 255 / 100;
 			break;
                 default:   

==== //depot/projects/smpng/sys/dev/tl/if_tl.c#2 (text+ko) ====

@@ -31,7 +31,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/tl/if_tl.c,v 1.1 2008/08/14 20:02:34 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/tl/if_tl.c,v 1.2 2009/02/10 23:17:20 imp Exp $");
 
 /*
  * Texas Instruments ThunderLAN driver for FreeBSD 2.2.6 and 3.x.
@@ -282,7 +282,7 @@
 static void tl_init_locked(struct tl_softc *);
 static void tl_stop(struct tl_softc *);
 static void tl_watchdog(struct ifnet *);
-static void tl_shutdown(device_t);
+static int tl_shutdown(device_t);
 static int tl_ifmedia_upd(struct ifnet *);
 static void tl_ifmedia_sts(struct ifnet *, struct ifmediareq *);
 
@@ -2347,7 +2347,7 @@
  * Stop all chip I/O so that the kernel's probe routines don't
  * get confused by errant DMAs when rebooting.
  */
-static void
+static int
 tl_shutdown(dev)
 	device_t		dev;
 {
@@ -2359,5 +2359,5 @@
 	tl_stop(sc);
 	TL_UNLOCK(sc);
 
-	return;
+	return (0);
 }

==== //depot/projects/smpng/sys/dev/tx/if_tx.c#31 (text+ko) ====

@@ -25,7 +25,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/tx/if_tx.c,v 1.99 2008/09/12 14:41:53 jhb Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/tx/if_tx.c,v 1.100 2009/02/10 23:17:20 imp Exp $");
 
 /*
  * EtherPower II 10/100 Fast Ethernet (SMC 9432 serie)
@@ -122,7 +122,7 @@
 
 static int epic_probe(device_t);
 static int epic_attach(device_t);
-static void epic_shutdown(device_t);
+static int epic_shutdown(device_t);
 static int epic_detach(device_t);
 static void epic_release(epic_softc_t *);
 static struct epic_type *epic_devtype(device_t);
@@ -502,7 +502,7 @@
  * Stop all chip I/O so that the kernel's probe routines don't
  * get confused by errant DMAs when rebooting.
  */
-static void
+static int
 epic_shutdown(device_t dev)
 {
 	epic_softc_t *sc;
@@ -512,6 +512,7 @@
 	EPIC_LOCK(sc);
 	epic_stop(sc);
 	EPIC_UNLOCK(sc);
+	return (0);
 }
 
 /*

==== //depot/projects/smpng/sys/dev/uart/uart_bus_pci.c#10 (text+ko) ====

@@ -25,7 +25,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/uart/uart_bus_pci.c,v 1.11 2007/05/17 04:07:19 marcel Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/uart/uart_bus_pci.c,v 1.12 2009/02/11 00:08:03 kaiw Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -96,6 +96,7 @@
 	0x18 },
 { 0x1407, 0x0110, 0xffff, 0, "Lava Computer mfg DSerial-PCI Port A", 0x10 },
 { 0x1407, 0x0111, 0xffff, 0, "Lava Computer mfg DSerial-PCI Port B", 0x10 },
+{ 0x1407, 0x0510, 0xffff, 0, "Lava SP Serial 550 PCI", 0x10 },
 { 0x1409, 0x7168, 0x1409, 0x4025, "Timedia Technology Serial Port", 0x10,
 	8 * DEFAULT_RCLK },
 { 0x1409, 0x7168, 0x1409, 0x4027, "Timedia Technology Serial Port", 0x10,

==== //depot/projects/smpng/sys/ia64/ia64/mp_machdep.c#40 (text+ko) ====

@@ -26,7 +26,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/ia64/ia64/mp_machdep.c,v 1.71 2008/10/19 20:14:48 marcel Exp $");
+__FBSDID("$FreeBSD: src/sys/ia64/ia64/mp_machdep.c,v 1.72 2009/02/10 20:29:57 marcel Exp $");
 
 #include "opt_kstack_pages.h"
 
@@ -267,7 +267,8 @@
 			if (!ap_awake)
 				printf("SMP: WARNING: cpu%d did not wake up\n",
 				    pc->pc_cpuid);
-		}
+		} else
+			pc->pc_awake = 1;
 	}
 }
 

==== //depot/projects/smpng/sys/kern/kern_linker.c#98 (text+ko) ====

@@ -25,7 +25,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/kern/kern_linker.c,v 1.165 2009/02/06 14:51:32 jhb Exp $");
+__FBSDID("$FreeBSD: src/sys/kern/kern_linker.c,v 1.166 2009/02/10 15:50:19 attilio Exp $");
 
 #include "opt_ddb.h"
 #include "opt_hwpmc_hooks.h"

>>> TRUNCATED FOR MAIL (1000 lines) <<<



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