Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 31 May 2008 13:13:35 GMT
From:      Vincenzo Iozzo <snagg@FreeBSD.org>
To:        Perforce Change Reviews <perforce@FreeBSD.org>
Subject:   PERFORCE change 142626 for review
Message-ID:  <200805311313.m4VDDZbG007112@repoman.freebsd.org>

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

Change 142626 by snagg@snagg_macosx on 2008/05/31 13:12:47

	IFC

Affected files ...

.. //depot/projects/soc2008/snagg-audit/sys/dev/snc/dp83932.c#2 integrate
.. //depot/projects/soc2008/snagg-audit/sys/dev/snc/dp83932subr.c#2 integrate
.. //depot/projects/soc2008/snagg-audit/sys/dev/snc/dp83932var.h#2 integrate
.. //depot/projects/soc2008/snagg-audit/sys/dev/snc/if_sncreg.h#2 integrate
.. //depot/projects/soc2008/snagg-audit/sys/i386/cpufreq/est.c#3 integrate
.. //depot/projects/soc2008/snagg-audit/sys/modules/dtrace/Makefile#3 integrate

Differences ...

==== //depot/projects/soc2008/snagg-audit/sys/dev/snc/dp83932.c#2 (text+ko) ====

@@ -1,4 +1,4 @@
-/*	$FreeBSD: src/sys/dev/snc/dp83932.c,v 1.23 2005/12/06 11:19:37 ru Exp $	*/
+/*	$FreeBSD: src/sys/dev/snc/dp83932.c,v 1.24 2008/05/30 21:48:04 jhb Exp $	*/
 /*	$NecBSD: dp83932.c,v 1.5 1999/07/29 05:08:44 kmatsuda Exp $	*/
 /*	$NetBSD: if_snc.c,v 1.18 1998/04/25 21:27:40 scottr Exp $	*/
 
@@ -70,9 +70,6 @@
 #include <sys/socket.h>
 #include <sys/syslog.h>
 #include <sys/errno.h>
-#if defined(NRND) && NRND > 0
-#include <sys/rnd.h>
-#endif
 
 #include <net/ethernet.h>
 #include <net/if.h>
@@ -88,29 +85,29 @@
 #include <dev/snc/dp83932reg.h>
 #include <dev/snc/dp83932var.h>
 
-hide void	sncwatchdog(struct ifnet *);
-hide void	sncinit(void *);
-hide int	sncstop(struct snc_softc *sc);
-hide int	sncioctl(struct ifnet *ifp, u_long cmd, caddr_t data);
-hide void	sncstart(struct ifnet *ifp);
-hide void	sncreset(struct snc_softc *sc);
+static void	sncwatchdog(struct ifnet *);
+static void	sncinit(void *);
+static int	sncstop(struct snc_softc *sc);
+static int	sncioctl(struct ifnet *ifp, u_long cmd, caddr_t data);
+static void	sncstart(struct ifnet *ifp);
+static void	sncreset(struct snc_softc *sc);
 
-hide void	caminitialise(struct snc_softc *);
-hide void	camentry(struct snc_softc *, int, u_char *ea);
-hide void	camprogram(struct snc_softc *);
-hide void	initialise_tda(struct snc_softc *);
-hide void	initialise_rda(struct snc_softc *);
-hide void	initialise_rra(struct snc_softc *);
+static void	caminitialise(struct snc_softc *);
+static void	camentry(struct snc_softc *, int, u_char *ea);
+static void	camprogram(struct snc_softc *);
+static void	initialise_tda(struct snc_softc *);
+static void	initialise_rda(struct snc_softc *);
+static void	initialise_rra(struct snc_softc *);
 #ifdef SNCDEBUG
-hide void	camdump(struct snc_softc *sc);
+static void	camdump(struct snc_softc *sc);
 #endif
 
-hide void	sonictxint(struct snc_softc *);
-hide void	sonicrxint(struct snc_softc *);
+static void	sonictxint(struct snc_softc *);
+static void	sonicrxint(struct snc_softc *);
 
