Index: build/jam/HaikuImage
===================================================================
--- build/jam/HaikuImage	(revision 28637)
+++ build/jam/HaikuImage	(working copy)
@@ -143,6 +143,7 @@
 	#vlance
 	$(X86_ONLY)marvell_yukon $(X86_ONLY)syskonnect usb_ecm
 	$(GPL_ONLY)bcm570x
+	broadcom570x
 ;
 #BEOS_ADD_ONS_DRIVERS_ACPI = $(X86_ONLY)acpi_button ;
 BEOS_ADD_ONS_BUS_MANAGERS = pci $(X86_ONLY)ps2 $(X86_ONLY)isa ide scsi
Index: src/add-ons/kernel/drivers/network/broadcom570x/dev/bge/if_bgereg.h
===================================================================
--- src/add-ons/kernel/drivers/network/broadcom570x/dev/bge/if_bgereg.h	(revision 28637)
+++ src/add-ons/kernel/drivers/network/broadcom570x/dev/bge/if_bgereg.h	(working copy)
@@ -2586,3 +2586,7 @@
 #define	BGE_LOCK_ASSERT(_sc)	mtx_assert(&(_sc)->bge_mtx, MA_OWNED)
 #define	BGE_UNLOCK(_sc)		mtx_unlock(&(_sc)->bge_mtx)
 #define	BGE_LOCK_DESTROY(_sc)	mtx_destroy(&(_sc)->bge_mtx)
+
+// these functions declarations are placed here because they are used in glue.c
+void bge_writembx(struct bge_softc *, int, int);
+void bge_link_upd(struct bge_softc *);
Index: src/add-ons/kernel/drivers/network/broadcom570x/dev/bge/if_bge.c
===================================================================
--- src/add-ons/kernel/drivers/network/broadcom570x/dev/bge/if_bge.c	(revision 28637)
+++ src/add-ons/kernel/drivers/network/broadcom570x/dev/bge/if_bge.c	(working copy)
@@ -378,7 +378,6 @@
 static int bge_has_eaddr(struct bge_softc *);
 static uint32_t bge_readmem_ind(struct bge_softc *, int);
 static void bge_writemem_ind(struct bge_softc *, int, int);
-static void bge_writembx(struct bge_softc *, int, int);
 #ifdef notdef
 static uint32_t bge_readreg_ind(struct bge_softc *, int);
 #endif
@@ -398,7 +397,6 @@
 static void bge_sig_legacy(struct bge_softc *, int);
 static void bge_sig_pre_reset(struct bge_softc *, int);
 static int bge_reset(struct bge_softc *);
-static void bge_link_upd(struct bge_softc *);
 
 /*
  * The BGE_REGISTER_DEBUG option is only for low-level debugging.  It may
@@ -553,7 +551,7 @@
 	CSR_WRITE_4(sc, off, val);
 }
 
-static void
+void
 bge_writembx(struct bge_softc *sc, int off, int val)
 {
 	if (sc->bge_asicrev == BGE_ASICREV_BCM5906)
@@ -4320,7 +4318,7 @@
 	return (0);
 }
 
-static void
+void
 bge_link_upd(struct bge_softc *sc)
 {
 	struct mii_data *mii;
Index: src/add-ons/kernel/drivers/network/broadcom570x/dev/bge/glue.c
===================================================================
--- src/add-ons/kernel/drivers/network/broadcom570x/dev/bge/glue.c	(revision 28637)
+++ src/add-ons/kernel/drivers/network/broadcom570x/dev/bge/glue.c	(working copy)
@@ -31,28 +31,28 @@
 }
 
 
-// copied from if_bge.c
-static void
-bge_writembx(struct bge_softc *sc, int off, int val)
-{
-	if (sc->bge_asicrev == BGE_ASICREV_BCM5906)
-		off += BGE_LPMBX_IRQ0_HI - BGE_MBX_IRQ0_HI;
-
-	CSR_WRITE_4(sc, off, val);
-}
-
-
 int
 __haiku_disable_interrupts(device_t dev)
 {
 	struct bge_softc *sc = device_get_softc(dev);
 
-	uint32 statusword = CSR_READ_4(sc, BGE_MAC_STS) & BGE_MACSTAT_LINK_CHANGED;
+	uint32 linkChanged = CSR_READ_4(sc, BGE_MAC_STS) 
+		& BGE_MACSTAT_LINK_CHANGED;
+	uint32 notInterrupted = pci_read_config(sc->bge_dev, BGE_PCI_PCISTATE, 4)
+		& BGE_PCISTATE_INTR_STATE; 
+	// bit of a strange register name. a nonzero actually means 
+	// it is _not_ interrupted
 
-	if ((sc->bge_ifp->if_drv_flags & IFF_DRV_RUNNING) == 0 && !statusword
-		&& (pci_read_config(sc->bge_dev, BGE_PCI_PCISTATE,4) & BGE_PCISTATE_INTR_STATE))
+	if (notInterrupted)
 		return 0;
 
+	// this part is copied from bge_intr. Perhaps it is needed here
+	// to stop the storm of interrupts.
+	if ((sc->bge_asicrev == BGE_ASICREV_BCM5700 &&
+	    sc->bge_chipid != BGE_CHIPID_BCM5700_B2) ||
+	    linkChanged || sc->bge_link_evt)
+		bge_link_upd(sc);
+
 	BGE_SETBIT(sc, BGE_PCI_MISC_CTL, BGE_PCIMISCCTL_MASK_PCI_INTR);
 	bge_writembx(sc, BGE_MBX_IRQ0_LO, 1);
 
Index: src/libs/compat/freebsd_network/fbsd_mii_physubr.c
===================================================================
--- src/libs/compat/freebsd_network/fbsd_mii_physubr.c	(revision 28637)
+++ src/libs/compat/freebsd_network/fbsd_mii_physubr.c	(working copy)
@@ -510,8 +510,10 @@
 	}
 
 	if (sc->mii_capabilities & BMSR_ANEG) {
-		ADD(IFM_MAKEWORD(IFM_ETHER, IFM_AUTO, 0, sc->mii_inst),
-		    MII_NMEDIA);	/* intentionally invalid index */
+		//ADD(IFM_MAKEWORD(IFM_ETHER, IFM_AUTO, 0, sc->mii_inst),
+		//    MII_NMEDIA);	/* intentionally invalid index */
+		//TODO: Why was this done? Incomplete code?
+		dprintf("don't know how to handle sc->mii_capabilities & BMSR_ANEG\n");
 		PRINT("auto");
 	}
 #undef ADD
