PERFORCE change 147984 for review
John Birrell
jb at FreeBSD.org
Thu Aug 21 09:21:23 UTC 2008
http://perforce.freebsd.org/chv.cgi?CH=147984
Change 147984 by jb at freebsd3 on 2008/08/21 09:20:45
IF7
Affected files ...
.. //depot/projects/dtrace7/src/share/man/man4/man4.i386/Makefile#2 integrate
.. //depot/projects/dtrace7/src/share/man/man4/man4.i386/glxsb.4#1 branch
.. //depot/projects/dtrace7/src/sys/amd64/amd64/db_disasm.c#2 integrate
.. //depot/projects/dtrace7/src/sys/compat/ndis/kern_ndis.c#2 integrate
.. //depot/projects/dtrace7/src/sys/compat/ndis/subr_ntoskrnl.c#4 integrate
.. //depot/projects/dtrace7/src/sys/conf/files.i386#6 integrate
.. //depot/projects/dtrace7/src/sys/dev/bfe/if_bfe.c#4 integrate
.. //depot/projects/dtrace7/src/sys/dev/bfe/if_bfereg.h#3 integrate
.. //depot/projects/dtrace7/src/sys/dev/cpufreq/ichss.c#3 integrate
.. //depot/projects/dtrace7/src/sys/dev/glxsb/glxsb.c#1 branch
.. //depot/projects/dtrace7/src/sys/dev/glxsb/glxsb.h#1 branch
.. //depot/projects/dtrace7/src/sys/dev/glxsb/glxsb_hash.c#1 branch
.. //depot/projects/dtrace7/src/sys/i386/conf/NOTES#5 integrate
.. //depot/projects/dtrace7/src/sys/i386/cpufreq/est.c#5 integrate
.. //depot/projects/dtrace7/src/sys/i386/cpufreq/p4tcc.c#3 integrate
.. //depot/projects/dtrace7/src/sys/i386/cpufreq/powernow.c#2 integrate
.. //depot/projects/dtrace7/src/sys/i386/cpufreq/smist.c#2 integrate
.. //depot/projects/dtrace7/src/sys/i386/i386/db_disasm.c#2 integrate
.. //depot/projects/dtrace7/src/sys/modules/Makefile#18 integrate
.. //depot/projects/dtrace7/src/sys/modules/glxsb/Makefile#1 branch
.. //depot/projects/dtrace7/src/sys/sys/param.h#11 integrate
.. //depot/projects/dtrace7/src/usr.bin/comm/comm.c#2 integrate
.. //depot/projects/dtrace7/src/usr.sbin/ndiscvt/inf.c#2 integrate
.. //depot/projects/dtrace7/src/usr.sbin/ndiscvt/ndisgen.8#2 integrate
Differences ...
==== //depot/projects/dtrace7/src/share/man/man4/man4.i386/Makefile#2 (text+ko) ====
@@ -1,4 +1,4 @@
-# $FreeBSD: src/share/man/man4/man4.i386/Makefile,v 1.185 2007/03/30 21:19:10 takawata Exp $
+# $FreeBSD: src/share/man/man4/man4.i386/Makefile,v 1.185.2.1 2008/08/20 14:16:07 philip Exp $
MAN= acpi_aiboost.4 \
acpi_asus.4 \
@@ -23,6 +23,7 @@
ep.4 \
ex.4 \
fe.4 \
+ glxsb.4 \
ichwd.4 \
ie.4 \
io.4 \
==== //depot/projects/dtrace7/src/sys/amd64/amd64/db_disasm.c#2 (text+ko) ====
@@ -25,7 +25,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/amd64/amd64/db_disasm.c,v 1.31 2006/11/13 21:14:54 jhb Exp $");
+__FBSDID("$FreeBSD: src/sys/amd64/amd64/db_disasm.c,v 1.31.2.1 2008/08/20 17:44:02 jhb Exp $");
/*
* Instruction disassembler.
@@ -164,15 +164,37 @@
""
};
+static const char * const db_Grp15[] = {
+ "fxsave",
+ "fxrstor",
+ "ldmxcsr",
+ "stmxcsr",
+ "",
+ "",
+ "",
+ "clflush"
+};
+
+static const char * const db_Grp15b[] = {
+ "",
+ "",
+ "",
+ "",
+ "",
+ "lfence",
+ "mfence",
+ "sfence"
+};
+
static const struct inst db_inst_0f0x[] = {
/*00*/ { "", TRUE, NONE, op1(Ew), db_Grp6 },
/*01*/ { "", TRUE, NONE, op1(Ew), db_Grp7 },
/*02*/ { "lar", TRUE, LONG, op2(E,R), 0 },
/*03*/ { "lsl", TRUE, LONG, op2(E,R), 0 },
/*04*/ { "", FALSE, NONE, 0, 0 },
-/*05*/ { "", FALSE, NONE, 0, 0 },
+/*05*/ { "syscall",FALSE,NONE, 0, 0 },
/*06*/ { "clts", FALSE, NONE, 0, 0 },
-/*07*/ { "", FALSE, NONE, 0, 0 },
+/*07*/ { "sysret",FALSE, NONE, 0, 0 },
/*08*/ { "invd", FALSE, NONE, 0, 0 },
/*09*/ { "wbinvd",FALSE, NONE, 0, 0 },
@@ -209,10 +231,10 @@
/*31*/ { "rdtsc", FALSE, NONE, 0, 0 },
/*32*/ { "rdmsr", FALSE, NONE, 0, 0 },
/*33*/ { "rdpmc", FALSE, NONE, 0, 0 },
-/*34*/ { "", FALSE, NONE, 0, 0 },
-/*35*/ { "", FALSE, NONE, 0, 0 },
+/*34*/ { "sysenter",FALSE,NONE, 0, 0 },
+/*35*/ { "sysexit",FALSE,NONE, 0, 0 },
/*36*/ { "", FALSE, NONE, 0, 0 },
-/*37*/ { "", FALSE, NONE, 0, 0 },
+/*37*/ { "getsec",FALSE, NONE, 0, 0 },
/*38*/ { "", FALSE, NONE, 0, 0 },
/*39*/ { "", FALSE, NONE, 0, 0 },
@@ -300,8 +322,8 @@
/*ab*/ { "bts", TRUE, LONG, op2(R,E), 0 },
/*ac*/ { "shrd", TRUE, LONG, op3(Ib,R,E), 0 },
/*ad*/ { "shrd", TRUE, LONG, op3(CL,R,E), 0 },
-/*a6*/ { "", FALSE, NONE, 0, 0 },
-/*a7*/ { "imul", TRUE, LONG, op2(E,R), 0 },
+/*ae*/ { "", TRUE, LONG, op1(E), db_Grp15 },
+/*af*/ { "imul", TRUE, LONG, op2(E,R), 0 },
};
static const struct inst db_inst_0fbx[] = {
@@ -1123,6 +1145,7 @@
boolean_t first;
int displ;
int prefix;
+ int rep;
int imm;
int imm2;
long imm64;
@@ -1137,6 +1160,7 @@
/*
* Get prefixes
*/
+ rep = FALSE;
prefix = TRUE;
do {
switch (inst) {
@@ -1171,7 +1195,7 @@
db_printf("repne ");
break;
case 0xf3:
- db_printf("repe "); /* XXX repe VS rep */
+ rep = TRUE;
break;
default:
prefix = FALSE;
@@ -1184,6 +1208,14 @@
if (prefix) {
get_value_inc(inst, loc, 1, FALSE);
}
+ if (rep == TRUE) {
+ if (inst == 0x90) {
+ db_printf("pause\n");
+ return (loc);
+ }
+ db_printf("repe "); /* XXX repe VS rep */
+ rep = FALSE;
+ }
} while (prefix);
if (inst >= 0xd8 && inst <= 0xdf) {
@@ -1216,7 +1248,8 @@
if (ip->i_extra == db_Grp1 || ip->i_extra == db_Grp2 ||
ip->i_extra == db_Grp6 || ip->i_extra == db_Grp7 ||
- ip->i_extra == db_Grp8 || ip->i_extra == db_Grp9) {
+ ip->i_extra == db_Grp8 || ip->i_extra == db_Grp9 ||
+ ip->i_extra == db_Grp15) {
i_name = ((const char * const *)ip->i_extra)[f_reg(rex, regmodrm)];
}
else if (ip->i_extra == db_Grp3) {
@@ -1233,6 +1266,32 @@
i_size = ip->i_size;
}
+ /* Special cases that don't fit well in the tables. */
+ if (ip->i_extra == db_Grp7 && f_mod(rex, regmodrm) == 3) {
+ switch (regmodrm) {
+ case 0xc8:
+ i_name = "monitor";
+ i_size = NONE;
+ i_mode = 0;
+ break;
+ case 0xc9:
+ i_name = "mwait";
+ i_size = NONE;
+ i_mode = 0;
+ break;
+ case 0xf8:
+ i_name = "swapgs";
+ i_size = NONE;
+ i_mode = 0;
+ break;
+ }
+ }
+ if (ip->i_extra == db_Grp15 && f_mod(rex, regmodrm) == 3) {
+ i_name = db_Grp15b[f_reg(rex, regmodrm)];
+ i_size = NONE;
+ i_mode = 0;
+ }
+
if (i_size == SDEP) {
if (size == WORD)
db_printf("%s", i_name);
==== //depot/projects/dtrace7/src/sys/compat/ndis/kern_ndis.c#2 (text+ko) ====
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/compat/ndis/kern_ndis.c,v 1.96 2007/06/10 04:40:13 mjacob Exp $");
+__FBSDID("$FreeBSD: src/sys/compat/ndis/kern_ndis.c,v 1.96.2.1 2008/08/21 05:40:38 weongyo Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -876,6 +876,8 @@
sc = arg;
+ KeResetEvent(&sc->ndis_block->nmb_setevent);
+
KeAcquireSpinLock(&sc->ndis_block->nmb_lock, &irql);
if (sc->ndis_block->nmb_pendingreq != NULL) {
@@ -904,7 +906,6 @@
if (rval == NDIS_STATUS_PENDING) {
/* Wait up to 5 seconds. */
duetime = (5 * 1000000) * -10;
- KeResetEvent(&sc->ndis_block->nmb_setevent);
KeWaitForSingleObject(&sc->ndis_block->nmb_setevent,
0, 0, FALSE, &duetime);
rval = sc->ndis_block->nmb_setstat;
@@ -1097,6 +1098,8 @@
NDIS_UNLOCK(sc);
+ KeResetEvent(&sc->ndis_block->nmb_resetevent);
+
if (NDIS_SERIALIZED(sc->ndis_block))
KeAcquireSpinLock(&sc->ndis_block->nmb_lock, &irql);
@@ -1105,11 +1108,9 @@
if (NDIS_SERIALIZED(sc->ndis_block))
KeReleaseSpinLock(&sc->ndis_block->nmb_lock, irql);
- if (rval == NDIS_STATUS_PENDING) {
- KeResetEvent(&sc->ndis_block->nmb_resetevent);
+ if (rval == NDIS_STATUS_PENDING)
KeWaitForSingleObject(&sc->ndis_block->nmb_resetevent,
0, 0, FALSE, NULL);
- }
return(0);
}
@@ -1298,6 +1299,8 @@
sc = arg;
+ KeResetEvent(&sc->ndis_block->nmb_getevent);
+
KeAcquireSpinLock(&sc->ndis_block->nmb_lock, &irql);
if (sc->ndis_block->nmb_pendingreq != NULL) {
@@ -1328,7 +1331,6 @@
if (rval == NDIS_STATUS_PENDING) {
/* Wait up to 5 seconds. */
duetime = (5 * 1000000) * -10;
- KeResetEvent(&sc->ndis_block->nmb_getevent);
KeWaitForSingleObject(&sc->ndis_block->nmb_getevent,
0, 0, FALSE, &duetime);
rval = sc->ndis_block->nmb_getstat;
==== //depot/projects/dtrace7/src/sys/compat/ndis/subr_ntoskrnl.c#4 (text+ko) ====
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/compat/ndis/subr_ntoskrnl.c,v 1.90.2.2 2008/07/16 16:28:12 cokane Exp $");
+__FBSDID("$FreeBSD: src/sys/compat/ndis/subr_ntoskrnl.c,v 1.90.2.3 2008/08/21 05:13:55 weongyo Exp $");
#include <sys/ctype.h>
#include <sys/unistd.h>
@@ -1567,8 +1567,9 @@
}
if (satisfied == TRUE)
- cv_broadcastpri(&we->we_cv, w->wb_oldpri -
- (increment * 4));
+ cv_broadcastpri(&we->we_cv,
+ (w->wb_oldpri - (increment * 4)) > PRI_MIN_KERN ?
+ w->wb_oldpri - (increment * 4) : PRI_MIN_KERN);
e = e->nle_flink;
}
@@ -3350,8 +3351,9 @@
}
} else {
w->wb_awakened |= TRUE;
- cv_broadcastpri(&we->we_cv, w->wb_oldpri -
- (increment * 4));
+ cv_broadcastpri(&we->we_cv,
+ (w->wb_oldpri - (increment * 4)) > PRI_MIN_KERN ?
+ w->wb_oldpri - (increment * 4) : PRI_MIN_KERN);
}
}
==== //depot/projects/dtrace7/src/sys/conf/files.i386#6 (text+ko) ====
@@ -1,7 +1,7 @@
# This file tells config what files go into building a kernel,
# files marked standard are always included.
#
-# $FreeBSD: src/sys/conf/files.i386,v 1.580.2.6 2008/04/10 22:09:22 rwatson Exp $
+# $FreeBSD: src/sys/conf/files.i386,v 1.580.2.7 2008/08/20 11:33:13 philip Exp $
#
# The long compile-with and dependency lines are required because of
# limitations in config: backslash-newline doesn't work in strings, and
@@ -179,6 +179,8 @@
dev/fdc/fdc_isa.c optional fdc isa
dev/fdc/fdc_pccard.c optional fdc pccard
dev/fe/if_fe_isa.c optional fe isa
+dev/glxsb/glxsb.c optional glxsb
+dev/glxsb/glxsb_hash.c optional glxsb
dev/hptmv/entry.c optional hptmv
dev/hptmv/mv.c optional hptmv
dev/hptmv/gui_lib.c optional hptmv
==== //depot/projects/dtrace7/src/sys/dev/bfe/if_bfe.c#4 (text+ko) ====
@@ -26,7 +26,7 @@
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/bfe/if_bfe.c,v 1.42.2.3 2008/05/07 01:32:29 yongari Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/bfe/if_bfe.c,v 1.42.2.7 2008/08/21 03:45:50 yongari Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -171,19 +171,13 @@
bfe_probe(device_t dev)
{
struct bfe_type *t;
- struct bfe_softc *sc;
t = bfe_devs;
- sc = device_get_softc(dev);
- bzero(sc, sizeof(struct bfe_softc));
- sc->bfe_unit = device_get_unit(dev);
- sc->bfe_dev = dev;
-
- while(t->bfe_name != NULL) {
- if ((pci_get_vendor(dev) == t->bfe_vid) &&
- (pci_get_device(dev) == t->bfe_did)) {
- device_set_desc_copy(dev, t->bfe_name);
+ while (t->bfe_name != NULL) {
+ if (pci_get_vendor(dev) == t->bfe_vid &&
+ pci_get_device(dev) == t->bfe_did) {
+ device_set_desc(dev, t->bfe_name);
return (BUS_PROBE_DEFAULT);
}
t++;
@@ -294,7 +288,7 @@
error = bus_dmamem_alloc(sc->bfe_rx_tag, (void *)&sc->bfe_rx_list,
BUS_DMA_NOWAIT, &sc->bfe_rx_map);
- if(error)
+ if (error)
return (ENOMEM);
bzero(sc->bfe_rx_list, BFE_RX_LIST_SIZE);
@@ -302,7 +296,7 @@
sc->bfe_rx_list, sizeof(struct bfe_desc),
bfe_dma_map, &sc->bfe_rx_dma, BUS_DMA_NOWAIT);
- if(error)
+ if (error)
return (ENOMEM);
bus_dmamap_sync(sc->bfe_rx_tag, sc->bfe_rx_map, BUS_DMASYNC_PREWRITE);
@@ -316,7 +310,7 @@
error = bus_dmamap_load(sc->bfe_tx_tag, sc->bfe_tx_map,
sc->bfe_tx_list, sizeof(struct bfe_desc),
bfe_dma_map, &sc->bfe_tx_dma, BUS_DMA_NOWAIT);
- if(error)
+ if (error)
return (ENOMEM);
bzero(sc->bfe_tx_list, BFE_TX_LIST_SIZE);
@@ -330,16 +324,14 @@
{
struct ifnet *ifp = NULL;
struct bfe_softc *sc;
- int unit, error = 0, rid;
+ int error = 0, rid;
sc = device_get_softc(dev);
mtx_init(&sc->bfe_mtx, device_get_nameunit(dev), MTX_NETWORK_LOCK,
MTX_DEF);
callout_init_mtx(&sc->bfe_stat_co, &sc->bfe_mtx, 0);
- unit = device_get_unit(dev);
sc->bfe_dev = dev;
- sc->bfe_unit = unit;
/*
* Map control/status registers.
@@ -350,7 +342,7 @@
sc->bfe_res = bus_alloc_resource_any(dev, SYS_RES_MEMORY, &rid,
RF_ACTIVE);
if (sc->bfe_res == NULL) {
- printf ("bfe%d: couldn't map memory\n", unit);
+ device_printf(dev, "couldn't map memory\n");
error = ENXIO;
goto fail;
}
@@ -365,14 +357,13 @@
sc->bfe_irq = bus_alloc_resource_any(dev, SYS_RES_IRQ, &rid,
RF_SHAREABLE | RF_ACTIVE);
if (sc->bfe_irq == NULL) {
- printf("bfe%d: couldn't map interrupt\n", unit);
+ device_printf(dev, "couldn't map interrupt\n");
error = ENXIO;
goto fail;
}
if (bfe_dma_alloc(dev)) {
- printf("bfe%d: failed to allocate DMA resources\n",
- sc->bfe_unit);
+ device_printf(dev, "failed to allocate DMA resources\n");
error = ENXIO;
goto fail;
}
@@ -380,7 +371,7 @@
/* Set up ifnet structure */
ifp = sc->bfe_ifp = if_alloc(IFT_ETHER);
if (ifp == NULL) {
- printf("bfe%d: failed to if_alloc()\n", sc->bfe_unit);
+ device_printf(dev, "failed to if_alloc()\n");
error = ENOSPC;
goto fail;
}
@@ -404,7 +395,7 @@
if (mii_phy_probe(dev, &sc->bfe_miibus,
bfe_ifmedia_upd, bfe_ifmedia_sts)) {
- printf("bfe%d: MII without any PHY!\n", sc->bfe_unit);
+ device_printf(dev, "MII without any PHY!\n");
error = ENXIO;
goto fail;
}
@@ -425,7 +416,7 @@
NULL, bfe_intr, sc, &sc->bfe_intrhand);
if (error) {
- printf("bfe%d: couldn't set up irq\n", unit);
+ device_printf(dev, "couldn't set up irq\n");
goto fail;
}
fail:
@@ -458,7 +449,7 @@
bfe_chip_reset(sc);
bus_generic_detach(dev);
- if(sc->bfe_miibus != NULL)
+ if (sc->bfe_miibus != NULL)
device_delete_child(dev, sc->bfe_miibus);
bfe_release_resources(sc);
@@ -526,7 +517,7 @@
u_int32_t ret;
sc = device_get_softc(dev);
- if(phy != sc->bfe_phyaddr)
+ if (phy != sc->bfe_phyaddr)
return (0);
bfe_readphy(sc, reg, &ret);
@@ -539,7 +530,7 @@
struct bfe_softc *sc;
sc = device_get_softc(dev);
- if(phy != sc->bfe_phyaddr)
+ if (phy != sc->bfe_phyaddr)
return (0);
bfe_writephy(sc, reg, val);
@@ -593,7 +584,7 @@
int i;
for(i = 0; i < BFE_TX_LIST_CNT; i++) {
- if(sc->bfe_tx_ring[i].bfe_mbuf != NULL) {
+ if (sc->bfe_tx_ring[i].bfe_mbuf != NULL) {
m_freem(sc->bfe_tx_ring[i].bfe_mbuf);
sc->bfe_tx_ring[i].bfe_mbuf = NULL;
bus_dmamap_unload(sc->bfe_tag,
@@ -627,7 +618,7 @@
int i;
for(i = 0; i < BFE_RX_LIST_CNT; i++) {
- if(bfe_list_newbuf(sc, i, NULL) == ENOBUFS)
+ if (bfe_list_newbuf(sc, i, NULL) == ENOBUFS)
return (ENOBUFS);
}
@@ -652,9 +643,9 @@
return (EINVAL);
allocated = 0;
- if(m == NULL) {
+ if (m == NULL) {
m = m_getcl(M_DONTWAIT, MT_DATA, M_PKTHDR);
- if(m == NULL)
+ if (m == NULL)
return (ENOBUFS);
m->m_len = m->m_pkthdr.len = MCLBYTES;
allocated++;
@@ -676,15 +667,15 @@
if (allocated != 0)
m_free(m);
if (error != ENOMEM)
- printf("bfe%d: failed to map RX buffer, error %d\n",
- sc->bfe_unit, error);
+ device_printf(sc->bfe_dev,
+ "failed to map RX buffer, error %d\n", error);
return (ENOBUFS);
}
bus_dmamap_sync(sc->bfe_tag, r->bfe_map, BUS_DMASYNC_PREWRITE);
ctrl = ETHER_MAX_LEN + 32;
- if(c == BFE_RX_LIST_CNT - 1)
+ if (c == BFE_RX_LIST_CNT - 1)
ctrl |= BFE_DESC_EOT;
d->bfe_ctrl = ctrl;
@@ -757,7 +748,7 @@
DELAY(100);
bfe_readphy(sc, 0, &val);
if (val & BMCR_RESET) {
- printf("bfe%d: PHY Reset would not complete.\n", sc->bfe_unit);
+ device_printf(sc->bfe_dev, "PHY Reset would not complete.\n");
return (ENXIO);
}
return (0);
@@ -820,9 +811,9 @@
/* Internal or external PHY? */
val = CSR_READ_4(sc, BFE_DEVCTRL);
- if(!(val & BFE_IPP))
+ if (!(val & BFE_IPP))
CSR_WRITE_4(sc, BFE_ENET_CTRL, BFE_ENET_EPSEL);
- else if(CSR_READ_4(sc, BFE_DEVCTRL) & BFE_EPR) {
+ else if (CSR_READ_4(sc, BFE_DEVCTRL) & BFE_EPR) {
BFE_AND(sc, BFE_DEVCTRL, ~BFE_EPR);
DELAY(100);
}
@@ -867,7 +858,7 @@
static void
bfe_core_disable(struct bfe_softc *sc)
{
- if((CSR_READ_4(sc, BFE_SBTMSLOW)) & BFE_RESET)
+ if ((CSR_READ_4(sc, BFE_SBTMSLOW)) & BFE_RESET)
return;
/*
@@ -1023,7 +1014,7 @@
if (sc->bfe_ifp != NULL)
if_free(sc->bfe_ifp);
- if(sc->bfe_tx_tag != NULL) {
+ if (sc->bfe_tx_tag != NULL) {
bus_dmamap_unload(sc->bfe_tx_tag, sc->bfe_tx_map);
bus_dmamem_free(sc->bfe_tx_tag, sc->bfe_tx_list,
sc->bfe_tx_map);
@@ -1031,7 +1022,7 @@
sc->bfe_tx_tag = NULL;
}
- if(sc->bfe_rx_tag != NULL) {
+ if (sc->bfe_rx_tag != NULL) {
bus_dmamap_unload(sc->bfe_rx_tag, sc->bfe_rx_map);
bus_dmamem_free(sc->bfe_rx_tag, sc->bfe_rx_list,
sc->bfe_rx_map);
@@ -1039,7 +1030,7 @@
sc->bfe_rx_tag = NULL;
}
- if(sc->bfe_tag != NULL) {
+ if (sc->bfe_tag != NULL) {
for(i = 0; i < BFE_TX_LIST_CNT; i++) {
bus_dmamap_destroy(sc->bfe_tag,
sc->bfe_tx_ring[i].bfe_map);
@@ -1052,7 +1043,7 @@
sc->bfe_tag = NULL;
}
- if(sc->bfe_parent_tag != NULL)
+ if (sc->bfe_parent_tag != NULL)
bus_dma_tag_destroy(sc->bfe_parent_tag);
return;
@@ -1084,9 +1075,9 @@
DELAY(10);
}
if (i == timeout) {
- printf("bfe%d: BUG! Timeout waiting for bit %08x of register "
- "%x to %s.\n", sc->bfe_unit, bit, reg,
- (clear ? "clear" : "set"));
+ device_printf(sc->bfe_dev,
+ "BUG! Timeout waiting for bit %08x of register "
+ "%x to %s.\n", bit, reg, (clear ? "clear" : "set"));
return (-1);
}
return (0);
@@ -1179,9 +1170,9 @@
i = sc->bfe_tx_cons;
/* Go through the mbufs and free those that have been transmitted */
- while(i != chipidx) {
+ while (i != chipidx) {
struct bfe_data *r = &sc->bfe_tx_ring[i];
- if(r->bfe_mbuf != NULL) {
+ if (r->bfe_mbuf != NULL) {
ifp->if_opackets++;
m_freem(r->bfe_mbuf);
r->bfe_mbuf = NULL;
@@ -1191,7 +1182,7 @@
BFE_INC(i, BFE_TX_LIST_CNT);
}
- if(i != sc->bfe_tx_cons) {
+ if (i != sc->bfe_tx_cons) {
/* we freed up some mbufs */
sc->bfe_tx_cons = i;
ifp->if_drv_flags &= ~IFF_DRV_OACTIVE;
@@ -1219,7 +1210,7 @@
ifp = sc->bfe_ifp;
- while(current != cons) {
+ while (current != cons) {
r = &sc->bfe_rx_ring[cons];
m = r->bfe_mbuf;
rxheader = mtod(m, struct bfe_rxheader*);
@@ -1288,33 +1279,34 @@
CSR_READ_4(sc, BFE_ISTAT);
/* not expecting this interrupt, disregard it */
- if(istat == 0) {
+ if (istat == 0) {
BFE_UNLOCK(sc);
return;
}
- if(istat & BFE_ISTAT_ERRORS) {
+ if (istat & BFE_ISTAT_ERRORS) {
if (istat & BFE_ISTAT_DSCE) {
- printf("if_bfe Descriptor Error\n");
+ device_printf(sc->bfe_dev, "Descriptor Error\n");
bfe_stop(sc);
BFE_UNLOCK(sc);
return;
}
if (istat & BFE_ISTAT_DPE) {
- printf("if_bfe Descriptor Protocol Error\n");
+ device_printf(sc->bfe_dev,
+ "Descriptor Protocol Error\n");
bfe_stop(sc);
BFE_UNLOCK(sc);
return;
}
flag = CSR_READ_4(sc, BFE_DMATX_STAT);
- if(flag & BFE_STAT_EMASK)
+ if (flag & BFE_STAT_EMASK)
ifp->if_oerrors++;
flag = CSR_READ_4(sc, BFE_DMARX_STAT);
- if(flag & BFE_RX_FLAG_ERRORS)
+ if (flag & BFE_RX_FLAG_ERRORS)
ifp->if_ierrors++;
ifp->if_drv_flags &= ~IFF_DRV_RUNNING;
@@ -1322,11 +1314,11 @@
}
/* A packet was received */
- if(istat & BFE_ISTAT_RX)
+ if (istat & BFE_ISTAT_RX)
bfe_rxeof(sc);
/* A packet was sent */
- if(istat & BFE_ISTAT_TX)
+ if (istat & BFE_ISTAT_TX)
bfe_txeof(sc);
/* We have packets pending, fire them out */
@@ -1347,7 +1339,7 @@
int chainlen = 0;
int error;
- if(BFE_TX_LIST_CNT - sc->bfe_tx_cnt < 2)
+ if (BFE_TX_LIST_CNT - sc->bfe_tx_cnt < 2)
return (ENOBUFS);
/*
@@ -1377,8 +1369,8 @@
cnt = 0;
for(m = *m_head; m != NULL; m = m->m_next) {
- if(m->m_len != 0) {
- if((BFE_TX_LIST_CNT - (sc->bfe_tx_cnt + cnt)) < 2)
+ if (m->m_len != 0) {
+ if ((BFE_TX_LIST_CNT - (sc->bfe_tx_cnt + cnt)) < 2)
return (ENOBUFS);
d = &sc->bfe_tx_list[cur];
@@ -1386,10 +1378,10 @@
d->bfe_ctrl = BFE_DESC_LEN & m->m_len;
/* always intterupt on completion */
d->bfe_ctrl |= BFE_DESC_IOC;
- if(cnt == 0)
+ if (cnt == 0)
/* Set start of frame */
d->bfe_ctrl |= BFE_DESC_SOF;
- if(cur == BFE_TX_LIST_CNT - 1)
+ if (cur == BFE_TX_LIST_CNT - 1)
/*
* Tell the chip to wrap to the start of
* the descriptor list
@@ -1459,16 +1451,16 @@
IFF_DRV_RUNNING)
return;
- while(sc->bfe_tx_ring[idx].bfe_mbuf == NULL) {
+ while (sc->bfe_tx_ring[idx].bfe_mbuf == NULL) {
IFQ_DRV_DEQUEUE(&ifp->if_snd, m_head);
- if(m_head == NULL)
+ if (m_head == NULL)
break;
/*
* Pack the data into the tx ring. If we dont have
* enough room, let the chip drain the ring.
*/
- if(bfe_encap(sc, &m_head, &idx)) {
+ if (bfe_encap(sc, &m_head, &idx)) {
IFQ_DRV_PREPEND(&ifp->if_snd, m_head);
ifp->if_drv_flags |= IFF_DRV_OACTIVE;
break;
@@ -1522,8 +1514,8 @@
bfe_chip_reset(sc);
if (bfe_list_rx_init(sc) == ENOBUFS) {
- printf("bfe%d: bfe_init: Not enough memory for list buffers\n",
- sc->bfe_unit);
+ device_printf(sc->bfe_dev,
+ "%s: Not enough memory for list buffers\n", __func__);
bfe_stop(sc);
return;
}
@@ -1596,34 +1588,33 @@
struct mii_data *mii;
int error = 0;
- switch(command) {
- case SIOCSIFFLAGS:
- BFE_LOCK(sc);
- if(ifp->if_flags & IFF_UP)
- if(ifp->if_drv_flags & IFF_DRV_RUNNING)
- bfe_set_rx_mode(sc);
- else
- bfe_init_locked(sc);
- else if(ifp->if_drv_flags & IFF_DRV_RUNNING)
- bfe_stop(sc);
- BFE_UNLOCK(sc);
- break;
- case SIOCADDMULTI:
- case SIOCDELMULTI:
- BFE_LOCK(sc);
- if(ifp->if_drv_flags & IFF_DRV_RUNNING)
+ switch (command) {
+ case SIOCSIFFLAGS:
+ BFE_LOCK(sc);
+ if (ifp->if_flags & IFF_UP)
+ if (ifp->if_drv_flags & IFF_DRV_RUNNING)
bfe_set_rx_mode(sc);
- BFE_UNLOCK(sc);
- break;
- case SIOCGIFMEDIA:
- case SIOCSIFMEDIA:
- mii = device_get_softc(sc->bfe_miibus);
- error = ifmedia_ioctl(ifp, ifr, &mii->mii_media,
- command);
- break;
- default:
- error = ether_ioctl(ifp, command, data);
- break;
+ else
+ bfe_init_locked(sc);
+ else if (ifp->if_drv_flags & IFF_DRV_RUNNING)
+ bfe_stop(sc);
+ BFE_UNLOCK(sc);
+ break;
+ case SIOCADDMULTI:
+ case SIOCDELMULTI:
+ BFE_LOCK(sc);
+ if (ifp->if_drv_flags & IFF_DRV_RUNNING)
+ bfe_set_rx_mode(sc);
+ BFE_UNLOCK(sc);
+ break;
+ case SIOCGIFMEDIA:
+ case SIOCSIFMEDIA:
+ mii = device_get_softc(sc->bfe_miibus);
+ error = ifmedia_ioctl(ifp, ifr, &mii->mii_media, command);
+ break;
+ default:
+ error = ether_ioctl(ifp, command, data);
+ break;
}
return (error);
@@ -1641,7 +1632,7 @@
ifp = sc->bfe_ifp;
- printf("bfe%d: watchdog timeout -- resetting\n", sc->bfe_unit);
+ device_printf(sc->bfe_dev, "watchdog timeout -- resetting\n");
ifp->if_oerrors++;
ifp->if_drv_flags &= ~IFF_DRV_RUNNING;
==== //depot/projects/dtrace7/src/sys/dev/bfe/if_bfereg.h#3 (text+ko) ====
@@ -22,7 +22,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*/
-/* $FreeBSD: src/sys/dev/bfe/if_bfereg.h,v 1.10.2.1 2008/03/18 02:11:40 yongari Exp $ */
+/* $FreeBSD: src/sys/dev/bfe/if_bfereg.h,v 1.10.2.2 2008/08/21 02:03:01 yongari Exp $ */
#ifndef _BFE_H
#define _BFE_H
@@ -524,7 +524,6 @@
int bfe_watchdog_timer;
u_int8_t bfe_phyaddr; /* Address of the card's PHY */
u_int8_t bfe_mdc_port;
- u_int8_t bfe_unit; /* interface number */
u_int8_t bfe_core_unit;
u_int8_t bfe_up;
u_char bfe_enaddr[6];
==== //depot/projects/dtrace7/src/sys/dev/cpufreq/ichss.c#3 (text+ko) ====
@@ -25,7 +25,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/cpufreq/ichss.c,v 1.10.2.1 2008/06/27 03:49:22 jhb Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/cpufreq/ichss.c,v 1.10.2.2 2008/08/20 18:33:09 jhb Exp $");
#include <sys/param.h>
#include <sys/bus.h>
@@ -181,7 +181,7 @@
}
DPRINT("ichss: PMBASE is %#x\n", pmbase);
- child = BUS_ADD_CHILD(parent, 0, "ichss", 0);
+ child = BUS_ADD_CHILD(parent, 20, "ichss", 0);
if (child == NULL) {
device_printf(parent, "add SpeedStep child failed\n");
return;
==== //depot/projects/dtrace7/src/sys/i386/conf/NOTES#5 (text+ko) ====
@@ -4,7 +4,7 @@
# This file contains machine dependent kernel configuration notes. For
# machine independent notes, look in /sys/conf/NOTES.
#
-# $FreeBSD: src/sys/i386/conf/NOTES,v 1.1244.2.4 2008/02/03 07:28:37 scottl Exp $
+# $FreeBSD: src/sys/i386/conf/NOTES,v 1.1244.2.5 2008/08/20 11:33:13 philip Exp $
#
#
@@ -753,6 +753,12 @@
options SAFE_DEBUG # enable debugging support: hw.safe.debug
options SAFE_RNDTEST # enable rndtest support
+#
+# glxsb is a driver for the Security Block in AMD Geode LX processors.
+# Requires 'device crypto'.
+#
+device glxsb # AMD Geode LX Security Block
+
#####################################################################
#
==== //depot/projects/dtrace7/src/sys/i386/cpufreq/est.c#5 (text+ko) ====
@@ -26,7 +26,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/i386/cpufreq/est.c,v 1.11.2.5 2008/06/27 00:48:23 jhb Exp $");
+__FBSDID("$FreeBSD: src/sys/i386/cpufreq/est.c,v 1.11.2.6 2008/08/20 18:33:09 jhb Exp $");
#include <sys/param.h>
#include <sys/bus.h>
@@ -967,7 +967,7 @@
* We add a child for each CPU since settings must be performed
* on each CPU in the SMP case.
*/
- child = BUS_ADD_CHILD(parent, 0, "est", -1);
+ child = BUS_ADD_CHILD(parent, 10, "est", -1);
if (child == NULL)
device_printf(parent, "add est child failed\n");
}
==== //depot/projects/dtrace7/src/sys/i386/cpufreq/p4tcc.c#3 (text+ko) ====
@@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/i386/cpufreq/p4tcc.c,v 1.12.2.1 2008/04/08 09:38:15 phk Exp $");
+__FBSDID("$FreeBSD: src/sys/i386/cpufreq/p4tcc.c,v 1.12.2.2 2008/08/20 18:33:09 jhb Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -131,7 +131,7 @@
* of the IA32 Intel Architecture Software Developer's Manual,
* Volume 3, for more info.
*/
- if (BUS_ADD_CHILD(parent, 0, "p4tcc", -1) == NULL)
+ if (BUS_ADD_CHILD(parent, 10, "p4tcc", -1) == NULL)
device_printf(parent, "add p4tcc child failed\n");
}
==== //depot/projects/dtrace7/src/sys/i386/cpufreq/powernow.c#2 (text+ko) ====
@@ -29,7 +29,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/i386/cpufreq/powernow.c,v 1.4 2007/01/23 19:20:30 bruno Exp $");
+__FBSDID("$FreeBSD: src/sys/i386/cpufreq/powernow.c,v 1.4.2.1 2008/08/20 18:33:09 jhb Exp $");
#include <sys/param.h>
#include <sys/bus.h>
@@ -894,7 +894,7 @@
}
if (device_find_child(parent, "powernow", -1) != NULL)
return;
- if ((child = BUS_ADD_CHILD(parent, 0, "powernow", -1)) == NULL)
+ if ((child = BUS_ADD_CHILD(parent, 10, "powernow", -1)) == NULL)
device_printf(parent, "powernow: add child failed\n");
}
==== //depot/projects/dtrace7/src/sys/i386/cpufreq/smist.c#2 (text+ko) ====
@@ -36,7 +36,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/i386/cpufreq/smist.c,v 1.2 2007/06/17 07:18:23 njl Exp $");
+__FBSDID("$FreeBSD: src/sys/i386/cpufreq/smist.c,v 1.2.2.1 2008/08/20 18:33:09 jhb Exp $");
#include <sys/param.h>
#include <sys/bus.h>
@@ -308,7 +308,7 @@
if (device_find_child(parent, "smist", -1) != NULL)
return;
- if (BUS_ADD_CHILD(parent, 0, "smist", -1) == NULL)
+ if (BUS_ADD_CHILD(parent, 30, "smist", -1) == NULL)
device_printf(parent, "smist: add child failed\n");
}
==== //depot/projects/dtrace7/src/sys/i386/i386/db_disasm.c#2 (text+ko) ====
@@ -25,7 +25,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/i386/i386/db_disasm.c,v 1.29 2005/01/05 19:09:59 imp Exp $");
>>> TRUNCATED FOR MAIL (1000 lines) <<<
More information about the p4-projects
mailing list