-hide u_int	sonicput(struct snc_softc *sc, struct mbuf *m0, int mtd_next);
-hide int	sonic_read(struct snc_softc *, u_int32_t, int);
-hide struct mbuf *sonic_get(struct snc_softc *, u_int32_t, int);
+static u_int	sonicput(struct snc_softc *sc, struct mbuf *m0, int mtd_next);
+static int	sonic_read(struct snc_softc *, u_int32_t, int);
+static struct mbuf *sonic_get(struct snc_softc *, u_int32_t, int);
 
 int	snc_enable(struct snc_softc *);
 void	snc_disable(struct snc_softc *);
@@ -118,14 +115,6 @@
 int	snc_mediachange(struct ifnet *);
 void	snc_mediastatus(struct ifnet *, struct ifmediareq *);
 
-#ifdef NetBSD
-#if NetBSD <= 199714
-struct cfdriver snc_cd = {
-	NULL, "snc", DV_IFNET
-};
-#endif
-#endif
-
 #undef assert
 #undef _assert
 
@@ -201,11 +190,6 @@
 	}
 
 	ether_ifattach(ifp, myea);
-
-#if defined(NRND) && NRND > 0
-	rnd_attach_source(&sc->rnd_source, device_get_nameunit(sc->sc_dev),
-	    RND_TYPE_NET, 0);
-#endif
 }
 
 void
@@ -251,7 +235,7 @@
 }
 
 
-hide int
+static int
 sncioctl(ifp, cmd, data)
 	struct ifnet *ifp;
 	u_long cmd;
@@ -259,7 +243,7 @@
 {
 	struct ifreq *ifr;
 	struct snc_softc *sc = ifp->if_softc;
-	int	s = splhardnet(), err = 0;
+	int	s = splimp(), err = 0;
 	int	temp;
 
 	switch (cmd) {
@@ -322,7 +306,7 @@
 /*
  * Encapsulate a packet of type family for the local net.
  */
-hide void
+static void
 sncstart(ifp)
 	struct ifnet *ifp;
 {
@@ -384,7 +368,7 @@
  * reset and restart the SONIC.  Called in case of fatal
  * hardware/software errors.
  */
-hide void
+static void
 sncreset(sc)
 	struct snc_softc *sc;
 {
@@ -392,7 +376,7 @@
 	sncinit(sc);
 }
 
-hide void
+static void
 sncinit(xsc)
 	void *xsc;
 {
@@ -404,7 +388,7 @@
 		/* already running */
 		return;
 
-	s = splhardnet();
+	s = splimp();
 
 	NIC_PUT(sc, SNCR_CR, CR_RST);	/* DCR only accessable in reset mode! */
 
@@ -464,12 +448,12 @@
  * Called on final close of device, or if sncinit() fails
  * part way through.
  */
-hide int
+static int
 sncstop(sc)
 	struct snc_softc *sc;
 {
 	struct mtd *mtd;
-	int	s = splhardnet();
+	int	s = splimp();
 
 	/* stick chip in reset */
 	NIC_PUT(sc, SNCR_CR, CR_RST);
@@ -498,7 +482,7 @@
  * In all cases we just reset the chip, and any retransmission
  * will be handled by higher level protocol timeouts.
  */
-hide void
+static void
 sncwatchdog(ifp)
 	struct ifnet *ifp;
 {
@@ -524,7 +508,7 @@
 /*
  * stuff packet into sonic (at splnet)
  */
-hide u_int
+static u_int
 sonicput(sc, m0, mtd_next)
 	struct snc_softc *sc;
 	struct mbuf *m0;
@@ -615,7 +599,7 @@
 /*
  * CAM support
  */
-hide void
+static void
 caminitialise(sc)
 	struct snc_softc *sc;
 {
@@ -639,7 +623,7 @@
 #endif
 }
 
-hide void
+static void
 camentry(sc, entry, ea)
 	int entry;
 	u_char *ea;
@@ -656,7 +640,7 @@
 	    (SRO(sc, v_cda, CDA_ENABLE) | (1 << entry)));
 }
 
-hide void
+static void
 camprogram(sc)
 	struct snc_softc *sc;
 {
@@ -718,7 +702,7 @@
 }
 
 #ifdef SNCDEBUG
-hide void
+static void
 camdump(sc)
 	struct snc_softc *sc;
 {
@@ -744,7 +728,7 @@
 }
 #endif
 
-hide void
+static void
 initialise_tda(sc)
 	struct snc_softc *sc;
 {
@@ -766,7 +750,7 @@
 	NIC_PUT(sc, SNCR_CTDA, LOWER(sc->mtda[0].mtd_vtxp));
 }
 
-hide void
+static void
 initialise_rda(sc)
 	struct snc_softc *sc;
 {
@@ -795,7 +779,7 @@
 	wbflush();
 }
 
-hide void
+static void
 initialise_rra(sc)
 	struct snc_softc *sc;
 {
@@ -820,8 +804,8 @@
 		v = SONIC_GETDMA(sc->rbuf[i]);
 		SWO(sc, sc->v_rra[i], RXRSRC_PTRHI, UPPER(v));
 		SWO(sc, sc->v_rra[i], RXRSRC_PTRLO, LOWER(v));
-		SWO(sc, sc->v_rra[i], RXRSRC_WCHI, UPPER(NBPG/2));
-		SWO(sc, sc->v_rra[i], RXRSRC_WCLO, LOWER(NBPG/2));
+		SWO(sc, sc->v_rra[i], RXRSRC_WCHI, UPPER(PAGE_SIZE/2));
+		SWO(sc, sc->v_rra[i], RXRSRC_WCLO, LOWER(PAGE_SIZE/2));
 	}
 	sc->sc_rramark = NRBA;
 	NIC_PUT(sc, SNCR_RWP, LOWER(sc->v_rra[sc->sc_rramark]));
@@ -889,11 +873,6 @@
 #endif
 		}
 		sncstart(sc->sc_ifp);
-
-#if defined(NRND) && NRND > 0
-		if (isr)
-			rnd_add_uint32(&sc->rnd_source, isr);
-#endif
 	}
 	return;
 }
@@ -901,7 +880,7 @@
 /*
  * Transmit interrupt routine
  */
-hide void
+static void
 sonictxint(sc)
 	struct snc_softc *sc;
 {
@@ -978,7 +957,7 @@
 /*
  * Receive interrupt routine
  */
-hide void
+static void
 sonicrxint(sc)
 	struct snc_softc *sc;
 {
@@ -1002,9 +981,9 @@
 		 */
 		len = SRO(sc, rda, RXPKT_BYTEC) - FCSSIZE;
 		if (status & RCR_PRX) {
-			/* XXX: Does PGOFSET require? */
+			/* XXX: Does PAGE_MASK require? */
 			u_int32_t pkt =
-			    sc->rbuf[orra & RBAMASK] + (rxpkt_ptr & PGOFSET);
+			    sc->rbuf[orra & RBAMASK] + (rxpkt_ptr & PAGE_MASK);
 			if (sonic_read(sc, pkt, len))
 				sc->sc_ifp->if_ipackets++;
 			else
@@ -1072,7 +1051,7 @@
  * sonic_read -- pull packet off interface and forward to
  * appropriate protocol handler
  */
-hide int
+static int
 sonic_read(sc, pkt, len)
 	struct snc_softc *sc;
 	u_int32_t pkt;
@@ -1117,7 +1096,7 @@
 /*
  * munge the received packet into an mbuf chain
  */
-hide struct mbuf *
+static struct mbuf *
 sonic_get(sc, pkt, datalen)
 	struct snc_softc *sc;
 	u_int32_t pkt;

==== //depot/projects/soc2008/snagg-audit/sys/dev/snc/dp83932subr.c#2 (text+ko) ====

@@ -33,7 +33,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/snc/dp83932subr.c,v 1.7 2005/01/06 01:43:15 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/snc/dp83932subr.c,v 1.8 2008/05/30 21:48:05 jhb Exp $");
 /*
  * Routines of NEC PC-9801-83, 84, 103, 104, PC-9801N-25 and PC-9801N-J02, J02R 
  * Ethernet interface for NetBSD/pc98, ported by Kouichi Matsuda.
@@ -56,15 +56,6 @@
 #include <net/if_arp.h>
 #include <net/if_media.h>
 
-#ifdef INET
-#include <netinet/in.h>
-#include <netinet/in_systm.h>
-#include <netinet/in_var.h>
-#include <netinet/ip.h>
-#include <netinet/if_inarp.h>
-#endif
-
-
 #include <sys/bus.h>
 #include <machine/bus.h>
 
@@ -73,7 +64,7 @@
 #include <dev/snc/if_sncreg.h>
 #include <dev/snc/dp83932subr.h>
 
-integrate u_int16_t snc_nec16_select_bank
+static __inline u_int16_t snc_nec16_select_bank
 	(struct snc_softc *, u_int32_t, u_int32_t);
 
 /*
@@ -131,27 +122,27 @@
 
 	p = SOALIGN(sc, p);
 
-	if ((p - pp) > NBPG) {
+	if ((p - pp) > PAGE_SIZE) {
 		device_printf (sc->sc_dev, "sizeof RRA (%ld) + CDA (%ld) +"
-		    "TDA (%ld) > NBPG (%d). Punt!\n",
-		    (ulong)sc->v_cda - (ulong)sc->v_rra[0],
-		    (ulong)sc->mtda[0].mtd_vtxp - (ulong)sc->v_cda,
-		    (ulong)p - (ulong)sc->mtda[0].mtd_vtxp,
-		    NBPG);
+		    "TDA (%ld) > PAGE_SIZE (%d). Punt!\n",
+		    (u_long)sc->v_cda - (u_long)sc->v_rra[0],
+		    (u_long)sc->mtda[0].mtd_vtxp - (u_long)sc->v_cda,
+		    (u_long)p - (u_long)sc->mtda[0].mtd_vtxp,
+		    PAGE_SIZE);
 		return(1);
 	}
 
-	p = pp + NBPG;
+	p = pp + PAGE_SIZE;
 	pp = p;
 
-	sc->sc_nrda = NBPG / RXPKT_SIZE(sc);
+	sc->sc_nrda = PAGE_SIZE / RXPKT_SIZE(sc);
 	sc->v_rda = SONIC_GETDMA(p);
 
-	p = pp + NBPG;
+	p = pp + PAGE_SIZE;
 
 	for (i = 0; i < NRBA; i++) {
 		sc->rbuf[i] = p;
-		p += NBPG;
+		p += PAGE_SIZE;
 	}
 
 	pp = p;
@@ -161,10 +152,10 @@
 
 		mtdp->mtd_vbuf = SONIC_GETDMA(p);
 		offset += TXBSIZE;
-		if (offset < NBPG) {
+		if (offset < PAGE_SIZE) {
 			p += TXBSIZE;
 		} else {
-			p = pp + NBPG;
+			p = pp + PAGE_SIZE;
 			pp = p;
 			offset = TXBSIZE;
 		}
@@ -396,7 +387,7 @@
 	/* select SONIC register SNCR_CR */
 	bus_space_write_1(iot, ioh, SNEC_ADDR, SNCR_CR);
 	bus_space_write_2(iot, ioh, SNEC_CTRL, CR_RXDIS | CR_STP | CR_RST);
-	delay(400);
+	DELAY(400);
 
 	cr = bus_space_read_2(iot, ioh, SNEC_CTRL);
 	if (cr != (CR_RXDIS | CR_STP | CR_RST)) {
@@ -535,7 +526,7 @@
  * select memory bank and map
  * where exists specified (internal buffer memory) offset.
  */
-integrate u_int16_t
+static __inline u_int16_t
 snc_nec16_select_bank(sc, base, offset)
 	struct snc_softc *sc;
 	u_int32_t base;
@@ -757,61 +748,61 @@
 		bus_space_write_1(iot, ioh, SNEC_ADDR, SNECR_EEP);
 
 		bus_space_write_1(iot, ioh, SNEC_CTRLB, 0x00);
-		delay(SNEC_EEP_DELAY);
+		DELAY(SNEC_EEP_DELAY);
 
 		/* Start EEPROM access. */
 		bus_space_write_1(iot, ioh, SNEC_CTRLB, SNECR_EEP_CS);
-		delay(SNEC_EEP_DELAY);
+		DELAY(SNEC_EEP_DELAY);
 
 		bus_space_write_1(iot, ioh, SNEC_CTRLB,
 		    SNECR_EEP_CS | SNECR_EEP_SK);
-		delay(SNEC_EEP_DELAY);
+		DELAY(SNEC_EEP_DELAY);
 
 		bus_space_write_1(iot, ioh, SNEC_CTRLB,
 		    SNECR_EEP_CS | SNECR_EEP_DI);
-		delay(SNEC_EEP_DELAY);
+		DELAY(SNEC_EEP_DELAY);
 
 		bus_space_write_1(iot, ioh, SNEC_CTRLB,
 		    SNECR_EEP_CS | SNECR_EEP_SK | SNECR_EEP_DI);
-		delay(SNEC_EEP_DELAY);
+		DELAY(SNEC_EEP_DELAY);
 
 		bus_space_write_1(iot, ioh, SNEC_CTRLB,
 		    SNECR_EEP_CS | SNECR_EEP_DI);
-		delay(SNEC_EEP_DELAY);
+		DELAY(SNEC_EEP_DELAY);
 
 		bus_space_write_1(iot, ioh, SNEC_CTRLB,
 		    SNECR_EEP_CS | SNECR_EEP_SK | SNECR_EEP_DI);
-		delay(SNEC_EEP_DELAY);
+		DELAY(SNEC_EEP_DELAY);
 
 		bus_space_write_1(iot, ioh, SNEC_CTRLB, SNECR_EEP_CS);
-		delay(SNEC_EEP_DELAY);
+		DELAY(SNEC_EEP_DELAY);
 
 		bus_space_write_1(iot, ioh, SNEC_CTRLB,
 		    SNECR_EEP_CS | SNECR_EEP_SK);
-		delay(SNEC_EEP_DELAY);
+		DELAY(SNEC_EEP_DELAY);
 
 		/* Pass the iteration count to the chip. */
 		for (bit = 0x20; bit != 0x00; bit >>= 1) {
 			bus_space_write_1(iot, ioh, SNEC_CTRLB, SNECR_EEP_CS |
 			    ((n & bit) ? SNECR_EEP_DI : 0x00));
-			delay(SNEC_EEP_DELAY);
+			DELAY(SNEC_EEP_DELAY);
 
 			bus_space_write_1(iot, ioh, SNEC_CTRLB,
 			    SNECR_EEP_CS | SNECR_EEP_SK |
 			    ((n & bit) ? SNECR_EEP_DI : 0x00));
-			delay(SNEC_EEP_DELAY);
+			DELAY(SNEC_EEP_DELAY);
 		}
 
 		bus_space_write_1(iot, ioh, SNEC_CTRLB, SNECR_EEP_CS);
 		(void) bus_space_read_1(iot, ioh, SNEC_CTRLB);	/* ACK */
-		delay(SNEC_EEP_DELAY);
+		DELAY(SNEC_EEP_DELAY);
 
 		/* Read a byte. */
 		val = 0;
 		for (bit = 0x80; bit != 0x00; bit >>= 1) {
 			bus_space_write_1(iot, ioh, SNEC_CTRLB,
 			    SNECR_EEP_CS | SNECR_EEP_SK);
-			delay(SNEC_EEP_DELAY);
+			DELAY(SNEC_EEP_DELAY);
 
 			bus_space_write_1(iot, ioh, SNEC_CTRLB, SNECR_EEP_CS);
 
@@ -825,7 +816,7 @@
 		for (bit = 0x80; bit != 0x00; bit >>= 1) {
 			bus_space_write_1(iot, ioh, SNEC_CTRLB,
 			    SNECR_EEP_CS | SNECR_EEP_SK);
-			delay(SNEC_EEP_DELAY);
+			DELAY(SNEC_EEP_DELAY);
 
 			bus_space_write_1(iot, ioh, SNEC_CTRLB, SNECR_EEP_CS);
 
@@ -835,7 +826,7 @@
 		*data++ = val;
 
 		bus_space_write_1(iot, ioh, SNEC_CTRLB, 0x00);
-		delay(SNEC_EEP_DELAY);
+		DELAY(SNEC_EEP_DELAY);
 	}
 
 #ifdef	SNCDEBUG
@@ -871,7 +862,7 @@
 	for (n = 0; n < SNC_NREGS; n++) {
 		/* select required SONIC register */
 		bus_space_write_1(iot, ioh, SNEC_ADDR, n);
-		delay(10);
+		DELAY(10);
 		val = bus_space_read_2(iot, ioh, SNEC_CTRL);
 		if ((n % 0x10) == 0)
 			printf("\n%04x ", val);
@@ -884,7 +875,7 @@
 	for (n = SNECR_MEMBS; n <= SNECR_IDENT; n += 2) {
 		/* select required SONIC register */
 		bus_space_write_1(iot, ioh, SNEC_ADDR, n);
-		delay(10);
+		DELAY(10);
 		val = (u_int16_t) bus_space_read_1(iot, ioh, SNEC_CTRLB);
 		printf("%04x ", val);
 	}

==== //depot/projects/soc2008/snagg-audit/sys/dev/snc/dp83932var.h#2 (text+ko) ====

@@ -1,4 +1,4 @@
-/*	$FreeBSD: src/sys/dev/snc/dp83932var.h,v 1.6 2005/12/06 11:19:37 ru Exp $	*/
+/*	$FreeBSD: src/sys/dev/snc/dp83932var.h,v 1.7 2008/05/30 21:48:05 jhb Exp $	*/
 /*	$NecBSD: dp83932var.h,v 1.3 1999/01/24 01:39:51 kmatsuda Exp $	*/
 /*	$NetBSD: if_snvar.h,v 1.12 1998/05/01 03:42:47 scottr Exp $	*/
 
@@ -23,31 +23,6 @@
  * (64 * 16 bits) Microwire Serial EEPROM.
  */
 
-/* borrow from arch/mac68k/dev/if_mcvar.h for debug. */
-#ifdef DDB
-#define	integrate
-#define hide
-#else
-#define	integrate	static __inline
-#define hide		static
-#endif
-
-/* NetBSD Emulation */
-#ifdef __NetBSD__
-#define	splhardnet	splnet
-#endif
-#ifdef __FreeBSD__
-#define	splhardnet	splimp
-#ifndef NBPG
-#define NBPG PAGE_SIZE
-#endif
-#ifndef PGOFSET
-#define PGOFSET PAGE_MASK
-#endif
-typedef unsigned long ulong;
-#define delay(x) DELAY(x)
-#endif
-
 /*
  * Vendor types
  */
@@ -225,10 +200,6 @@
 
 	void	*sc_sh;		/* shutdownhook cookie */
 	int	gone;
-
-#if defined(NRND) && NRND > 0
-	rndsource_element_t	rnd_source;
-#endif
 } snc_softc_t;
 
 /*

==== //depot/projects/soc2008/snagg-audit/sys/dev/snc/if_sncreg.h#2 (text+ko) ====

@@ -1,4 +1,4 @@
-/*	$FreeBSD: src/sys/dev/snc/if_sncreg.h,v 1.2 2005/01/06 01:43:15 imp Exp $	*/
+/*	$FreeBSD: src/sys/dev/snc/if_sncreg.h,v 1.3 2008/05/30 21:48:05 jhb Exp $	*/
 /*	$NecBSD: if_snreg.h,v 1.3 1999/01/24 01:39:52 kmatsuda Exp $	*/
 /*	$NetBSD$	*/
   
@@ -57,7 +57,7 @@
 #define	SNEC_NREGS	6
 
 /* bank memory size */
-#define	SNEC_NMEMS	(NBPG * 2)
+#define	SNEC_NMEMS	(PAGE_SIZE * 2)
 /* how many bank */
 #define	SNEC_NBANK	0x10
 /* internal buffer size */

==== //depot/projects/soc2008/snagg-audit/sys/i386/cpufreq/est.c#3 (text+ko) ====

@@ -26,7 +26,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/i386/cpufreq/est.c,v 1.16 2008/05/02 10:16:41 rpaulo Exp $");
+__FBSDID("$FreeBSD: src/sys/i386/cpufreq/est.c,v 1.17 2008/05/30 22:01:09 jhb Exp $");
 
 #include <sys/param.h>
 #include <sys/bus.h>
@@ -1078,7 +1078,8 @@
 	struct cf_setting *sets;
 	freq_info *table;
 	device_t perf_dev;
-	int count, error, i, j, maxi, maxfreq;
+	int count, error, i, j;
+	uint16_t saved_id16;
 
 	perf_dev = device_find_child(device_get_parent(dev), "acpi_perf", -1);
 	if (perf_dev == NULL || !device_is_attached(perf_dev))
@@ -1101,7 +1102,7 @@
 		error = ENOMEM;
 		goto out;
 	}
-	maxi = maxfreq = 0;
+	est_get_id16(&saved_id16);
 	for (i = 0, j = 0; i < count; i++) {
 		/*
 		 * Confirm id16 value is correct.
@@ -1118,24 +1119,11 @@
 				table[j].id16 = sets[i].spec[0];
 				table[j].power = sets[i].power;
 				++j;
-				if (sets[i].freq > maxfreq) {
-					maxi = i;
-					maxfreq = sets[i].freq;
-				}
-
 			}
-			/* restore saved setting */
-			est_set_id16(dev, sets[i].spec[0], 0);
 		}
 	}
-	/*
-	 * Set the frequency to max, so we get through boot fast, and don't
-	 * handicap systems not running powerd.
-	 */
-	if (maxfreq != 0) { 
-		device_printf(dev, "Setting %d MHz\n", sets[maxi].freq);
-		est_set_id16(dev, sets[maxi].spec[0], 0);
-	}
+	/* restore saved setting */
+	est_set_id16(dev, saved_id16, 0);
 
 	/* Mark end of table with a terminator. */
 	bzero(&table[j], sizeof(freq_info));

==== //depot/projects/soc2008/snagg-audit/sys/modules/dtrace/Makefile#3 (text+ko) ====

@@ -1,4 +1,4 @@
-# $FreeBSD: src/sys/modules/dtrace/Makefile,v 1.3 2008/05/24 19:52:19 bz Exp $
+# $FreeBSD: src/sys/modules/dtrace/Makefile,v 1.4 2008/05/31 09:37:40 jb Exp $
 
 .include <bsd.own.mk>
 .include "Makefile.inc"
@@ -6,6 +6,7 @@
 SUBDIR=		dtmalloc	\
 		dtrace		\
 		dtraceall	\
+		dtrace_test	\
 		profile		\
 		prototype	\
 		sdt		\



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