remove spurious spaces
[openwrt.git] / openwrt / target / linux / linux-2.4 / patches / brcm / 001-bcm47xx.patch
index 5e3fc34..9734878 100644 (file)
@@ -1,6 +1,167 @@
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/compressed/Makefile linux-2.4.30-brcm/arch/mips/bcm947xx/compressed/Makefile
---- linux-2.4.30/arch/mips/bcm947xx/compressed/Makefile        1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/compressed/Makefile   2005-05-26 03:29:22.000000000 +0200
+diff -urN linux.old/Makefile linux.dev/Makefile
+--- linux.old/Makefile 2005-08-26 13:41:41.689634168 +0200
++++ linux.dev/Makefile 2005-08-26 13:44:34.233403528 +0200
+@@ -17,9 +17,9 @@
+ FINDHPATH     = $(HPATH)/asm $(HPATH)/linux $(HPATH)/scsi $(HPATH)/net $(HPATH)/math-emu
+ HOSTCC        = gcc
+-HOSTCFLAGS    = -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer
++HOSTCFLAGS    = -Wall -Wstrict-prototypes -Os -fomit-frame-pointer
+-CROSS_COMPILE         =
++CROSS_COMPILE=
+ #
+ # Include the make variables (CC, etc...)
+@@ -91,8 +91,10 @@
+ CPPFLAGS := -D__KERNEL__ -I$(HPATH)
+-CFLAGS := $(CPPFLAGS) -Wall -Wstrict-prototypes -Wno-trigraphs -O2 \
++CFLAGS := $(CPPFLAGS) -Wall -Wstrict-prototypes -Wno-trigraphs -Os \
+         -fno-strict-aliasing -fno-common
++
++
+ ifndef CONFIG_FRAME_POINTER
+ CFLAGS += -fomit-frame-pointer
+ endif
+@@ -354,7 +356,7 @@
+       @rm -f .ver1
+ include/linux/version.h: ./Makefile
+-      @expr length "$(KERNELRELEASE)" \<= $(uts_len) > /dev/null || \
++      @-expr length "$(KERNELRELEASE)" \<= $(uts_len) > /dev/null || \
+         (echo KERNELRELEASE \"$(KERNELRELEASE)\" exceeds $(uts_len) characters >&2; false)
+       @echo \#define UTS_RELEASE \"$(KERNELRELEASE)\" > .ver
+       @echo \#define LINUX_VERSION_CODE `expr $(VERSION) \\* 65536 + $(PATCHLEVEL) \\* 256 + $(SUBLEVEL)` >> .ver
+@@ -501,7 +503,7 @@
+ ifdef CONFIG_MODVERSIONS
+       $(MAKE) update-modverfile
+ endif
+-      scripts/mkdep -- `find $(FINDHPATH) \( -name SCCS -o -name .svn \) -prune -o -follow -name \*.h ! -name modversions.h -print` > .hdepend
++      (find $(FINDHPATH) \( -name SCCS -o -name .svn \) -prune -o -follow -name \*.h ! -name modversions.h -print | xargs -r scripts/mkdep -- ) > .hdepend
+       scripts/mkdep -- init/*.c > .depend
+ ifdef CONFIG_MODVERSIONS
+diff -urN linux.old/Rules.make linux.dev/Rules.make
+--- linux.old/Rules.make       2004-02-18 14:36:30.000000000 +0100
++++ linux.dev/Rules.make       2005-08-26 13:44:34.252400640 +0200
+@@ -176,7 +176,14 @@
+ _modinst__: dummy
+ ifneq "$(strip $(ALL_MOBJS))" ""
+       mkdir -p $(MODLIB)/kernel/$(MOD_DESTDIR)
+-      cp $(sort $(ALL_MOBJS)) $(MODLIB)/kernel/$(MOD_DESTDIR)
++      #@cp $(sort $(ALL_MOBJS)) $(MODLIB)/kernel/$(MOD_DESTDIR)
++      for f in $(ALL_MOBJS) ; do \
++              $(OBJCOPY) -R __ksymtab -R .comment -R .note -x \
++              `$(NM) $$f | cut -f3- -d' ' | sed -n \
++                      -e 's/__module_parm_\(.*\)/-K \1/p' \
++                      -e 's/__ks..tab_\(.*\)/-K \1/p'` \
++              $$f $(MODLIB)/kernel/$(MOD_DESTDIR)$(MOD_TARGET)$$f; \
++      done
+ endif
+ .PHONY: modules_install
+diff -urN linux.old/arch/mips/Makefile linux.dev/arch/mips/Makefile
+--- linux.old/arch/mips/Makefile       2005-08-26 13:41:41.690634016 +0200
++++ linux.dev/arch/mips/Makefile       2005-08-26 13:44:34.253400488 +0200
+@@ -46,10 +46,10 @@
+ GCCFLAGS      := -I $(TOPDIR)/include/asm/gcc
+ GCCFLAGS      += -G 0 -mno-abicalls -fno-pic -pipe
+ GCCFLAGS      += $(call check_gcc, -finline-limit=100000,)
+-LINKFLAGS     += -G 0 -static -n
+-MODFLAGS      += -mlong-calls
++LINKFLAGS     += -G 0 -static -n -nostdlib
++MODFLAGS      += -mlong-calls -fno-common
+-ifdef CONFIG_DEBUG_INFO
++ifdef CONFIG_REMOTE_DEBUG
+ GCCFLAGS      += -g
+ ifdef CONFIG_SB1XXX_CORELIS
+ GCCFLAGS      += -mno-sched-prolog -fno-omit-frame-pointer
+@@ -71,13 +71,13 @@
+ set_gccflags = $(shell \
+ while :; do \
+       cpu=$(1); isa=-$(2); \
+-      for gcc_opt in -march= -mcpu=; do \
++      for gcc_opt in -march= -mtune=; do \
+               $(CC) $$gcc_opt$$cpu $$isa -S -o /dev/null \
+                       -xc /dev/null > /dev/null 2>&1 && \
+                       break 2; \
+       done; \
+       cpu=$(3); isa=-$(4); \
+-      for gcc_opt in -march= -mcpu=; do \
++      for gcc_opt in -march= -mtune=; do \
+               $(CC) $$gcc_opt$$cpu $$isa -S -o /dev/null \
+                       -xc /dev/null > /dev/null 2>&1 && \
+                       break 2; \
+@@ -92,7 +92,7 @@
+ fi; \
+ gas_abi=-Wa,-32; gas_cpu=$$cpu; gas_isa=-Wa,$$isa; \
+ while :; do \
+-      for gas_opt in -Wa,-march= -Wa,-mcpu=; do \
++      for gas_opt in -Wa,-march= -Wa,-mtune=; do \
+               $(CC) $$gas_abi $$gas_opt$$cpu $$gas_isa -Wa,-Z -c \
+                       -o /dev/null -xassembler /dev/null > /dev/null 2>&1 && \
+                       break 2; \
+@@ -174,6 +174,7 @@
+ endif
+ AFLAGS                += $(GCCFLAGS)
++ASFLAGS               += $(GCCFLAGS)
+ CFLAGS                += $(GCCFLAGS)
+ LD            += -m $(ld-emul)
+@@ -727,6 +728,19 @@
+ endif
+ #
++# Broadcom BCM947XX variants
++#
++ifdef CONFIG_BCM947XX
++LIBS          += arch/mips/bcm947xx/generic/brcm.o arch/mips/bcm947xx/bcm947xx.o 
++SUBDIRS               += arch/mips/bcm947xx/generic arch/mips/bcm947xx 
++LOADADDR      := 0x80001000
++
++zImage: vmlinux
++      $(MAKE) -C arch/$(ARCH)/bcm947xx/compressed
++export LOADADDR
++endif
++
++#
+ # Choosing incompatible machines durings configuration will result in
+ # error messages during linking.  Select a default linkscript if
+ # none has been choosen above.
+@@ -779,6 +793,7 @@
+       $(MAKE) -C arch/$(ARCH)/tools clean
+       $(MAKE) -C arch/mips/baget clean
+       $(MAKE) -C arch/mips/lasat clean
++      $(MAKE) -C arch/mips/bcm947xx/compressed clean
+ archmrproper:
+       @$(MAKEBOOT) mrproper
+diff -urN linux.old/arch/mips/bcm947xx/Makefile linux.dev/arch/mips/bcm947xx/Makefile
+--- linux.old/arch/mips/bcm947xx/Makefile      1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/Makefile      2005-08-26 13:44:34.262399120 +0200
+@@ -0,0 +1,15 @@
++#
++# Makefile for the BCM947xx specific kernel interface routines
++# under Linux.
++#
++
++EXTRA_CFLAGS+=-I$(TOPDIR)/arch/mips/bcm947xx/include -DBCMDRIVER
++
++O_TARGET        := bcm947xx.o
++
++export-objs     := nvram_linux.o setup.o
++obj-y         := prom.o setup.o time.o sbmips.o gpio.o
++obj-y         += nvram.o nvram_linux.o
++obj-$(CONFIG_PCI) += sbpci.o pcibios.o
++
++include $(TOPDIR)/Rules.make
+diff -urN linux.old/arch/mips/bcm947xx/compressed/Makefile linux.dev/arch/mips/bcm947xx/compressed/Makefile
+--- linux.old/arch/mips/bcm947xx/compressed/Makefile   1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/compressed/Makefile   2005-08-26 13:44:34.262399120 +0200
 @@ -0,0 +1,33 @@
 +#
 +# Makefile for Broadcom BCM947XX boards
@@ -35,9 +196,28 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/compressed/Makefile linux-2.4.30-brcm/
 +
 +clean:
 +      rm -f vmlinuz piggy
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/generic/int-handler.S linux-2.4.30-brcm/arch/mips/bcm947xx/generic/int-handler.S
---- linux-2.4.30/arch/mips/bcm947xx/generic/int-handler.S      1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/generic/int-handler.S 2005-05-22 22:55:51.000000000 +0200
+diff -urN linux.old/arch/mips/bcm947xx/generic/Makefile linux.dev/arch/mips/bcm947xx/generic/Makefile
+--- linux.old/arch/mips/bcm947xx/generic/Makefile      1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/generic/Makefile      2005-08-26 13:44:34.263398968 +0200
+@@ -0,0 +1,15 @@
++#
++# Makefile for the BCM947xx specific kernel interface routines
++# under Linux.
++#
++
++.S.s:
++      $(CPP) $(AFLAGS) $< -o $*.s
++.S.o:
++      $(CC) $(AFLAGS) -c $< -o $*.o
++
++O_TARGET        := brcm.o
++
++obj-y := int-handler.o irq.o
++
++include $(TOPDIR)/Rules.make
+diff -urN linux.old/arch/mips/bcm947xx/generic/int-handler.S linux.dev/arch/mips/bcm947xx/generic/int-handler.S
+--- linux.old/arch/mips/bcm947xx/generic/int-handler.S 1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/generic/int-handler.S 2005-08-26 13:44:34.263398968 +0200
 @@ -0,0 +1,51 @@
 +/*
 + * Generic interrupt handler for Broadcom MIPS boards
@@ -90,9 +270,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/generic/int-handler.S linux-2.4.30-brc
 +       nop
 +              
 +      END(brcmIRQ)
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/generic/irq.c linux-2.4.30-brcm/arch/mips/bcm947xx/generic/irq.c
---- linux-2.4.30/arch/mips/bcm947xx/generic/irq.c      1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/generic/irq.c 2005-05-22 22:55:51.000000000 +0200
+diff -urN linux.old/arch/mips/bcm947xx/generic/irq.c linux.dev/arch/mips/bcm947xx/generic/irq.c
+--- linux.old/arch/mips/bcm947xx/generic/irq.c 1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/generic/irq.c 2005-08-26 13:44:34.263398968 +0200
 @@ -0,0 +1,130 @@
 +/*
 + * Generic interrupt control functions for Broadcom MIPS boards
@@ -224,28 +404,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/generic/irq.c linux-2.4.30-brcm/arch/m
 +      breakpoint(); 
 +#endif
 +}
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/generic/Makefile linux-2.4.30-brcm/arch/mips/bcm947xx/generic/Makefile
---- linux-2.4.30/arch/mips/bcm947xx/generic/Makefile   1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/generic/Makefile      2005-05-25 18:53:41.000000000 +0200
-@@ -0,0 +1,15 @@
-+#
-+# Makefile for the BCM947xx specific kernel interface routines
-+# under Linux.
-+#
-+
-+.S.s:
-+      $(CPP) $(AFLAGS) $< -o $*.s
-+.S.o:
-+      $(CC) $(AFLAGS) -c $< -o $*.o
-+
-+O_TARGET        := brcm.o
-+
-+obj-y := int-handler.o irq.o
-+
-+include $(TOPDIR)/Rules.make
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/gpio.c linux-2.4.30-brcm/arch/mips/bcm947xx/gpio.c
---- linux-2.4.30/arch/mips/bcm947xx/gpio.c     1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/gpio.c        2005-05-22 22:55:51.000000000 +0200
+diff -urN linux.old/arch/mips/bcm947xx/gpio.c linux.dev/arch/mips/bcm947xx/gpio.c
+--- linux.old/arch/mips/bcm947xx/gpio.c        1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/gpio.c        2005-08-26 13:44:34.264398816 +0200
 @@ -0,0 +1,158 @@
 +/*
 + * GPIO char driver
@@ -405,9 +566,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/gpio.c linux-2.4.30-brcm/arch/mips/bcm
 +
 +module_init(gpio_init);
 +module_exit(gpio_exit);
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmdevs.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmdevs.h
---- linux-2.4.30/arch/mips/bcm947xx/include/bcmdevs.h  1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmdevs.h     2005-05-25 20:30:26.000000000 +0200
+diff -urN linux.old/arch/mips/bcm947xx/include/bcmdevs.h linux.dev/arch/mips/bcm947xx/include/bcmdevs.h
+--- linux.old/arch/mips/bcm947xx/include/bcmdevs.h     1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/bcmdevs.h     2005-08-26 13:44:34.265398664 +0200
 @@ -0,0 +1,369 @@
 +/*
 + * Broadcom device-specific manifest constants.
@@ -778,9 +939,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmdevs.h linux-2.4.30-brcm/ar
 +#define GPIO_NUMPINS          16
 +
 +#endif /* _BCMDEVS_H */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmendian.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmendian.h
---- linux-2.4.30/arch/mips/bcm947xx/include/bcmendian.h        1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmendian.h   2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/bcmendian.h linux.dev/arch/mips/bcm947xx/include/bcmendian.h
+--- linux.old/arch/mips/bcm947xx/include/bcmendian.h   1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/bcmendian.h   2005-08-26 13:44:34.269398056 +0200
 @@ -0,0 +1,168 @@
 +/*
 + * local version of endian.h - byte order defines
@@ -950,9 +1111,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmendian.h linux-2.4.30-brcm/
 +#endif
 +
 +#endif /* _BCMENDIAN_H_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmenet47xx.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmenet47xx.h
---- linux-2.4.30/arch/mips/bcm947xx/include/bcmenet47xx.h      1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmenet47xx.h 2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/bcmenet47xx.h linux.dev/arch/mips/bcm947xx/include/bcmenet47xx.h
+--- linux.old/arch/mips/bcm947xx/include/bcmenet47xx.h 1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/bcmenet47xx.h 2005-08-26 13:44:34.270397904 +0200
 @@ -0,0 +1,229 @@
 +/*
 + * Hardware-specific definitions for
@@ -1183,9 +1344,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmenet47xx.h linux-2.4.30-brc
 +#define       EMC_RZ          ((uint32)1 << 0)        /* autoclear on read */
 +
 +#endif        /* _bcmenet_47xx_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmenetmib.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmenetmib.h
---- linux-2.4.30/arch/mips/bcm947xx/include/bcmenetmib.h       1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmenetmib.h  2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/bcmenetmib.h linux.dev/arch/mips/bcm947xx/include/bcmenetmib.h
+--- linux.old/arch/mips/bcm947xx/include/bcmenetmib.h  1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/bcmenetmib.h  2005-08-26 13:44:34.278396688 +0200
 @@ -0,0 +1,81 @@
 +/*
 + * Hardware-specific MIB definition for
@@ -1268,9 +1429,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmenetmib.h linux-2.4.30-brcm
 +} bcmenetmib_t;
 +
 +#endif        /* _bcmenetmib_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmenetphy.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmenetphy.h
---- linux-2.4.30/arch/mips/bcm947xx/include/bcmenetphy.h       1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmenetphy.h  2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/bcmenetphy.h linux.dev/arch/mips/bcm947xx/include/bcmenetphy.h
+--- linux.old/arch/mips/bcm947xx/include/bcmenetphy.h  1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/bcmenetphy.h  2005-08-26 13:44:34.278396688 +0200
 @@ -0,0 +1,58 @@
 +/*
 + * Misc Broadcom BCM47XX MDC/MDIO enet phy definitions.
@@ -1330,9 +1491,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmenetphy.h linux-2.4.30-brcm
 +#define       AUX_DUPLEX      (1 << 0)                /* duplex 0=half 1=full */
 +
 +#endif        /* _bcmenetphy_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmenetrxh.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmenetrxh.h
---- linux-2.4.30/arch/mips/bcm947xx/include/bcmenetrxh.h       1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmenetrxh.h  2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/bcmenetrxh.h linux.dev/arch/mips/bcm947xx/include/bcmenetrxh.h
+--- linux.old/arch/mips/bcm947xx/include/bcmenetrxh.h  1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/bcmenetrxh.h  2005-08-26 13:44:34.278396688 +0200
 @@ -0,0 +1,43 @@
 +/*
 + * Hardware-specific Receive Data Header for the
@@ -1377,9 +1538,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmenetrxh.h linux-2.4.30-brcm
 +#define       RXF_OV          ((uint16)1 << 0)        /* fifo overflow */
 +
 +#endif        /* _bcmenetrxh_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmnvram.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmnvram.h
---- linux-2.4.30/arch/mips/bcm947xx/include/bcmnvram.h 1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmnvram.h    2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/bcmnvram.h linux.dev/arch/mips/bcm947xx/include/bcmnvram.h
+--- linux.old/arch/mips/bcm947xx/include/bcmnvram.h    1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/bcmnvram.h    2005-08-26 13:44:34.279396536 +0200
 @@ -0,0 +1,132 @@
 +/*
 + * NVRAM variable manipulation
@@ -1513,9 +1674,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmnvram.h linux-2.4.30-brcm/a
 +#define NVRAM_SPACE           0x8000
 +
 +#endif /* _bcmnvram_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmparams.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmparams.h
---- linux-2.4.30/arch/mips/bcm947xx/include/bcmparams.h        1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmparams.h   2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/bcmparams.h linux.dev/arch/mips/bcm947xx/include/bcmparams.h
+--- linux.old/arch/mips/bcm947xx/include/bcmparams.h   1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/bcmparams.h   2005-08-26 13:44:34.279396536 +0200
 @@ -0,0 +1,23 @@
 +/*
 + * Misc system wide parameters.
@@ -1540,9 +1701,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmparams.h linux-2.4.30-brcm/
 +#define DEV_NUMIFS    16      /* Max. # of devices/interfaces supported */
 +
 +#endif
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmsrom.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmsrom.h
---- linux-2.4.30/arch/mips/bcm947xx/include/bcmsrom.h  1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmsrom.h     2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/bcmsrom.h linux.dev/arch/mips/bcm947xx/include/bcmsrom.h
+--- linux.old/arch/mips/bcm947xx/include/bcmsrom.h     1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/bcmsrom.h     2005-08-26 13:44:34.280396384 +0200
 @@ -0,0 +1,22 @@
 +/*
 + * Misc useful routines to access NIC local SROM/OTP .
@@ -1566,9 +1727,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmsrom.h linux-2.4.30-brcm/ar
 +extern int srom_write(uint bus, void *curmap, void *osh, uint byteoff, uint nbytes, uint16 *buf);
 +         
 +#endif        /* _bcmsrom_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmutils.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmutils.h
---- linux-2.4.30/arch/mips/bcm947xx/include/bcmutils.h 1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/bcmutils.h    2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/bcmutils.h linux.dev/arch/mips/bcm947xx/include/bcmutils.h
+--- linux.old/arch/mips/bcm947xx/include/bcmutils.h    1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/bcmutils.h    2005-08-26 13:44:34.280396384 +0200
 @@ -0,0 +1,239 @@
 +/*
 + * Misc useful os-independent macros and functions.
@@ -1809,9 +1970,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bcmutils.h linux-2.4.30-brcm/a
 +#define       mboolmaskset(mb, mask, val)     ((mb) = (((mb) & ~(mask)) | (val)))
 +
 +#endif        /* _bcmutils_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bitfuncs.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/bitfuncs.h
---- linux-2.4.30/arch/mips/bcm947xx/include/bitfuncs.h 1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/bitfuncs.h    2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/bitfuncs.h linux.dev/arch/mips/bcm947xx/include/bitfuncs.h
+--- linux.old/arch/mips/bcm947xx/include/bitfuncs.h    1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/bitfuncs.h    2005-08-26 13:44:34.281396232 +0200
 @@ -0,0 +1,85 @@
 +/*
 + * bit manipulation utility functions
@@ -1898,9 +2059,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/bitfuncs.h linux-2.4.30-brcm/a
 +#endif
 +
 +#endif /* _BITFUNCS_H */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/cfe_osl.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/cfe_osl.h
---- linux-2.4.30/arch/mips/bcm947xx/include/cfe_osl.h  1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/cfe_osl.h     2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/cfe_osl.h linux.dev/arch/mips/bcm947xx/include/cfe_osl.h
+--- linux.old/arch/mips/bcm947xx/include/cfe_osl.h     1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/cfe_osl.h     2005-08-26 13:44:34.281396232 +0200
 @@ -0,0 +1,184 @@
 +/*
 + * CFE boot loader OS Abstraction Layer.
@@ -2086,9 +2247,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/cfe_osl.h linux-2.4.30-brcm/ar
 +extern struct lbuf *osl_pktdup(struct lbuf *lb);
 +
 +#endif        /* _cfe_osl_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/epivers.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/epivers.h
---- linux-2.4.30/arch/mips/bcm947xx/include/epivers.h  1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/epivers.h     2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/epivers.h linux.dev/arch/mips/bcm947xx/include/epivers.h
+--- linux.old/arch/mips/bcm947xx/include/epivers.h     1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/epivers.h     2005-08-26 13:44:34.282396080 +0200
 @@ -0,0 +1,69 @@
 +/*
 + * Copyright 2005, Broadcom Corporation
@@ -2159,9 +2320,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/epivers.h linux-2.4.30-brcm/ar
 +#define       EPI_ROUTER_VERSION_STR  "3.91.23.0"
 +
 +#endif /* _epivers_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/epivers.h.in linux-2.4.30-brcm/arch/mips/bcm947xx/include/epivers.h.in
---- linux-2.4.30/arch/mips/bcm947xx/include/epivers.h.in       1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/epivers.h.in  2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/epivers.h.in linux.dev/arch/mips/bcm947xx/include/epivers.h.in
+--- linux.old/arch/mips/bcm947xx/include/epivers.h.in  1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/epivers.h.in  2005-08-26 13:44:34.282396080 +0200
 @@ -0,0 +1,69 @@
 +/*
 + * Copyright 2005, Broadcom Corporation
@@ -2232,9 +2393,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/epivers.h.in linux-2.4.30-brcm
 +#define       EPI_ROUTER_VERSION_STR  "@EPI_ROUTER_VERSION_STR@"
 +
 +#endif /* _epivers_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/etsockio.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/etsockio.h
---- linux-2.4.30/arch/mips/bcm947xx/include/etsockio.h 1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/etsockio.h    2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/etsockio.h linux.dev/arch/mips/bcm947xx/include/etsockio.h
+--- linux.old/arch/mips/bcm947xx/include/etsockio.h    1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/etsockio.h    2005-08-26 13:44:34.283395928 +0200
 @@ -0,0 +1,59 @@
 +/*
 + * Driver-specific socket ioctls
@@ -2295,9 +2456,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/etsockio.h linux-2.4.30-brcm/a
 +};
 +
 +#endif
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/flash.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/flash.h
---- linux-2.4.30/arch/mips/bcm947xx/include/flash.h    1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/flash.h       2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/flash.h linux.dev/arch/mips/bcm947xx/include/flash.h
+--- linux.old/arch/mips/bcm947xx/include/flash.h       1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/flash.h       2005-08-27 02:56:56.458670688 +0200
 @@ -0,0 +1,188 @@
 +/*
 + * flash.h: Common definitions for flash access.
@@ -2464,7 +2625,7 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/flash.h linux-2.4.30-brcm/arch
 +      { 0x0001, 0x2249, 0x0200000, 2, AMD, 0x10000, 32,  1, 31,  4, amd4112, "AMD 29lv160DB 1Mx16 BotB" },
 +      { 0x0001, 0x22f6, 0x0400000, 2, AMD, 0x10000, 64,  0, 62,  8, blk8x8k, "AMD 29lv320DT 2Mx16 TopB" },
 +      { 0x0001, 0x22f9, 0x0400000, 2, AMD, 0x10000, 64,  1, 63,  8, blk8x8k, "AMD 29lv320DB 2Mx16 BotB" },
-+      { 0x0001, 0x2201, 0x0400000, 2, AMD, 0x10000, 64,  0, 62,  8, blk8x8k, "AMD 29lv320MT 2Mx16 TopB" },
++      { 0x0001, 0x227e, 0x0400000, 2, AMD, 0x10000, 64,  0, 62,  8, blk8x8k, "AMD 29lv320MT 2Mx16 TopB" },
 +      { 0x0001, 0x2200, 0x0400000, 2, AMD, 0x10000, 64,  1, 63,  8, blk8x8k, "AMD 29lv320MB 2Mx16 BotB" },
 +      { 0x0020, 0x22CA, 0x0400000, 2, AMD, 0x10000, 64,  0, 62,  4, amd4112, "ST 29w320DT 2Mx16 TopB" },
 +      { 0x0020, 0x22CB, 0x0400000, 2, AMD, 0x10000, 64,  1, 63,  4, amd2114, "ST 29w320DB 2Mx16 BotB" },
@@ -2487,9 +2648,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/flash.h linux-2.4.30-brcm/arch
 +extern flash_desc_t flashes[];
 +
 +#endif
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/flashutl.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/flashutl.h
---- linux-2.4.30/arch/mips/bcm947xx/include/flashutl.h 1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/flashutl.h    2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/flashutl.h linux.dev/arch/mips/bcm947xx/include/flashutl.h
+--- linux.old/arch/mips/bcm947xx/include/flashutl.h    1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/flashutl.h    2005-08-26 13:44:34.284395776 +0200
 @@ -0,0 +1,27 @@
 +/*
 + * BCM47XX FLASH driver interface
@@ -2518,9 +2679,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/flashutl.h linux-2.4.30-brcm/a
 +#endif        /* _LANGUAGE_ASSEMBLY */
 +
 +#endif /* _flashutl_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/hnddma.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/hnddma.h
---- linux-2.4.30/arch/mips/bcm947xx/include/hnddma.h   1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/hnddma.h      2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/hnddma.h linux.dev/arch/mips/bcm947xx/include/hnddma.h
+--- linux.old/arch/mips/bcm947xx/include/hnddma.h      1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/hnddma.h      2005-08-26 13:44:34.284395776 +0200
 @@ -0,0 +1,184 @@
 +/*
 + * Generic Broadcom Home Networking Division (HND) DMA engine definitions.
@@ -2706,9 +2867,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/hnddma.h linux-2.4.30-brcm/arc
 +
 +
 +#endif        /* _hnddma_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/hndmips.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/hndmips.h
---- linux-2.4.30/arch/mips/bcm947xx/include/hndmips.h  1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/hndmips.h     2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/hndmips.h linux.dev/arch/mips/bcm947xx/include/hndmips.h
+--- linux.old/arch/mips/bcm947xx/include/hndmips.h     1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/hndmips.h     2005-08-26 13:44:34.285395624 +0200
 @@ -0,0 +1,16 @@
 +/*
 + * Alternate include file for HND sbmips.h since CFE also ships with
@@ -2726,9 +2887,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/hndmips.h linux-2.4.30-brcm/ar
 + */
 +
 +#include "sbmips.h"
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/linux_osl.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/linux_osl.h
---- linux-2.4.30/arch/mips/bcm947xx/include/linux_osl.h        1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/linux_osl.h   2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/linux_osl.h linux.dev/arch/mips/bcm947xx/include/linux_osl.h
+--- linux.old/arch/mips/bcm947xx/include/linux_osl.h   1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/linux_osl.h   2005-08-26 13:44:34.286395472 +0200
 @@ -0,0 +1,341 @@
 +/*
 + * Linux OS Independent Layer
@@ -3071,9 +3232,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/linux_osl.h linux-2.4.30-brcm/
 +#define       PKTBUFSZ        2048
 +
 +#endif        /* _linux_osl_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/linuxver.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/linuxver.h
---- linux-2.4.30/arch/mips/bcm947xx/include/linuxver.h 1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/linuxver.h    2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/linuxver.h linux.dev/arch/mips/bcm947xx/include/linuxver.h
+--- linux.old/arch/mips/bcm947xx/include/linuxver.h    1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/linuxver.h    2005-08-26 13:44:34.287395320 +0200
 @@ -0,0 +1,399 @@
 +/*
 + * Linux-specific abstractions to gain some independence from linux kernel versions.
@@ -3474,9 +3635,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/linuxver.h linux-2.4.30-brcm/a
 +#endif
 +
 +#endif /* _linuxver_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/min_osl.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/min_osl.h
---- linux-2.4.30/arch/mips/bcm947xx/include/min_osl.h  1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/min_osl.h     2005-05-25 03:31:09.000000000 +0200
+diff -urN linux.old/arch/mips/bcm947xx/include/min_osl.h linux.dev/arch/mips/bcm947xx/include/min_osl.h
+--- linux.old/arch/mips/bcm947xx/include/min_osl.h     1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/min_osl.h     2005-08-26 13:44:34.287395320 +0200
 @@ -0,0 +1,120 @@
 +/*
 + * HND Minimal OS Abstraction Layer.
@@ -3598,9 +3759,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/min_osl.h linux-2.4.30-brcm/ar
 +extern int getintvar(char *vars, char *name);
 +
 +#endif        /* _min_osl_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/mipsinc.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/mipsinc.h
---- linux-2.4.30/arch/mips/bcm947xx/include/mipsinc.h  1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/mipsinc.h     2005-05-26 02:34:15.000000000 +0200
+diff -urN linux.old/arch/mips/bcm947xx/include/mipsinc.h linux.dev/arch/mips/bcm947xx/include/mipsinc.h
+--- linux.old/arch/mips/bcm947xx/include/mipsinc.h     1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/mipsinc.h     2005-08-26 13:44:34.288395168 +0200
 @@ -0,0 +1,524 @@
 +/*
 + * HND Run Time Environment for standalone MIPS programs.
@@ -4126,9 +4287,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/mipsinc.h linux-2.4.30-brcm/ar
 +
 +
 +#endif        /* _MISPINC_H */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/nvports.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/nvports.h
---- linux-2.4.30/arch/mips/bcm947xx/include/nvports.h  1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/nvports.h     2005-02-02 23:41:24.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/nvports.h linux.dev/arch/mips/bcm947xx/include/nvports.h
+--- linux.old/arch/mips/bcm947xx/include/nvports.h     1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/nvports.h     2005-08-26 13:44:34.291394712 +0200
 @@ -0,0 +1,55 @@
 +/*
 + * BCM53xx RoboSwitch utility functions
@@ -4185,9 +4346,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/nvports.h linux-2.4.30-brcm/ar
 +
 +
 +
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/osl.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/osl.h
---- linux-2.4.30/arch/mips/bcm947xx/include/osl.h      1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/osl.h 2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/osl.h linux.dev/arch/mips/bcm947xx/include/osl.h
+--- linux.old/arch/mips/bcm947xx/include/osl.h 1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/osl.h 2005-08-26 13:44:34.291394712 +0200
 @@ -0,0 +1,39 @@
 +/*
 + * OS Independent Layer
@@ -4228,9 +4389,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/osl.h linux-2.4.30-brcm/arch/m
 +#define       MAXPRIO         7       /* 0-7 */
 +
 +#endif        /* _osl_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/pcicfg.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/pcicfg.h
---- linux-2.4.30/arch/mips/bcm947xx/include/pcicfg.h   1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/pcicfg.h      2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/pcicfg.h linux.dev/arch/mips/bcm947xx/include/pcicfg.h
+--- linux.old/arch/mips/bcm947xx/include/pcicfg.h      1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/pcicfg.h      2005-08-26 13:44:34.292394560 +0200
 @@ -0,0 +1,369 @@
 +/*
 + * pcicfg.h: PCI configuration  constants and structures.
@@ -4601,9 +4762,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/pcicfg.h linux-2.4.30-brcm/arc
 +#define PCI_CFG_CMD_STAT_TA   0x08000000      /* target abort status */
 +
 +#endif
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/pmon_osl.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/pmon_osl.h
---- linux-2.4.30/arch/mips/bcm947xx/include/pmon_osl.h 1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/pmon_osl.h    2005-02-02 23:16:39.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/pmon_osl.h linux.dev/arch/mips/bcm947xx/include/pmon_osl.h
+--- linux.old/arch/mips/bcm947xx/include/pmon_osl.h    1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/pmon_osl.h    2005-08-26 13:44:34.293394408 +0200
 @@ -0,0 +1,126 @@
 +/*
 + * MIPS PMON boot loader OS Abstraction Layer.
@@ -4731,9 +4892,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/pmon_osl.h linux-2.4.30-brcm/a
 +extern void et_pktfree(void *drv, struct lbuf *lb, bool send);
 +
 +#endif        /* _pmon_osl_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/proto/802.11.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/proto/802.11.h
---- linux-2.4.30/arch/mips/bcm947xx/include/proto/802.11.h     1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/proto/802.11.h        2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/proto/802.11.h linux.dev/arch/mips/bcm947xx/include/proto/802.11.h
+--- linux.old/arch/mips/bcm947xx/include/proto/802.11.h        1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/proto/802.11.h        2005-08-26 13:44:34.295394104 +0200
 @@ -0,0 +1,897 @@
 +/*
 + * Copyright 2005, Broadcom Corporation      
@@ -5632,9 +5793,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/proto/802.11.h linux-2.4.30-br
 +#endif
 +
 +#endif /* _802_11_H_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/proto/bcmeth.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/proto/bcmeth.h
---- linux-2.4.30/arch/mips/bcm947xx/include/proto/bcmeth.h     1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/proto/bcmeth.h        2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/proto/bcmeth.h linux.dev/arch/mips/bcm947xx/include/proto/bcmeth.h
+--- linux.old/arch/mips/bcm947xx/include/proto/bcmeth.h        1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/proto/bcmeth.h        2005-08-26 13:44:34.295394104 +0200
 @@ -0,0 +1,97 @@
 +/*
 + * Broadcom Ethernettype  protocol definitions
@@ -5733,9 +5894,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/proto/bcmeth.h linux-2.4.30-br
 +#endif
 +
 +#endif
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/proto/ethernet.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/proto/ethernet.h
---- linux-2.4.30/arch/mips/bcm947xx/include/proto/ethernet.h   1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/proto/ethernet.h      2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/proto/ethernet.h linux.dev/arch/mips/bcm947xx/include/proto/ethernet.h
+--- linux.old/arch/mips/bcm947xx/include/proto/ethernet.h      1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/proto/ethernet.h      2005-08-26 13:44:34.296393952 +0200
 @@ -0,0 +1,161 @@
 +/*******************************************************************************
 + * $Id$
@@ -5898,9 +6059,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/proto/ethernet.h linux-2.4.30-
 +#endif
 +
 +#endif /* _NET_ETHERNET_H_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/proto/vlan.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/proto/vlan.h
---- linux-2.4.30/arch/mips/bcm947xx/include/proto/vlan.h       1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/proto/vlan.h  2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/proto/vlan.h linux.dev/arch/mips/bcm947xx/include/proto/vlan.h
+--- linux.old/arch/mips/bcm947xx/include/proto/vlan.h  1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/proto/vlan.h  2005-08-26 13:44:34.296393952 +0200
 @@ -0,0 +1,50 @@
 +/*
 + * 802.1Q VLAN protocol definitions
@@ -5952,9 +6113,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/proto/vlan.h linux-2.4.30-brcm
 +#endif
 +
 +#endif /* _vlan_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/proto/wpa.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/proto/wpa.h
---- linux-2.4.30/arch/mips/bcm947xx/include/proto/wpa.h        1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/proto/wpa.h   2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/proto/wpa.h linux.dev/arch/mips/bcm947xx/include/proto/wpa.h
+--- linux.old/arch/mips/bcm947xx/include/proto/wpa.h   1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/proto/wpa.h   2005-08-26 13:44:34.297393800 +0200
 @@ -0,0 +1,140 @@
 +/*
 + * Fundamental types and constants relating to WPA
@@ -6096,9 +6257,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/proto/wpa.h linux-2.4.30-brcm/
 +#endif
 +
 +#endif /* _proto_wpa_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/rts/crc.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/rts/crc.h
---- linux-2.4.30/arch/mips/bcm947xx/include/rts/crc.h  1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/rts/crc.h     2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/rts/crc.h linux.dev/arch/mips/bcm947xx/include/rts/crc.h
+--- linux.old/arch/mips/bcm947xx/include/rts/crc.h     1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/rts/crc.h     2005-08-26 13:44:34.297393800 +0200
 @@ -0,0 +1,69 @@
 +/*******************************************************************************
 + * $Id$
@@ -6169,9 +6330,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/rts/crc.h linux-2.4.30-brcm/ar
 +#endif
 +
 +#endif /* _RTS_CRC_H_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbchipc.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbchipc.h
---- linux-2.4.30/arch/mips/bcm947xx/include/sbchipc.h  1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbchipc.h     2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/sbchipc.h linux.dev/arch/mips/bcm947xx/include/sbchipc.h
+--- linux.old/arch/mips/bcm947xx/include/sbchipc.h     1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/sbchipc.h     2005-08-26 13:44:34.298393648 +0200
 @@ -0,0 +1,394 @@
 +/*
 + * SiliconBackplane Chipcommon core hardware definitions.
@@ -6567,9 +6728,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbchipc.h linux-2.4.30-brcm/ar
 +#define       OTP_MAGIC       0x4e56
 +
 +#endif        /* _SBCHIPC_H */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbconfig.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbconfig.h
---- linux-2.4.30/arch/mips/bcm947xx/include/sbconfig.h 1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbconfig.h    2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/sbconfig.h linux.dev/arch/mips/bcm947xx/include/sbconfig.h
+--- linux.old/arch/mips/bcm947xx/include/sbconfig.h    1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/sbconfig.h    2005-08-26 13:44:34.299393496 +0200
 @@ -0,0 +1,324 @@
 +/*
 + * Broadcom SiliconBackplane hardware register definitions.
@@ -6895,9 +7056,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbconfig.h linux-2.4.30-brcm/a
 +#define       BISZ_BSSEND_IDX         6               /*      6: text start */
 +
 +#endif        /* _SBCONFIG_H */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbextif.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbextif.h
---- linux-2.4.30/arch/mips/bcm947xx/include/sbextif.h  1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbextif.h     2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/sbextif.h linux.dev/arch/mips/bcm947xx/include/sbextif.h
+--- linux.old/arch/mips/bcm947xx/include/sbextif.h     1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/sbextif.h     2005-08-26 13:44:34.300393344 +0200
 @@ -0,0 +1,242 @@
 +/*
 + * Hardware-specific External Interface I/O core definitions
@@ -7141,9 +7302,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbextif.h linux-2.4.30-brcm/ar
 +#define       CC_CLOCK_BASE   24000000        /* Half the clock freq. in the 4710 */
 +
 +#endif        /* _SBEXTIF_H */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbmemc.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbmemc.h
---- linux-2.4.30/arch/mips/bcm947xx/include/sbmemc.h   1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbmemc.h      2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/sbmemc.h linux.dev/arch/mips/bcm947xx/include/sbmemc.h
+--- linux.old/arch/mips/bcm947xx/include/sbmemc.h      1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/sbmemc.h      2005-08-26 13:44:34.300393344 +0200
 @@ -0,0 +1,147 @@
 +/*
 + * BCM47XX Sonics SiliconBackplane DDR/SDRAM controller core hardware definitions.
@@ -7292,9 +7453,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbmemc.h linux-2.4.30-brcm/arc
 +#define MEMC_CONFIG_DDR               0x00000001
 +
 +#endif        /* _SBMEMC_H */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbmips.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbmips.h
---- linux-2.4.30/arch/mips/bcm947xx/include/sbmips.h   1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbmips.h      2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/sbmips.h linux.dev/arch/mips/bcm947xx/include/sbmips.h
+--- linux.old/arch/mips/bcm947xx/include/sbmips.h      1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/sbmips.h      2005-08-26 13:44:34.301393192 +0200
 @@ -0,0 +1,60 @@
 +/*
 + * Broadcom SiliconBackplane MIPS definitions
@@ -7356,9 +7517,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbmips.h linux-2.4.30-brcm/arc
 +#endif /* _LANGUAGE_ASSEMBLY */
 +
 +#endif        /* _SBMIPS_H */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbpci.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbpci.h
---- linux-2.4.30/arch/mips/bcm947xx/include/sbpci.h    1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbpci.h       2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/sbpci.h linux.dev/arch/mips/bcm947xx/include/sbpci.h
+--- linux.old/arch/mips/bcm947xx/include/sbpci.h       1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/sbpci.h       2005-08-26 13:44:34.301393192 +0200
 @@ -0,0 +1,117 @@
 +/*
 + * BCM47XX Sonics SiliconBackplane PCI core hardware definitions.
@@ -7477,9 +7638,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbpci.h linux-2.4.30-brcm/arch
 +#endif /* !_LANGUAGE_ASSEMBLY */
 +
 +#endif        /* _SBPCI_H */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbpcmcia.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbpcmcia.h
---- linux-2.4.30/arch/mips/bcm947xx/include/sbpcmcia.h 1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbpcmcia.h    2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/sbpcmcia.h linux.dev/arch/mips/bcm947xx/include/sbpcmcia.h
+--- linux.old/arch/mips/bcm947xx/include/sbpcmcia.h    1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/sbpcmcia.h    2005-08-26 13:44:34.302393040 +0200
 @@ -0,0 +1,139 @@
 +/*
 + * BCM43XX Sonics SiliconBackplane PCMCIA core hardware definitions.
@@ -7620,9 +7781,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbpcmcia.h linux-2.4.30-brcm/a
 +#define SBTMH_INT_STATUS      0x40000         /* sb interrupt status */
 +
 +#endif        /* _SBPCMCIA_H */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbsdram.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbsdram.h
---- linux-2.4.30/arch/mips/bcm947xx/include/sbsdram.h  1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbsdram.h     2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/sbsdram.h linux.dev/arch/mips/bcm947xx/include/sbsdram.h
+--- linux.old/arch/mips/bcm947xx/include/sbsdram.h     1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/sbsdram.h     2005-08-26 13:44:34.302393040 +0200
 @@ -0,0 +1,75 @@
 +/*
 + * BCM47XX Sonics SiliconBackplane SDRAM controller core hardware definitions.
@@ -7699,9 +7860,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbsdram.h linux-2.4.30-brcm/ar
 +#define MEM8MX16X2    0xc29   /* 32 MB */
 +
 +#endif        /* _SBSDRAM_H */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbsocram.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbsocram.h
---- linux-2.4.30/arch/mips/bcm947xx/include/sbsocram.h 1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbsocram.h    2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/sbsocram.h linux.dev/arch/mips/bcm947xx/include/sbsocram.h
+--- linux.old/arch/mips/bcm947xx/include/sbsocram.h    1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/sbsocram.h    2005-08-26 13:44:34.303392888 +0200
 @@ -0,0 +1,37 @@
 +/*
 + * BCM47XX Sonics SiliconBackplane embedded ram core
@@ -7740,9 +7901,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbsocram.h linux-2.4.30-brcm/a
 +#define SOCRAM_MEMSIZE_BASESHIFT 16
 +
 +#endif        /* _SBSOCRAM_H */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbutils.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbutils.h
---- linux-2.4.30/arch/mips/bcm947xx/include/sbutils.h  1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/sbutils.h     2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/sbutils.h linux.dev/arch/mips/bcm947xx/include/sbutils.h
+--- linux.old/arch/mips/bcm947xx/include/sbutils.h     1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/sbutils.h     2005-08-26 13:44:34.303392888 +0200
 @@ -0,0 +1,87 @@
 +/*
 + * Misc utility routines for accessing chip-specific features
@@ -7831,9 +7992,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sbutils.h linux-2.4.30-brcm/ar
 +#define       CLK_DYNAMIC     2                       /* enable dynamic power control */
 +
 +#endif        /* _sbutils_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sflash.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/sflash.h
---- linux-2.4.30/arch/mips/bcm947xx/include/sflash.h   1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/sflash.h      2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/sflash.h linux.dev/arch/mips/bcm947xx/include/sflash.h
+--- linux.old/arch/mips/bcm947xx/include/sflash.h      1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/sflash.h      2005-08-26 13:44:34.304392736 +0200
 @@ -0,0 +1,36 @@
 +/*
 + * Broadcom SiliconBackplane chipcommon serial flash interface
@@ -7871,9 +8032,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/sflash.h linux-2.4.30-brcm/arc
 +extern struct sflash * sflash_init(chipcregs_t *cc);
 +
 +#endif /* _sflash_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/trxhdr.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/trxhdr.h
---- linux-2.4.30/arch/mips/bcm947xx/include/trxhdr.h   1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/trxhdr.h      2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/trxhdr.h linux.dev/arch/mips/bcm947xx/include/trxhdr.h
+--- linux.old/arch/mips/bcm947xx/include/trxhdr.h      1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/trxhdr.h      2005-08-26 13:44:34.304392736 +0200
 @@ -0,0 +1,33 @@
 +/*
 + * TRX image file header format.
@@ -7908,9 +8069,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/trxhdr.h linux-2.4.30-brcm/arc
 +
 +/* Compatibility */
 +typedef struct trx_header TRXHDR, *PTRXHDR;
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/typedefs.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/typedefs.h
---- linux-2.4.30/arch/mips/bcm947xx/include/typedefs.h 1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/typedefs.h    2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/typedefs.h linux.dev/arch/mips/bcm947xx/include/typedefs.h
+--- linux.old/arch/mips/bcm947xx/include/typedefs.h    1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/typedefs.h    2005-08-26 13:44:34.305392584 +0200
 @@ -0,0 +1,322 @@
 +/*
 + * Copyright 2005, Broadcom Corporation      
@@ -8234,9 +8395,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/typedefs.h linux-2.4.30-brcm/a
 +#endif /* USE_TYPEDEF_DEFAULTS */
 +
 +#endif /* _TYPEDEFS_H_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/wlioctl.h linux-2.4.30-brcm/arch/mips/bcm947xx/include/wlioctl.h
---- linux-2.4.30/arch/mips/bcm947xx/include/wlioctl.h  1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/include/wlioctl.h     2005-02-02 23:16:40.000000000 +0100
+diff -urN linux.old/arch/mips/bcm947xx/include/wlioctl.h linux.dev/arch/mips/bcm947xx/include/wlioctl.h
+--- linux.old/arch/mips/bcm947xx/include/wlioctl.h     1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/include/wlioctl.h     2005-08-26 13:44:34.307392280 +0200
 @@ -0,0 +1,825 @@
 +/*
 + * Custom OID/ioctl definitions for
@@ -9063,28 +9224,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/include/wlioctl.h linux-2.4.30-brcm/ar
 +#endif
 +
 +#endif /* _wlioctl_h_ */
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/Makefile linux-2.4.30-brcm/arch/mips/bcm947xx/Makefile
---- linux-2.4.30/arch/mips/bcm947xx/Makefile   1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/Makefile      2005-05-26 15:07:37.000000000 +0200
-@@ -0,0 +1,15 @@
-+#
-+# Makefile for the BCM947xx specific kernel interface routines
-+# under Linux.
-+#
-+
-+EXTRA_CFLAGS+=-I$(TOPDIR)/arch/mips/bcm947xx/include -DBCMDRIVER
-+
-+O_TARGET        := bcm947xx.o
-+
-+export-objs     := nvram_linux.o setup.o
-+obj-y         := prom.o setup.o time.o sbmips.o gpio.o
-+obj-y         += nvram.o nvram_linux.o
-+obj-$(CONFIG_PCI) += sbpci.o pcibios.o
-+
-+include $(TOPDIR)/Rules.make
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/nvram.c linux-2.4.30-brcm/arch/mips/bcm947xx/nvram.c
---- linux-2.4.30/arch/mips/bcm947xx/nvram.c    1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/nvram.c       2005-05-24 17:58:29.000000000 +0200
+diff -urN linux.old/arch/mips/bcm947xx/nvram.c linux.dev/arch/mips/bcm947xx/nvram.c
+--- linux.old/arch/mips/bcm947xx/nvram.c       1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/nvram.c       2005-08-26 13:44:34.307392280 +0200
 @@ -0,0 +1,321 @@
 +/*
 + * NVRAM variable manipulation (common)
@@ -9407,9 +9549,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/nvram.c linux-2.4.30-brcm/arch/mips/bc
 +{
 +      BCMINIT(nvram_free)();
 +}
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/nvram_linux.c linux-2.4.30-brcm/arch/mips/bcm947xx/nvram_linux.c
---- linux-2.4.30/arch/mips/bcm947xx/nvram_linux.c      1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/nvram_linux.c 2005-05-25 20:02:50.000000000 +0200
+diff -urN linux.old/arch/mips/bcm947xx/nvram_linux.c linux.dev/arch/mips/bcm947xx/nvram_linux.c
+--- linux.old/arch/mips/bcm947xx/nvram_linux.c 1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/nvram_linux.c 2005-08-26 13:44:34.308392128 +0200
 @@ -0,0 +1,617 @@
 +/*
 + * NVRAM variable manipulation (Linux kernel half)
@@ -10028,9 +10170,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/nvram_linux.c linux-2.4.30-brcm/arch/m
 +
 +module_init(dev_nvram_init);
 +module_exit(dev_nvram_exit);
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/pcibios.c linux-2.4.30-brcm/arch/mips/bcm947xx/pcibios.c
---- linux-2.4.30/arch/mips/bcm947xx/pcibios.c  1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/pcibios.c     2005-05-26 01:15:53.000000000 +0200
+diff -urN linux.old/arch/mips/bcm947xx/pcibios.c linux.dev/arch/mips/bcm947xx/pcibios.c
+--- linux.old/arch/mips/bcm947xx/pcibios.c     1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/pcibios.c     2005-08-26 13:44:34.309391976 +0200
 @@ -0,0 +1,355 @@
 +/*
 + * Low-Level PCI and SB support for BCM47xx (Linux support code)
@@ -10387,9 +10529,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/pcibios.c linux-2.4.30-brcm/arch/mips/
 +      pci_write_config_byte(dev, PCI_LATENCY_TIMER, lat);
 +}
 +
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/prom.c linux-2.4.30-brcm/arch/mips/bcm947xx/prom.c
---- linux-2.4.30/arch/mips/bcm947xx/prom.c     1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/prom.c        2005-05-22 22:55:51.000000000 +0200
+diff -urN linux.old/arch/mips/bcm947xx/prom.c linux.dev/arch/mips/bcm947xx/prom.c
+--- linux.old/arch/mips/bcm947xx/prom.c        1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/prom.c        2005-08-26 13:44:34.310391824 +0200
 @@ -0,0 +1,41 @@
 +/*
 + * Early initialization code for BCM94710 boards
@@ -10432,14 +10574,14 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/prom.c linux-2.4.30-brcm/arch/mips/bcm
 +prom_free_prom_memory(void)
 +{
 +}
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbmips.c linux-2.4.30-brcm/arch/mips/bcm947xx/sbmips.c
---- linux-2.4.30/arch/mips/bcm947xx/sbmips.c   1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/sbmips.c      2005-05-25 05:06:08.000000000 +0200
-@@ -0,0 +1,982 @@
+diff -urN linux.old/arch/mips/bcm947xx/sbmips.c linux.dev/arch/mips/bcm947xx/sbmips.c
+--- linux.old/arch/mips/bcm947xx/sbmips.c      1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/sbmips.c      2005-09-01 01:30:26.074176728 +0200
+@@ -0,0 +1,1033 @@
 +/*
 + * BCM47XX Sonics SiliconBackplane MIPS core routines
 + *
-+ * Copyright 2004, Broadcom Corporation
++ * Copyright 2005, Broadcom Corporation
 + * All Rights Reserved.
 + * 
 + * THIS SOFTWARE IS OFFERED "AS IS", AND BROADCOM GRANTS NO WARRANTIES OF ANY
@@ -10447,7 +10589,7 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbmips.c linux-2.4.30-brcm/arch/mips/b
 + * SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS
 + * FOR A SPECIFIC PURPOSE OR NONINFRINGEMENT CONCERNING THIS SOFTWARE.
 + *
-+ * $Id$
++ * $Id: sbmips.c,v 1.3 2005/03/07 08:35:32 kanki Exp $
 + */
 +
 +#include <typedefs.h>
@@ -10541,32 +10683,34 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbmips.c linux-2.4.30-brcm/arch/mips/b
 +                                                R_REG(&cc->clockcontrol_n),
 +                                                R_REG(&cc->clockcontrol_m2));
 +                      div = 1;
-+              } else if (rev >= 3) {
-+                      if (pll == PLL_TYPE6) {
-+                              /* Fixed ALP clock on 4320 */
++              } else {
++                      if (rev >= 11) {
++                              /* Fixed ALP clock */
 +                              baud_base = 20000000;
++                              div = 1;
 +                              /* Set the override bit so we don't divide it */
 +                              W_REG(&cc->corecontrol, CC_UARTCLKO);
-+                      } else {
++                      } else if (rev >= 3) {
 +                              /* Internal backplane clock */
 +                              baud_base = sb_clock(sbh);
++                              div = 2;        /* Minimum divisor */
++                              W_REG(&cc->clkdiv, ((R_REG(&cc->clkdiv) & ~CLKD_UART) | div));
++                      } else {
++                              /* Fixed internal backplane clock */
++                              baud_base = 88000000;
++                              div = 48;
 +                      }
-+                      div = 2;        /* Minimum divisor */
-+                      W_REG(&cc->clkdiv, ((R_REG(&cc->clkdiv) & ~CLKD_UART) | div));
-+              } else {
-+                      /* Fixed internal backplane clock */
-+                      baud_base = 88000000;
-+                      div = 48;
-+              }
 +
-+              /* Clock source depends on strapping if UartClkOverride is unset */
-+              if ((rev > 0) && ((R_REG(&cc->corecontrol) & CC_UARTCLKO) == 0)) {
-+                      if ((cap & CAP_UCLKSEL) == CAP_UINTCLK) {
-+                              /* Internal divided backplane clock */
-+                              baud_base /= div;
-+                      } else {
-+                              /* Assume external clock of 1.8432 MHz */
-+                              baud_base = 1843200;
++                      /* Clock source depends on strapping if UartClkOverride is unset */
++                      if ((rev > 0) &&
++                          ((R_REG(&cc->corecontrol) & CC_UARTCLKO) == 0)) {
++                              if ((cap & CAP_UCLKSEL) == CAP_UINTCLK) {
++                                      /* Internal divided backplane clock */
++                                      baud_base /= div;
++                              } else {
++                                      /* Assume external clock of 1.8432 MHz */
++                                      baud_base = 1843200;
++                              }
 +                      }
 +              }
 +
@@ -10815,6 +10959,14 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbmips.c linux-2.4.30-brcm/arch/mips/b
 +              tmp = tmp | CEIL(120, ns);              /* W0 = 120nS */
 +              W_REG(&eir->prog_waitcount, tmp);       /* 0x01020a0c for a 100Mhz clock */
 +      } else if ((cc = sb_setcore(sbh, SB_CC, 0))) {
++//==================================tallest===============================================
++              /* set register for external IO to control LED. */
++                W_REG(&cc->prog_config, 0x11);
++                tmp = CEIL(10, ns) << FW_W3_SHIFT;      /* W3 = 10nS */
++                tmp = tmp | (CEIL(40, ns) << FW_W1_SHIFT); /* W1 = 40nS */
++                tmp = tmp | CEIL(240, ns);              /* W0 = 120nS */
++                W_REG(&cc->prog_waitcount, tmp);        /* 0x01020a0c for a 100Mhz clock */
++//========================================================================================
 +              /* Set timing for the flash */
 +              tmp = CEIL(10, ns) << FW_W3_SHIFT;      /* W3 = 10nS */
 +              tmp |= CEIL(10, ns) << FW_W1_SHIFT;     /* W1 = 10nS */
@@ -10917,7 +11069,8 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbmips.c linux-2.4.30-brcm/arch/mips/b
 +              n = R_REG(&cc->clockcontrol_n);
 +              if ((pll_type == PLL_TYPE2) ||
 +                  (pll_type == PLL_TYPE4) ||
-+                  (pll_type == PLL_TYPE6))
++                  (pll_type == PLL_TYPE6) ||
++                  (pll_type == PLL_TYPE7))
 +                      m = R_REG(&cc->clockcontrol_mips);
 +              else if (pll_type == PLL_TYPE5) {
 +                      rate = 200000000;
@@ -10991,7 +11144,7 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbmips.c linux-2.4.30-brcm/arch/mips/b
 +      chipcregs_t *cc = NULL;
 +      mipsregs_t *mipsr = NULL;
 +      volatile uint32 *clockcontrol_n, *clockcontrol_sb, *clockcontrol_pci, *clockcontrol_m2;
-+      uint32 orig_n, orig_sb, orig_pci, orig_m2, orig_mips, orig_ratio_parm, new_ratio;
++      uint32 orig_n, orig_sb, orig_pci, orig_m2, orig_mips, orig_ratio_parm, orig_ratio_cfg;
 +      uint32 pll_type, sync_mode;
 +      uint ic_size, ic_lsize;
 +      uint idx, i;
@@ -11031,7 +11184,6 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbmips.c linux-2.4.30-brcm/arch/mips/b
 +      } type3_table_t;
 +      static type3_table_t type3_table[] = { /* for 5350, mips clock is always double sb clock */
 +              { 150000000, 0x311, 0x4020005 }, 
-+//            { 180000000, 0x, 0x },  /* later we may want this frequency */
 +              { 200000000, 0x311, 0x4020003 }, 
 +      };
 +      typedef struct {
@@ -11042,44 +11194,70 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbmips.c linux-2.4.30-brcm/arch/mips/b
 +              uint32 pci33;
 +              uint32 m2;
 +              uint32 m3;
-+              uint32 ratio;
++              uint32 ratio_cfg;
 +              uint32 ratio_parm;
 +      } n4m_table_t;
 +
 +      static n4m_table_t BCMINITDATA(type2_table)[] = {
-+              { 180000000,  80000000, 0x0403, 0x01010000, 0x01020300, 0x01020600, 0x05000100, 0x94, 0x012a00a9 },
-+              { 180000000,  90000000, 0x0403, 0x01000100, 0x01020300, 0x01000100, 0x05000100, 0x21, 0x0aaa0555 },
-+              { 200000000, 100000000, 0x0303, 0x01000000, 0x01000600, 0x01000000, 0x05000000, 0x21, 0x0aaa0555 },
-+              { 211200000, 105600000, 0x0902, 0x01000200, 0x01030400, 0x01000200, 0x05000200, 0x21, 0x0aaa0555 },
-+              { 220800000, 110400000, 0x1500, 0x01000200, 0x01030400, 0x01000200, 0x05000200, 0x21, 0x0aaa0555 },
-+              { 230400000, 115200000, 0x0604, 0x01000200, 0x01020600, 0x01000200, 0x05000200, 0x21, 0x0aaa0555 },
-+              { 234000000, 104000000, 0x0b01, 0x01010000, 0x01010700, 0x01020600, 0x05000100, 0x94, 0x012a00a9 },
-+              { 240000000, 120000000, 0x0803, 0x01000200, 0x01020600, 0x01000200, 0x05000200, 0x21, 0x0aaa0555 },
-+              { 252000000, 126000000, 0x0504, 0x01000100, 0x01020500, 0x01000100, 0x05000100, 0x21, 0x0aaa0555 },
-+              { 264000000, 132000000, 0x0903, 0x01000200, 0x01020700, 0x01000200, 0x05000200, 0x21, 0x0aaa0555 },
-+              { 270000000, 120000000, 0x0703, 0x01010000, 0x01030400, 0x01020600, 0x05000100, 0x94, 0x012a00a9 },
-+              { 276000000, 122666666, 0x1500, 0x01010000, 0x01030400, 0x01020600, 0x05000100, 0x94, 0x012a00a9 },
-+              { 280000000, 140000000, 0x0503, 0x01000000, 0x01010600, 0x01000000, 0x05000000, 0x21, 0x0aaa0555 },
-+              { 288000000, 128000000, 0x0604, 0x01010000, 0x01030400, 0x01020600, 0x05000100, 0x94, 0x012a00a9 },
-+              { 288000000, 144000000, 0x0404, 0x01000000, 0x01010600, 0x01000000, 0x05000000, 0x21, 0x0aaa0555 },
-+              { 300000000, 133333333, 0x0803, 0x01010000, 0x01020600, 0x01020600, 0x05000100, 0x94, 0x012a00a9 },
-+              { 300000000, 150000000, 0x0803, 0x01000100, 0x01020600, 0x01000100, 0x05000100, 0x21, 0x0aaa0555 }
++              { 180000000,  80000000, 0x0403, 0x01010000, 0x01020300, 0x01020600, 0x05000100,  8, 0x012a00a9 },
++              { 180000000,  90000000, 0x0403, 0x01000100, 0x01020300, 0x01000100, 0x05000100, 11, 0x0aaa0555 },
++              { 200000000, 100000000, 0x0303, 0x02010000, 0x02040001, 0x02010000, 0x06000001, 11, 0x0aaa0555 },
++              { 211200000, 105600000, 0x0902, 0x01000200, 0x01030400, 0x01000200, 0x05000200, 11, 0x0aaa0555 },
++              { 220800000, 110400000, 0x1500, 0x01000200, 0x01030400, 0x01000200, 0x05000200, 11, 0x0aaa0555 },
++              { 230400000, 115200000, 0x0604, 0x01000200, 0x01020600, 0x01000200, 0x05000200, 11, 0x0aaa0555 },
++              { 234000000, 104000000, 0x0b01, 0x01010000, 0x01010700, 0x01020600, 0x05000100,  8, 0x012a00a9 },
++              { 240000000, 120000000, 0x0803, 0x01000200, 0x01020600, 0x01000200, 0x05000200, 11, 0x0aaa0555 },
++              { 252000000, 126000000, 0x0504, 0x01000100, 0x01020500, 0x01000100, 0x05000100, 11, 0x0aaa0555 },
++              { 264000000, 132000000, 0x0903, 0x01000200, 0x01020700, 0x01000200, 0x05000200, 11, 0x0aaa0555 },
++              { 270000000, 120000000, 0x0703, 0x01010000, 0x01030400, 0x01020600, 0x05000100,  8, 0x012a00a9 },
++              { 276000000, 122666666, 0x1500, 0x01010000, 0x01030400, 0x01020600, 0x05000100,  8, 0x012a00a9 },
++              { 280000000, 140000000, 0x0503, 0x01000000, 0x01010600, 0x01000000, 0x05000000, 11, 0x0aaa0555 },
++              { 288000000, 128000000, 0x0604, 0x01010000, 0x01030400, 0x01020600, 0x05000100,  8, 0x012a00a9 },
++              { 288000000, 144000000, 0x0404, 0x01000000, 0x01010600, 0x01000000, 0x05000000, 11, 0x0aaa0555 },
++              { 300000000, 133333333, 0x0803, 0x01010000, 0x01020600, 0x01020600, 0x05000100,  8, 0x012a00a9 },
++              { 300000000, 150000000, 0x0803, 0x01000100, 0x01020600, 0x01000100, 0x05000100, 11, 0x0aaa0555 }
 +      };
 +
 +      static n4m_table_t BCMINITDATA(type4_table)[] = {
-+              { 192000000,  96000000, 0x0702, 0x04020011, 0x11030011, 0x04020011, 0x04020003, 0x21, 0x0aaa0555 },
-+              { 200000000, 100000000, 0x0009, 0x04020011, 0x11030011, 0x04020011, 0x04020003, 0x21, 0x0aaa0555 },
-+              { 216000000, 108000000, 0x0111, 0x11020005, 0x01030303, 0x11020005, 0x04000005, 0x21, 0x0aaa0555 },
-+              { 228000000, 101333333, 0x0e02, 0x11030003, 0x11210005, 0x11030305, 0x04000005, 0x94, 0x012a00a9 },
-+              { 228000000, 114000000, 0x0e02, 0x11020005, 0x11210005, 0x11020005, 0x04000005, 0x21, 0x0aaa0555 },
-+              { 240000000, 120000000, 0x0109, 0x11030002, 0x01050203, 0x11030002, 0x04000003, 0x21, 0x0aaa0555 },
-+              { 252000000, 126000000, 0x0203, 0x04000005, 0x11050005, 0x04000005, 0x04000002, 0x21, 0x0aaa0555 },
-+              { 264000000, 132000000, 0x0602, 0x04000005, 0x11050005, 0x04000005, 0x04000002, 0x21, 0x0aaa0555 },
-+              { 272000000, 116571428, 0x0c02, 0x04000021, 0x02000909, 0x02000221, 0x04000003, 0x73, 0x254a14a9 },
-+              { 280000000, 120000000, 0x0209, 0x04000021, 0x01030303, 0x02000221, 0x04000003, 0x73, 0x254a14a9 },
-+              { 288000000, 123428571, 0x0111, 0x04000021, 0x01030303, 0x02000221, 0x04000003, 0x73, 0x254a14a9 },
-+              { 300000000, 120000000, 0x0009, 0x04000009, 0x01030203, 0x02000902, 0x04000002, 0x52, 0x02520129 }
++              { 192000000,  96000000, 0x0702, 0x04000011, 0x11030011, 0x04000011, 0x04000003, 11, 0x0aaa0555 },
++              { 198000000,  99000000, 0x0603, 0x11020005, 0x11030011, 0x11020005, 0x04000005, 11, 0x0aaa0555 },
++              { 200000000, 100000000, 0x0009, 0x04020011, 0x11030011, 0x04020011, 0x04020003, 11, 0x0aaa0555 },
++              { 204000000, 102000000, 0x0c02, 0x11020005, 0x01030303, 0x11020005, 0x04000005, 11, 0x0aaa0555 },
++              { 208000000, 104000000, 0x0802, 0x11030002, 0x11090005, 0x11030002, 0x04000003, 11, 0x0aaa0555 },
++              { 210000000, 105000000, 0x0209, 0x11020005, 0x01030303, 0x11020005, 0x04000005, 11, 0x0aaa0555 },
++              { 216000000, 108000000, 0x0111, 0x11020005, 0x01030303, 0x11020005, 0x04000005, 11, 0x0aaa0555 },
++              { 224000000, 112000000, 0x0205, 0x11030002, 0x02002103, 0x11030002, 0x04000003, 11, 0x0aaa0555 },
++              { 228000000, 101333333, 0x0e02, 0x11030003, 0x11210005, 0x01030305, 0x04000005,  8, 0x012a00a9 },
++              { 228000000, 114000000, 0x0e02, 0x11020005, 0x11210005, 0x11020005, 0x04000005, 11, 0x0aaa0555 },
++              { 240000000, 102857143, 0x0109, 0x04000021, 0x01050203, 0x11030021, 0x04000003, 13, 0x254a14a9 },
++              { 240000000, 120000000, 0x0109, 0x11030002, 0x01050203, 0x11030002, 0x04000003, 11, 0x0aaa0555 },
++              { 252000000, 100800000, 0x0203, 0x04000009, 0x11050005, 0x02000209, 0x04000002,  9, 0x02520129 },
++              { 252000000, 126000000, 0x0203, 0x04000005, 0x11050005, 0x04000005, 0x04000002, 11, 0x0aaa0555 },
++              { 264000000, 132000000, 0x0602, 0x04000005, 0x11050005, 0x04000005, 0x04000002, 11, 0x0aaa0555 },
++              { 272000000, 116571428, 0x0c02, 0x04000021, 0x02000909, 0x02000221, 0x04000003, 13, 0x254a14a9 },
++              { 280000000, 120000000, 0x0209, 0x04000021, 0x01030303, 0x02000221, 0x04000003, 13, 0x254a14a9 },
++              { 288000000, 123428571, 0x0111, 0x04000021, 0x01030303, 0x02000221, 0x04000003, 13, 0x254a14a9 },
++              { 300000000, 120000000, 0x0009, 0x04000009, 0x01030203, 0x02000902, 0x04000002,  9, 0x02520129 },
++              { 300000000, 150000000, 0x0009, 0x04000005, 0x01030203, 0x04000005, 0x04000002, 11, 0x0aaa0555 }
++      };
++
++      static n4m_table_t BCMINITDATA(type7_table)[] = {
++              { 183333333,  91666666, 0x0605, 0x04000011, 0x11030011, 0x04000011, 0x04000003, 11, 0x0aaa0555 },
++              { 187500000,  93750000, 0x0a03, 0x04000011, 0x11030011, 0x04000011, 0x04000003, 11, 0x0aaa0555 },
++              { 196875000,  98437500, 0x1003, 0x11020005, 0x11050011, 0x11020005, 0x04000005, 11, 0x0aaa0555 },
++              { 200000000, 100000000, 0x0311, 0x04000011, 0x11030011, 0x04000009, 0x04000003, 11, 0x0aaa0555 },
++              { 200000000, 100000000, 0x0311, 0x04020011, 0x11030011, 0x04020011, 0x04020003, 11, 0x0aaa0555 },
++              { 206250000, 103125000, 0x1103, 0x11020005, 0x11050011, 0x11020005, 0x04000005, 11, 0x0aaa0555 },
++              { 212500000, 106250000, 0x0c05, 0x11020005, 0x01030303, 0x11020005, 0x04000005, 11, 0x0aaa0555 },
++              { 215625000, 107812500, 0x1203, 0x11090009, 0x11050005, 0x11020005, 0x04000005, 11, 0x0aaa0555 },
++              { 216666666, 108333333, 0x0805, 0x11020003, 0x11030011, 0x11020003, 0x04000003, 11, 0x0aaa0555 },
++              { 225000000, 112500000, 0x0d03, 0x11020003, 0x11030011, 0x11020003, 0x04000003, 11, 0x0aaa0555 },
++              { 233333333, 116666666, 0x0905, 0x11020003, 0x11030011, 0x11020003, 0x04000003, 11, 0x0aaa0555 },
++              { 237500000, 118750000, 0x0e05, 0x11020005, 0x11210005, 0x11020005, 0x04000005, 11, 0x0aaa0555 },
++              { 240000000, 120000000, 0x0b11, 0x11020009, 0x11210009, 0x11020009, 0x04000009, 11, 0x0aaa0555 },
++              { 250000000, 125000000, 0x0f03, 0x11020003, 0x11210003, 0x11020003, 0x04000003, 11, 0x0aaa0555 }
 +      };
++
 +      ulong start, end, dst;
 +      bool ret = FALSE;
 +      
@@ -11194,8 +11372,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbmips.c linux-2.4.30-brcm/arch/mips/b
 +              while (1);
 +      } else if ((pll_type == PLL_TYPE2) ||
 +                 (pll_type == PLL_TYPE4) ||
-+                 (pll_type == PLL_TYPE6)) {
-+              n4m_table_t *table = NULL;
++                 (pll_type == PLL_TYPE6) ||
++                 (pll_type == PLL_TYPE7)) {
++              n4m_table_t *table = NULL, *te;
 +              uint tabsz = 0;
 +
 +              ASSERT(cc);
@@ -11216,13 +11395,22 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbmips.c linux-2.4.30-brcm/arch/mips/b
 +                      goto end_fill;
 +              }
 +
-+              table = (pll_type == PLL_TYPE2) ? BCMINIT(type2_table) : BCMINIT(type4_table);
-+              tabsz = (pll_type == PLL_TYPE2) ? ARRAYSIZE(BCMINIT(type2_table)) :
-+                      ARRAYSIZE(BCMINIT(type4_table));
++              if (pll_type == PLL_TYPE2) {
++                      table = BCMINIT(type2_table);
++                      tabsz = ARRAYSIZE(BCMINIT(type2_table));
++              } else if (pll_type == PLL_TYPE4) {
++                      table = BCMINIT(type4_table);
++                      tabsz = ARRAYSIZE(BCMINIT(type4_table));
++              } else if (pll_type == PLL_TYPE7) {
++                      table = BCMINIT(type7_table);
++                      tabsz = ARRAYSIZE(BCMINIT(type7_table));
++              } else
++                      ASSERT((char *)"No table for plltype" == NULL);
 +
 +              /* Store the current clock register values */
 +              orig_m2 = R_REG(&cc->clockcontrol_m2);
 +              orig_ratio_parm = 0;
++              orig_ratio_cfg = 0;
 +
 +              /* Look up current ratio */
 +              for (i = 0; i < tabsz; i++) {
@@ -11232,6 +11420,7 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbmips.c linux-2.4.30-brcm/arch/mips/b
 +                          (orig_m2 == table[i].m2) &&
 +                          (orig_mips == table[i].m3)) {
 +                              orig_ratio_parm = table[i].ratio_parm;
++                              orig_ratio_cfg = table[i].ratio_cfg;
 +                              break;
 +                      }
 +              }
@@ -11248,30 +11437,35 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbmips.c linux-2.4.30-brcm/arch/mips/b
 +                      ret = FALSE;
 +                      goto done;
 +              } else {
++                      te = &table[i];
 +                      ret = TRUE;
 +              }
 +
 +              /* No PLL change */
-+              if ((orig_n == table[i].n) &&
-+                  (orig_sb == table[i].sb) &&
-+                  (orig_pci == table[i].pci33) &&
-+                  (orig_m2 == table[i].m2) &&
-+                  (orig_mips == table[i].m3))
++              if ((orig_n == te->n) &&
++                  (orig_sb == te->sb) &&
++                  (orig_pci == te->pci33) &&
++                  (orig_m2 == te->m2) &&
++                  (orig_mips == te->m3))
 +                      goto done;
 +
 +              /* Set the PLL controls */
-+              W_REG(clockcontrol_n, table[i].n);
-+              W_REG(clockcontrol_sb, table[i].sb);
-+              W_REG(clockcontrol_pci, table[i].pci33);
-+              W_REG(&cc->clockcontrol_m2, table[i].m2);
-+              W_REG(&cc->clockcontrol_mips, table[i].m3);
++              W_REG(clockcontrol_n, te->n);
++              W_REG(clockcontrol_sb, te->sb);
++              W_REG(clockcontrol_pci, te->pci33);
++              W_REG(&cc->clockcontrol_m2, te->m2);
++              W_REG(&cc->clockcontrol_mips, te->m3);
++
++              /* Set the chipcontrol bit to change mipsref to the backplane divider if needed */
++              if ((pll_type == PLL_TYPE7) &&
++                  (te->sb != te->m2) &&
++                  (sb_clock_rate(pll_type, te->n, te->m2) == 120000000))
++                      W_REG(&cc->chipcontrol, R_REG(&cc->chipcontrol) | 0x100);
 +
 +              /* No ratio change */
-+              if (orig_ratio_parm == table[i].ratio_parm)
++              if (orig_ratio_parm == te->ratio_parm)
 +                      goto end_fill;
 +
-+              new_ratio = table[i].ratio_parm;
-+
 +              icache_probe(MFC0(C0_CONFIG, 1), &ic_size, &ic_lsize);
 +
 +              /* Preload the code into the cache */
@@ -11307,8 +11501,8 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbmips.c linux-2.4.30-brcm/arch/mips/b
 +
 +      start_fill:
 +              /* step 1, set clock ratios */
-+              MTC0(C0_BROADCOM, 3, new_ratio);
-+              MTC0(C0_BROADCOM, 1, 8);
++              MTC0(C0_BROADCOM, 3, te->ratio_parm);
++              MTC0(C0_BROADCOM, 1, te->ratio_cfg);
 +
 +              /* step 2: program timer intr */
 +              W_REG(&mipsr->timer, 100);
@@ -11391,8 +11585,7 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbmips.c linux-2.4.30-brcm/arch/mips/b
 +      if (config & MEMC_CONFIG_DDR) {
 +              ret = (wr << 16) | (rd << 8) | dqsg;
 +      } else {
-+              if ( (rev > 0)  || (sb_chip(sbh) == BCM5365_DEVICE_ID))
-+
++              if ((rev > 0) || (sb_chip(sbh) == BCM5365_DEVICE_ID))
 +                      cd = rd;
 +              else
 +                      cd = (rd == MEMC_CD_THRESHOLD) ? rd : (wr + MEMC_CD_THRESHOLD);
@@ -11418,14 +11611,14 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbmips.c linux-2.4.30-brcm/arch/mips/b
 +      else 
 +              return 0x15;
 +}
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbpci.c linux-2.4.30-brcm/arch/mips/bcm947xx/sbpci.c
---- linux-2.4.30/arch/mips/bcm947xx/sbpci.c    1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/sbpci.c       2005-05-26 21:56:08.000000000 +0200
-@@ -0,0 +1,569 @@
+diff -urN linux.old/arch/mips/bcm947xx/sbpci.c linux.dev/arch/mips/bcm947xx/sbpci.c
+--- linux.old/arch/mips/bcm947xx/sbpci.c       1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/sbpci.c       2005-08-26 13:44:34.313391368 +0200
+@@ -0,0 +1,588 @@
 +/*
 + * Low-Level PCI and SB support for BCM47xx
 + *
-+ * Copyright 2004, Broadcom Corporation
++ * Copyright 2005, Broadcom Corporation
 + * All Rights Reserved.
 + * 
 + * THIS SOFTWARE IS OFFERED "AS IS", AND BROADCOM GRANTS NO WARRANTIES OF ANY
@@ -11433,7 +11626,7 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbpci.c linux-2.4.30-brcm/arch/mips/bc
 + * SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS
 + * FOR A SPECIFIC PURPOSE OR NONINFRINGEMENT CONCERNING THIS SOFTWARE.
 + *
-+ * $Id$
++ * $Id: sbpci.c,v 1.7 2005/03/07 08:35:32 kanki Exp $
 + */
 +
 +#include <typedefs.h>
@@ -11670,40 +11863,27 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbpci.c linux-2.4.30-brcm/arch/mips/bc
 +              pci_ban[pci_banned++] = core;
 +}
 +
-+int __init
-+sbpci_init(void *sbh)
++static int
++sbpci_init_pci(void *sbh)
 +{
-+      uint chip, chiprev, chippkg, coreidx, host, i;
++      uint chip, chiprev, chippkg, host;
 +      uint32 boardflags;
 +      sbpciregs_t *pci;
 +      sbconfig_t *sb;
-+      pci_config_regs *cfg;
-+      void *regs;
-+      char varname[8];
 +      int CT4712_WR;
-+      uint wlidx = 0;
-+      uint16 vendor, core;
-+      uint8 class, subclass, progif;
 +      uint32 val;
-+      uint32 sbips_int_mask[] = { 0, SBIPS_INT1_MASK, SBIPS_INT2_MASK, SBIPS_INT3_MASK, SBIPS_INT4_MASK };
-+      uint32 sbips_int_shift[] = { 0, 0, SBIPS_INT2_SHIFT, SBIPS_INT3_SHIFT, SBIPS_INT4_SHIFT };
 +
 +      chip = sb_chip(sbh);
 +      chiprev = sb_chiprev(sbh);
 +      chippkg = sb_chippkg(sbh);
-+      coreidx = sb_coreidx(sbh);
 +
-+      if (!(pci = (sbpciregs_t *) sb_setcore(sbh, SB_PCI, 0)))
++      if (!(pci = (sbpciregs_t *) sb_setcore(sbh, SB_PCI, 0))) {
++              printf("PCI: no core\n");
++              pci_disabled = TRUE;
 +              return -1;
++      }
 +      sb_core_reset(sbh, 0);
 +
-+      /* In some board,
-+      if(nvram_match("boardtype", "bcm94710dev"))
-+              CT4712_WR = 0;
-+      else
-+              CT4712_WR = 1;
-+      */
-+
 +      boardflags = (uint32) getintvar(NULL, "boardflags");
 +
 +      if ((chip == BCM4310_DEVICE_ID) && (chiprev == 0))
@@ -11716,7 +11896,8 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbpci.c linux-2.4.30-brcm/arch/mips/bc
 +       */
 +      if (((chip == BCM4712_DEVICE_ID) &&
 +           ((chippkg == BCM4712SMALL_PKG_ID) ||
-+            (chippkg == BCM4712MID_PKG_ID))) )
++            (chippkg == BCM4712MID_PKG_ID))) ||
++          (boardflags & BFL_NOPCI))
 +              pci_disabled = TRUE;
 +
 +      /*
@@ -11771,6 +11952,29 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbpci.c linux-2.4.30-brcm/arch/mips/bc
 +              /* Enable PCI interrupts */
 +              W_REG(&pci->intmask, PCI_INTA);
 +      }
++      
++      return 0;
++}
++
++static int
++sbpci_init_cores(void *sbh)
++{
++      uint chip, chiprev, chippkg, coreidx, i;
++      sbconfig_t *sb;
++      pci_config_regs *cfg;
++      void *regs;
++      char varname[8];
++      uint wlidx = 0;
++      uint16 vendor, core;
++      uint8 class, subclass, progif;
++      uint32 val;
++      uint32 sbips_int_mask[] = { 0, SBIPS_INT1_MASK, SBIPS_INT2_MASK, SBIPS_INT3_MASK, SBIPS_INT4_MASK };
++      uint32 sbips_int_shift[] = { 0, 0, SBIPS_INT2_SHIFT, SBIPS_INT3_SHIFT, SBIPS_INT4_SHIFT };
++
++      chip = sb_chip(sbh);
++      chiprev = sb_chiprev(sbh);
++      chippkg = sb_chippkg(sbh);
++      coreidx = sb_coreidx(sbh);
 +
 +      /* Scan the SB bus */
 +      bzero(sb_config_regs, sizeof(sb_config_regs));
@@ -11933,10 +12137,18 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbpci.c linux-2.4.30-brcm/arch/mips/bc
 +      return 0;
 +}
 +
-+void
-+sbpci_check(void *sbh)
++int __init
++sbpci_init(void *sbh)
 +{
-+      uint coreidx;
++      sbpci_init_pci(sbh);
++      sbpci_init_cores(sbh);
++      return 0;
++}
++
++void
++sbpci_check(void *sbh)
++{
++      uint coreidx;
 +      sbpciregs_t *pci;
 +      uint32 sbtopci1;
 +      uint32 buf[64], *ptr, i;
@@ -11991,9 +12203,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/sbpci.c linux-2.4.30-brcm/arch/mips/bc
 +
 +      sb_setcoreidx(sbh, coreidx);
 +}
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/setup.c linux-2.4.30-brcm/arch/mips/bcm947xx/setup.c
---- linux-2.4.30/arch/mips/bcm947xx/setup.c    1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/setup.c       2005-05-25 17:50:08.000000000 +0200
+diff -urN linux.old/arch/mips/bcm947xx/setup.c linux.dev/arch/mips/bcm947xx/setup.c
+--- linux.old/arch/mips/bcm947xx/setup.c       1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/setup.c       2005-08-26 13:44:34.313391368 +0200
 @@ -0,0 +1,261 @@
 +/*
 + * Generic setup routines for Broadcom MIPS boards
@@ -12143,7 +12355,7 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/setup.c linux-2.4.30-brcm/arch/mips/bc
 +#endif
 +
 +      /* Override default command line arguments */
-+      value = nvram_get("kernel_args");
++      value = nvram_get("kernel_cmdline");
 +      if (value && strlen(value) && strncmp(value, "empty", 5))
 +              strncpy(arcs_cmdline, value, sizeof(arcs_cmdline));
 +
@@ -12256,9 +12468,9 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/setup.c linux-2.4.30-brcm/arch/mips/bc
 +EXPORT_SYMBOL(init_mtd_partitions);
 +
 +#endif
-diff -Nur linux-2.4.30/arch/mips/bcm947xx/time.c linux-2.4.30-brcm/arch/mips/bcm947xx/time.c
---- linux-2.4.30/arch/mips/bcm947xx/time.c     1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/bcm947xx/time.c        2005-05-22 22:55:51.000000000 +0200
+diff -urN linux.old/arch/mips/bcm947xx/time.c linux.dev/arch/mips/bcm947xx/time.c
+--- linux.old/arch/mips/bcm947xx/time.c        1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/arch/mips/bcm947xx/time.c        2005-08-26 13:44:34.314391216 +0200
 @@ -0,0 +1,117 @@
 +/*
 + * Copyright 2004, Broadcom Corporation
@@ -12377,10 +12589,10 @@ diff -Nur linux-2.4.30/arch/mips/bcm947xx/time.c linux-2.4.30-brcm/arch/mips/bcm
 +      /* Enable the timer interrupt */
 +      setup_irq(7, &bcm947xx_timer_irqaction);
 +}
-diff -Nur linux-2.4.30/arch/mips/config-shared.in linux-2.4.30-brcm/arch/mips/config-shared.in
---- linux-2.4.30/arch/mips/config-shared.in    2005-01-19 15:09:27.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/config-shared.in       2005-05-26 16:34:10.000000000 +0200
-@@ -205,6 +205,14 @@
+diff -urN linux.old/arch/mips/config-shared.in linux.dev/arch/mips/config-shared.in
+--- linux.old/arch/mips/config-shared.in       2005-08-26 13:41:43.371378504 +0200
++++ linux.dev/arch/mips/config-shared.in       2005-08-26 13:44:34.315391064 +0200
+@@ -208,6 +208,14 @@
     fi
     define_bool CONFIG_MIPS_RTC y
  fi
@@ -12395,7 +12607,7 @@ diff -Nur linux-2.4.30/arch/mips/config-shared.in linux-2.4.30-brcm/arch/mips/co
  bool 'Support for SNI RM200 PCI' CONFIG_SNI_RM200_PCI
  bool 'Support for TANBAC TB0226 (Mbase)' CONFIG_TANBAC_TB0226
  bool 'Support for TANBAC TB0229 (VR4131DIMM)' CONFIG_TANBAC_TB0229
-@@ -226,6 +234,11 @@
+@@ -229,6 +237,11 @@
  define_bool CONFIG_RWSEM_XCHGADD_ALGORITHM n
  
  #
@@ -12407,7 +12619,7 @@ diff -Nur linux-2.4.30/arch/mips/config-shared.in linux-2.4.30-brcm/arch/mips/co
  # Select some configuration options automatically based on user selections.
  #
  if [ "$CONFIG_ACER_PICA_61" = "y" ]; then
-@@ -533,6 +546,13 @@
+@@ -554,6 +567,13 @@
     define_bool CONFIG_SWAP_IO_SPACE_L y
     define_bool CONFIG_BOOT_ELF32 y
  fi
@@ -12421,7 +12633,7 @@ diff -Nur linux-2.4.30/arch/mips/config-shared.in linux-2.4.30-brcm/arch/mips/co
  if [ "$CONFIG_SNI_RM200_PCI" = "y" ]; then
     define_bool CONFIG_ARC32 y
     define_bool CONFIG_ARC_MEMORY y
-@@ -1011,7 +1031,11 @@
+@@ -1042,7 +1062,11 @@
  
  bool 'Are you using a crosscompiler' CONFIG_CROSSCOMPILE
  bool 'Enable run-time debugging' CONFIG_RUNTIME_DEBUG
@@ -12434,10 +12646,10 @@ diff -Nur linux-2.4.30/arch/mips/config-shared.in linux-2.4.30-brcm/arch/mips/co
  dep_bool '  Console output to GDB' CONFIG_GDB_CONSOLE $CONFIG_KGDB
  if [ "$CONFIG_KGDB" = "y" ]; then
     define_bool CONFIG_DEBUG_INFO y
-diff -Nur linux-2.4.30/arch/mips/kernel/cpu-probe.c linux-2.4.30-brcm/arch/mips/kernel/cpu-probe.c
---- linux-2.4.30/arch/mips/kernel/cpu-probe.c  2005-01-19 15:09:29.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/kernel/cpu-probe.c     2005-05-22 22:55:51.000000000 +0200
-@@ -174,7 +174,7 @@
+diff -urN linux.old/arch/mips/kernel/cpu-probe.c linux.dev/arch/mips/kernel/cpu-probe.c
+--- linux.old/arch/mips/kernel/cpu-probe.c     2005-08-26 13:41:41.803616840 +0200
++++ linux.dev/arch/mips/kernel/cpu-probe.c     2005-08-26 13:44:34.316390912 +0200
+@@ -163,7 +163,7 @@
  
  static inline void cpu_probe_legacy(struct cpuinfo_mips *c)
  {
@@ -12446,7 +12658,7 @@ diff -Nur linux-2.4.30/arch/mips/kernel/cpu-probe.c linux-2.4.30-brcm/arch/mips/
        case PRID_IMP_R2000:
                c->cputype = CPU_R2000;
                c->isa_level = MIPS_CPU_ISA_I;
-@@ -184,7 +184,7 @@
+@@ -173,7 +173,7 @@
                c->tlbsize = 64;
                break;
        case PRID_IMP_R3000:
@@ -12455,7 +12667,7 @@ diff -Nur linux-2.4.30/arch/mips/kernel/cpu-probe.c linux-2.4.30-brcm/arch/mips/
                        if (cpu_has_confreg())
                                c->cputype = CPU_R3081E;
                        else
-@@ -199,12 +199,12 @@
+@@ -188,12 +188,12 @@
                break;
        case PRID_IMP_R4000:
                if (read_c0_config() & CONF_SC) {
@@ -12470,7 +12682,7 @@ diff -Nur linux-2.4.30/arch/mips/kernel/cpu-probe.c linux-2.4.30-brcm/arch/mips/
                                c->cputype = CPU_R4400SC;
                        else
                                c->cputype = CPU_R4000SC;
-@@ -450,7 +450,7 @@
+@@ -439,7 +439,7 @@
  static inline void cpu_probe_mips(struct cpuinfo_mips *c)
  {
        decode_config1(c);
@@ -12479,7 +12691,7 @@ diff -Nur linux-2.4.30/arch/mips/kernel/cpu-probe.c linux-2.4.30-brcm/arch/mips/
        case PRID_IMP_4KC:
                c->cputype = CPU_4KC;
                c->isa_level = MIPS_CPU_ISA_M32;
-@@ -491,10 +491,10 @@
+@@ -480,10 +480,10 @@
  {
        decode_config1(c);
        c->options |= MIPS_CPU_PREFETCH;
@@ -12492,7 +12704,7 @@ diff -Nur linux-2.4.30/arch/mips/kernel/cpu-probe.c linux-2.4.30-brcm/arch/mips/
                case 0:
                        c->cputype = CPU_AU1000;
                        break;
-@@ -522,10 +522,34 @@
+@@ -511,10 +511,34 @@
        }
  }
  
@@ -12528,7 +12740,7 @@ diff -Nur linux-2.4.30/arch/mips/kernel/cpu-probe.c linux-2.4.30-brcm/arch/mips/
        case PRID_IMP_SB1:
                c->cputype = CPU_SB1;
                c->isa_level = MIPS_CPU_ISA_M64;
-@@ -547,7 +571,7 @@
+@@ -536,7 +560,7 @@
  static inline void cpu_probe_sandcraft(struct cpuinfo_mips *c)
  {
        decode_config1(c);
@@ -12537,7 +12749,7 @@ diff -Nur linux-2.4.30/arch/mips/kernel/cpu-probe.c linux-2.4.30-brcm/arch/mips/
        case PRID_IMP_SR71000:
                c->cputype = CPU_SR71000;
                c->isa_level = MIPS_CPU_ISA_M64;
-@@ -572,7 +596,7 @@
+@@ -561,7 +585,7 @@
        c->cputype      = CPU_UNKNOWN;
  
        c->processor_id = read_c0_prid();
@@ -12546,7 +12758,7 @@ diff -Nur linux-2.4.30/arch/mips/kernel/cpu-probe.c linux-2.4.30-brcm/arch/mips/
  
        case PRID_COMP_LEGACY:
                cpu_probe_legacy(c);
-@@ -583,6 +607,9 @@
+@@ -572,6 +596,9 @@
        case PRID_COMP_ALCHEMY:
                cpu_probe_alchemy(c);
                break;
@@ -12556,9 +12768,9 @@ diff -Nur linux-2.4.30/arch/mips/kernel/cpu-probe.c linux-2.4.30-brcm/arch/mips/
        case PRID_COMP_SIBYTE:
                cpu_probe_sibyte(c);
                break;
-diff -Nur linux-2.4.30/arch/mips/kernel/head.S linux-2.4.30-brcm/arch/mips/kernel/head.S
---- linux-2.4.30/arch/mips/kernel/head.S       2005-01-19 15:09:29.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/kernel/head.S  2005-05-22 22:55:51.000000000 +0200
+diff -urN linux.old/arch/mips/kernel/head.S linux.dev/arch/mips/kernel/head.S
+--- linux.old/arch/mips/kernel/head.S  2005-08-26 13:41:41.804616688 +0200
++++ linux.dev/arch/mips/kernel/head.S  2005-08-26 13:44:34.317390760 +0200
 @@ -28,12 +28,20 @@
  #include <asm/mipsregs.h>
  #include <asm/stackframe.h>
@@ -12581,9 +12793,9 @@ diff -Nur linux-2.4.30/arch/mips/kernel/head.S linux-2.4.30-brcm/arch/mips/kerne
  
                /* The following two symbols are used for kernel profiling. */
                EXPORT(stext)
-diff -Nur linux-2.4.30/arch/mips/kernel/proc.c linux-2.4.30-brcm/arch/mips/kernel/proc.c
---- linux-2.4.30/arch/mips/kernel/proc.c       2005-01-19 15:09:29.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/kernel/proc.c  2005-05-22 22:55:51.000000000 +0200
+diff -urN linux.old/arch/mips/kernel/proc.c linux.dev/arch/mips/kernel/proc.c
+--- linux.old/arch/mips/kernel/proc.c  2005-01-19 15:09:29.000000000 +0100
++++ linux.dev/arch/mips/kernel/proc.c  2005-08-26 13:44:34.318390608 +0200
 @@ -78,9 +78,10 @@
        [CPU_AU1550]    "Au1550",
        [CPU_24K]       "MIPS 24K",
@@ -12596,10 +12808,10 @@ diff -Nur linux-2.4.30/arch/mips/kernel/proc.c linux-2.4.30-brcm/arch/mips/kerne
  static int show_cpuinfo(struct seq_file *m, void *v)
  {
        unsigned int version = current_cpu_data.processor_id;
-diff -Nur linux-2.4.30/arch/mips/kernel/setup.c linux-2.4.30-brcm/arch/mips/kernel/setup.c
---- linux-2.4.30/arch/mips/kernel/setup.c      2005-01-19 15:09:29.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/kernel/setup.c 2005-05-25 19:00:43.000000000 +0200
-@@ -495,6 +495,7 @@
+diff -urN linux.old/arch/mips/kernel/setup.c linux.dev/arch/mips/kernel/setup.c
+--- linux.old/arch/mips/kernel/setup.c 2005-08-26 13:41:41.805616536 +0200
++++ linux.dev/arch/mips/kernel/setup.c 2005-08-26 13:44:34.318390608 +0200
+@@ -493,6 +493,7 @@
        void swarm_setup(void);
        void hp_setup(void);
        void au1x00_setup(void);
@@ -12607,7 +12819,7 @@ diff -Nur linux-2.4.30/arch/mips/kernel/setup.c linux-2.4.30-brcm/arch/mips/kern
        void frame_info_init(void);
  
        frame_info_init();
-@@ -693,6 +694,11 @@
+@@ -691,6 +692,11 @@
                  pmc_yosemite_setup();
                  break;
  #endif
@@ -12619,10 +12831,10 @@ diff -Nur linux-2.4.30/arch/mips/kernel/setup.c linux-2.4.30-brcm/arch/mips/kern
        default:
                panic("Unsupported architecture");
        }
-diff -Nur linux-2.4.30/arch/mips/kernel/traps.c linux-2.4.30-brcm/arch/mips/kernel/traps.c
---- linux-2.4.30/arch/mips/kernel/traps.c      2005-01-19 15:09:29.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/kernel/traps.c 2005-05-22 22:55:51.000000000 +0200
-@@ -913,6 +913,7 @@
+diff -urN linux.old/arch/mips/kernel/traps.c linux.dev/arch/mips/kernel/traps.c
+--- linux.old/arch/mips/kernel/traps.c 2005-08-26 13:41:41.806616384 +0200
++++ linux.dev/arch/mips/kernel/traps.c 2005-08-26 13:44:34.321390152 +0200
+@@ -920,6 +920,7 @@
  void __init trap_init(void)
  {
        extern char except_vec1_generic;
@@ -12630,7 +12842,7 @@ diff -Nur linux-2.4.30/arch/mips/kernel/traps.c linux-2.4.30-brcm/arch/mips/kern
        extern char except_vec3_generic, except_vec3_r4000;
        extern char except_vec_ejtag_debug;
        extern char except_vec4;
-@@ -922,6 +923,7 @@
+@@ -927,6 +928,7 @@
  
        /* Copy the generic exception handler code to it's final destination. */
        memcpy((void *)(KSEG0 + 0x80), &except_vec1_generic, 0x80);
@@ -12638,7 +12850,7 @@ diff -Nur linux-2.4.30/arch/mips/kernel/traps.c linux-2.4.30-brcm/arch/mips/kern
  
        /*
         * Setup default vectors
-@@ -980,6 +982,12 @@
+@@ -985,6 +987,12 @@
        set_except_vector(13, handle_tr);
        set_except_vector(22, handle_mdmx);
  
@@ -12651,88 +12863,10 @@ diff -Nur linux-2.4.30/arch/mips/kernel/traps.c linux-2.4.30-brcm/arch/mips/kern
        if (cpu_has_fpu && !cpu_has_nofpuex)
                set_except_vector(15, handle_fpe);
  
-diff -Nur linux-2.4.30/arch/mips/Makefile linux-2.4.30-brcm/arch/mips/Makefile
---- linux-2.4.30/arch/mips/Makefile    2005-01-19 15:09:26.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/Makefile       2005-05-25 18:53:09.000000000 +0200
-@@ -46,10 +46,10 @@
- GCCFLAGS      := -I $(TOPDIR)/include/asm/gcc
- GCCFLAGS      += -G 0 -mno-abicalls -fno-pic -pipe
- GCCFLAGS      += $(call check_gcc, -finline-limit=100000,)
--LINKFLAGS     += -G 0 -static -n
--MODFLAGS      += -mlong-calls
-+LINKFLAGS     += -G 0 -static -n -nostdlib
-+MODFLAGS      += -mlong-calls -fno-common
--ifdef CONFIG_DEBUG_INFO
-+ifdef CONFIG_REMOTE_DEBUG
- GCCFLAGS      += -g
- ifdef CONFIG_SB1XXX_CORELIS
- GCCFLAGS      += -mno-sched-prolog -fno-omit-frame-pointer
-@@ -71,13 +71,13 @@
- set_gccflags = $(shell \
- while :; do \
-       cpu=$(1); isa=-$(2); \
--      for gcc_opt in -march= -mcpu=; do \
-+      for gcc_opt in -march= -mtune=; do \
-               $(CC) $$gcc_opt$$cpu $$isa -S -o /dev/null \
-                       -xc /dev/null > /dev/null 2>&1 && \
-                       break 2; \
-       done; \
-       cpu=$(3); isa=-$(4); \
--      for gcc_opt in -march= -mcpu=; do \
-+      for gcc_opt in -march= -mtune=; do \
-               $(CC) $$gcc_opt$$cpu $$isa -S -o /dev/null \
-                       -xc /dev/null > /dev/null 2>&1 && \
-                       break 2; \
-@@ -92,7 +92,7 @@
- fi; \
- gas_abi=-Wa,-32; gas_cpu=$$cpu; gas_isa=-Wa,$$isa; \
- while :; do \
--      for gas_opt in -Wa,-march= -Wa,-mcpu=; do \
-+      for gas_opt in -Wa,-march= -Wa,-mtune=; do \
-               $(CC) $$gas_abi $$gas_opt$$cpu $$gas_isa -Wa,-Z -c \
-                       -o /dev/null -xassembler /dev/null > /dev/null 2>&1 && \
-                       break 2; \
-@@ -174,6 +174,7 @@
- endif
- AFLAGS                += $(GCCFLAGS)
-+ASFLAGS               += $(GCCFLAGS)
- CFLAGS                += $(GCCFLAGS)
- LD            += -m $(ld-emul)
-@@ -715,6 +716,19 @@
- endif
- #
-+# Broadcom BCM947XX variants
-+#
-+ifdef CONFIG_BCM947XX
-+LIBS          += arch/mips/bcm947xx/generic/brcm.o arch/mips/bcm947xx/bcm947xx.o 
-+SUBDIRS               += arch/mips/bcm947xx/generic arch/mips/bcm947xx 
-+LOADADDR      := 0x80001000
-+
-+zImage: vmlinux
-+      $(MAKE) -C arch/$(ARCH)/bcm947xx/compressed
-+export LOADADDR
-+endif
-+
-+#
- # Choosing incompatible machines durings configuration will result in
- # error messages during linking.  Select a default linkscript if
- # none has been choosen above.
-@@ -767,6 +781,7 @@
-       $(MAKE) -C arch/$(ARCH)/tools clean
-       $(MAKE) -C arch/mips/baget clean
-       $(MAKE) -C arch/mips/lasat clean
-+      $(MAKE) -C arch/mips/bcm947xx/compressed clean
- archmrproper:
-       @$(MAKEBOOT) mrproper
-diff -Nur linux-2.4.30/arch/mips/mm/c-r4k.c linux-2.4.30-brcm/arch/mips/mm/c-r4k.c
---- linux-2.4.30/arch/mips/mm/c-r4k.c  2005-01-19 15:09:29.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/mm/c-r4k.c     2005-05-26 08:53:48.000000000 +0200
-@@ -1114,3 +1114,47 @@
+diff -urN linux.old/arch/mips/mm/c-r4k.c linux.dev/arch/mips/mm/c-r4k.c
+--- linux.old/arch/mips/mm/c-r4k.c     2005-08-26 13:41:41.825613496 +0200
++++ linux.dev/arch/mips/mm/c-r4k.c     2005-08-26 13:44:34.322390000 +0200
+@@ -1118,3 +1118,47 @@
        build_clear_page();
        build_copy_page();
  }
@@ -12780,9 +12914,9 @@ diff -Nur linux-2.4.30/arch/mips/mm/c-r4k.c linux-2.4.30-brcm/arch/mips/mm/c-r4k
 +}
 +
 +
-diff -Nur linux-2.4.30/arch/mips/pci/Makefile linux-2.4.30-brcm/arch/mips/pci/Makefile
---- linux-2.4.30/arch/mips/pci/Makefile        2005-01-19 15:09:29.000000000 +0100
-+++ linux-2.4.30-brcm/arch/mips/pci/Makefile   2005-05-26 01:02:53.000000000 +0200
+diff -urN linux.old/arch/mips/pci/Makefile linux.dev/arch/mips/pci/Makefile
+--- linux.old/arch/mips/pci/Makefile   2005-01-19 15:09:29.000000000 +0100
++++ linux.dev/arch/mips/pci/Makefile   2005-08-26 13:44:34.323389848 +0200
 @@ -13,7 +13,9 @@
  obj-$(CONFIG_MIPS_MSC)                += ops-msc.o
  obj-$(CONFIG_MIPS_NILE4)      += ops-nile4.o
@@ -12793,10 +12927,10 @@ diff -Nur linux-2.4.30/arch/mips/pci/Makefile linux-2.4.30-brcm/arch/mips/pci/Ma
  obj-$(CONFIG_PCI_AUTO)                += pci_auto.o
  
  include $(TOPDIR)/Rules.make
-diff -Nur linux-2.4.30/drivers/char/serial.c linux-2.4.30-brcm/drivers/char/serial.c
---- linux-2.4.30/drivers/char/serial.c 2005-01-19 15:09:50.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/char/serial.c    2005-05-22 22:55:52.000000000 +0200
-@@ -422,6 +422,10 @@
+diff -urN linux.old/drivers/char/serial.c linux.dev/drivers/char/serial.c
+--- linux.old/drivers/char/serial.c    2005-08-26 13:41:41.952594192 +0200
++++ linux.dev/drivers/char/serial.c    2005-09-01 02:33:38.312794792 +0200
+@@ -444,6 +444,10 @@
                return inb(info->port+1);
  #endif
        case SERIAL_IO_MEM:
@@ -12807,7 +12941,7 @@ diff -Nur linux-2.4.30/drivers/char/serial.c linux-2.4.30-brcm/drivers/char/seri
                return readb((unsigned long) info->iomem_base +
                             (offset<<info->iomem_reg_shift));
        default:
-@@ -442,6 +446,9 @@
+@@ -464,6 +468,9 @@
        case SERIAL_IO_MEM:
                writeb(value, (unsigned long) info->iomem_base +
                              (offset<<info->iomem_reg_shift));
@@ -12817,7 +12951,31 @@ diff -Nur linux-2.4.30/drivers/char/serial.c linux-2.4.30-brcm/drivers/char/seri
                break;
        default:
                outb(value, info->port+offset);
-@@ -5972,6 +5979,13 @@
+@@ -1728,7 +1735,7 @@
+                       /* Special case since 134 is really 134.5 */
+                       quot = (2*baud_base / 269);
+               else if (baud)
+-                      quot = baud_base / baud;
++                      quot = (baud_base + (baud / 2)) / baud;
+       }
+       /* If the quotient is zero refuse the change */
+       if (!quot && old_termios) {
+@@ -1745,12 +1752,12 @@
+                               /* Special case since 134 is really 134.5 */
+                               quot = (2*baud_base / 269);
+                       else if (baud)
+-                              quot = baud_base / baud;
++                              quot = (baud_base + (baud / 2)) / baud;
+               }
+       }
+       /* As a last resort, if the quotient is zero, default to 9600 bps */
+       if (!quot)
+-              quot = baud_base / 9600;
++              quot = (baud_base + 4800) / 9600;
+       /*
+        * Work around a bug in the Oxford Semiconductor 952 rev B
+        * chip which causes it to seriously miscalculate baud rates
+@@ -5996,6 +6003,13 @@
         *      Divisor, bytesize and parity
         */
        state = rs_table + co->index;
@@ -12831,1041 +12989,161 @@ diff -Nur linux-2.4.30/drivers/char/serial.c linux-2.4.30-brcm/drivers/char/seri
        if (doflow)
                state->flags |= ASYNC_CONS_FLOW;
        info = &async_sercons;
-diff -Nur linux-2.4.30/drivers/mtd/chips/cfi_cmdset_0701.c linux-2.4.30-brcm/drivers/mtd/chips/cfi_cmdset_0701.c
---- linux-2.4.30/drivers/mtd/chips/cfi_cmdset_0701.c   1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/mtd/chips/cfi_cmdset_0701.c      2005-05-22 22:55:52.000000000 +0200
-@@ -0,0 +1,855 @@
+@@ -6009,7 +6023,7 @@
+       info->io_type = state->io_type;
+       info->iomem_base = state->iomem_base;
+       info->iomem_reg_shift = state->iomem_reg_shift;
+-      quot = state->baud_base / baud;
++      quot = (state->baud_base + (baud / 2)) / baud;
+       cval = cflag & (CSIZE | CSTOPB);
+ #if defined(__powerpc__) || defined(__alpha__)
+       cval >>= 8;
+diff -urN linux.old/drivers/mtd/maps/Config.in linux.dev/drivers/mtd/maps/Config.in
+--- linux.old/drivers/mtd/maps/Config.in       2005-08-26 13:41:41.963592520 +0200
++++ linux.dev/drivers/mtd/maps/Config.in       2005-08-26 13:44:34.345386504 +0200
+@@ -48,6 +48,7 @@
+ fi
+ if [ "$CONFIG_MIPS" = "y" ]; then
++   dep_tristate '  CFI Flash device mapped on Broadcom BCM947XX boards' CONFIG_MTD_BCM947XX $CONFIG_MTD_CFI
+    dep_tristate '  Pb1000 MTD support' CONFIG_MTD_PB1000 $CONFIG_MIPS_PB1000
+    dep_tristate '  Pb1500 MTD support' CONFIG_MTD_PB1500 $CONFIG_MIPS_PB1500
+    dep_tristate '  Pb1100 MTD support' CONFIG_MTD_PB1100 $CONFIG_MIPS_PB1100
+diff -urN linux.old/drivers/mtd/maps/Makefile linux.dev/drivers/mtd/maps/Makefile
+--- linux.old/drivers/mtd/maps/Makefile        2005-08-26 13:41:41.963592520 +0200
++++ linux.dev/drivers/mtd/maps/Makefile        2005-08-26 13:44:34.346386352 +0200
+@@ -3,6 +3,8 @@
+ #
+ # $Id: Makefile,v 1.37 2003/01/24 14:26:38 dwmw2 Exp $
++EXTRA_CFLAGS := -I$(TOPDIR)/arch/mips/bcm947xx/include
++
+ BELOW25               := $(shell echo $(PATCHLEVEL) | sed s/[1234]/y/)
+ ifeq ($(BELOW25),y)
+@@ -10,6 +12,7 @@
+ endif
+ # Chip mappings
++obj-$(CONFIG_MTD_BCM947XX)    += bcm947xx-flash.o
+ obj-$(CONFIG_MTD_CDB89712)    += cdb89712.o
+ obj-$(CONFIG_MTD_ARM_INTEGRATOR)+= integrator-flash.o
+ obj-$(CONFIG_MTD_CFI_FLAGADM) += cfi_flagadm.o
+diff -urN linux.old/drivers/mtd/maps/bcm947xx-flash.c linux.dev/drivers/mtd/maps/bcm947xx-flash.c
+--- linux.old/drivers/mtd/maps/bcm947xx-flash.c        1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/drivers/mtd/maps/bcm947xx-flash.c        2005-08-26 13:44:34.346386352 +0200
+@@ -0,0 +1,236 @@
 +/*
-+ * Common Flash Interface support:
-+ *   SST Standard Vendor Command Set (ID 0x0701)
-+ *
-+ * Copyright (C) 2000 Crossnet Co. <info@crossnet.co.jp>
-+ *
-+ * 2_by_8 routines added by Simon Munton
-+ *
-+ * This code is GPL
++ * Flash mapping for BCM947XX boards
 + *
-+ * $Id: cfi_cmdset_0701.c,v 1.1 2005/03/16 13:50:00 wbx Exp $
++ * Copyright 2004, Broadcom Corporation
++ * All Rights Reserved.
++ * 
++ * THIS SOFTWARE IS OFFERED "AS IS", AND BROADCOM GRANTS NO WARRANTIES OF ANY
++ * KIND, EXPRESS OR IMPLIED, BY STATUTE, COMMUNICATION OR OTHERWISE. BROADCOM
++ * SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS
++ * FOR A SPECIFIC PURPOSE OR NONINFRINGEMENT CONCERNING THIS SOFTWARE.
 + *
++ * $Id: bcm947xx-flash.c,v 1.1 2005/03/16 13:50:00 wbx Exp $
 + */
 +
 +#include <linux/module.h>
 +#include <linux/types.h>
 +#include <linux/kernel.h>
-+#include <linux/sched.h>
 +#include <asm/io.h>
-+#include <asm/byteorder.h>
-+
-+#include <linux/errno.h>
-+#include <linux/slab.h>
-+#include <linux/delay.h>
-+#include <linux/interrupt.h>
++#include <linux/mtd/mtd.h>
 +#include <linux/mtd/map.h>
-+#include <linux/mtd/cfi.h>
++#include <linux/mtd/partitions.h>
++#include <linux/config.h>
 +
-+static int cfi_sststd_read (struct mtd_info *, loff_t, size_t, size_t *, u_char *);
-+static int cfi_sststd_write(struct mtd_info *, loff_t, size_t, size_t *, const u_char *);
-+static int cfi_sststd_erase_onesize(struct mtd_info *, struct erase_info *);
-+static int cfi_sststd_erase_varsize(struct mtd_info *, struct erase_info *);
-+static void cfi_sststd_sync (struct mtd_info *);
-+static int cfi_sststd_suspend (struct mtd_info *);
-+static void cfi_sststd_resume (struct mtd_info *);
++#include <typedefs.h>
++#include <bcmnvram.h>
++#include <bcmutils.h>
++#include <sbconfig.h>
++#include <sbchipc.h>
++#include <sbutils.h>
++#include <trxhdr.h>
 +
-+static void cfi_sststd_destroy(struct mtd_info *);
++/* Global SB handle */
++extern void *bcm947xx_sbh;
++extern spinlock_t bcm947xx_sbh_lock;
 +
-+struct mtd_info *cfi_cmdset_0701(struct map_info *, int);
-+static struct mtd_info *cfi_sststd_setup (struct map_info *);
++/* Convenience */
++#define sbh bcm947xx_sbh
++#define sbh_lock bcm947xx_sbh_lock
 +
++#ifdef CONFIG_MTD_PARTITIONS
++extern struct mtd_partition * init_mtd_partitions(struct mtd_info *mtd, size_t size);
++#endif
 +
-+static struct mtd_chip_driver cfi_sststd_chipdrv = {
-+      probe: NULL, /* Not usable directly */
-+      destroy: cfi_sststd_destroy,
-+      name: "cfi_cmdset_0701",
-+      module: THIS_MODULE
-+};
++#define WINDOW_ADDR 0x1fc00000
++#define WINDOW_SIZE 0x400000
++#define BUSWIDTH 2
 +
-+struct mtd_info *cfi_cmdset_0701(struct map_info *map, int primary)
++/* e.g., flash=2M or flash=4M */
++static int flash = 0;
++MODULE_PARM(flash, "i");
++static int __init
++bcm947xx_setup(char *str)
 +{
-+      struct cfi_private *cfi = map->fldrv_priv;
-+      int ofs_factor = cfi->interleave * cfi->device_type;
-+      int i;
-+      __u8 major, minor;
-+      __u32 base = cfi->chips[0].start;
-+
-+      if (cfi->cfi_mode==1){
-+              __u16 adr = primary?cfi->cfiq->P_ADR:cfi->cfiq->A_ADR;
++      flash = memparse(str, &str);
++      return 1;
++}
++__setup("flash=", bcm947xx_setup);
 +
-+              cfi_send_gen_cmd(0xAA, 0x5555, base, map, cfi, cfi->device_type, NULL);
-+              cfi_send_gen_cmd(0x55, 0x2AAA, base, map, cfi, cfi->device_type, NULL);
-+              cfi_send_gen_cmd(0x98, 0x5555, base, map, cfi, cfi->device_type, NULL);
-+              
-+              major = cfi_read_query(map, base + (adr+3)*ofs_factor);
-+              minor = cfi_read_query(map, base + (adr+4)*ofs_factor);
-+              
-+              printk(" SST Query Table v%c.%c at 0x%4.4X\n",
-+                     major, minor, adr);
-+              cfi_send_gen_cmd(0xf0, 0x5555, base, map, cfi, cfi->device_type, NULL);
-+              
-+              cfi_send_gen_cmd(0xAA, 0x5555, base, map, cfi, cfi->device_type, NULL);
-+              cfi_send_gen_cmd(0x55, 0x2AAA, base, map, cfi, cfi->device_type, NULL);
-+              cfi_send_gen_cmd(0x90, 0x5555, base, map, cfi, cfi->device_type, NULL);
-+              cfi->mfr = cfi_read_query(map, base);
-+              cfi->id = cfi_read_query(map, base + ofs_factor);
-+
-+              cfi_send_gen_cmd(0xAA, 0x5555, base, map, cfi, cfi->device_type, NULL);
-+              cfi_send_gen_cmd(0x55, 0x2AAA, base, map, cfi, cfi->device_type, NULL);
-+              cfi_send_gen_cmd(0x98, 0x5555, base, map, cfi, cfi->device_type, NULL);
-+              
-+              switch (cfi->device_type) {
-+              case CFI_DEVICETYPE_X16:
-+                      cfi->addr_unlock1 = 0x5555;
-+                      cfi->addr_unlock2 = 0x2AAA;
-+                      break;
-+              default:
-+                      printk(KERN_NOTICE "Eep. Unknown cfi_cmdset_0701 device type %d\n", cfi->device_type);
-+                      return NULL;
-+              }
-+      } /* CFI mode */
++static struct mtd_info *bcm947xx_mtd;
 +
-+      for (i=0; i< cfi->numchips; i++) {
-+              cfi->chips[i].word_write_time = 1<<cfi->cfiq->WordWriteTimeoutTyp;
-+              cfi->chips[i].buffer_write_time = 1<<cfi->cfiq->BufWriteTimeoutTyp;
-+              cfi->chips[i].erase_time = 1<<cfi->cfiq->BlockEraseTimeoutTyp;
-+      }               
-+      
-+      map->fldrv = &cfi_sststd_chipdrv;
-+      MOD_INC_USE_COUNT;
++__u8 bcm947xx_map_read8(struct map_info *map, unsigned long ofs)
++{
++      if (map->map_priv_2 == 1)
++              return __raw_readb(map->map_priv_1 + ofs);
 +
-+      cfi_send_gen_cmd(0xf0, 0x5555, base, map, cfi, cfi->device_type, NULL);
-+      return cfi_sststd_setup(map);
++      u16 val = __raw_readw(map->map_priv_1 + (ofs & ~1));
++      if (ofs & 1)
++              return ((val >> 8) & 0xff);
++      else
++              return (val & 0xff);
 +}
 +
-+static struct mtd_info *cfi_sststd_setup(struct map_info *map)
++__u16 bcm947xx_map_read16(struct map_info *map, unsigned long ofs)
 +{
-+      struct cfi_private *cfi = map->fldrv_priv;
-+      struct mtd_info *mtd;
-+      unsigned long devsize = (1<<cfi->cfiq->DevSize) * cfi->interleave;
-+
-+      mtd = kmalloc(sizeof(*mtd), GFP_KERNEL);
-+      printk("number of %s chips: %d\n", (cfi->cfi_mode)?"JEDEC":"CFI",cfi->numchips);
++      return __raw_readw(map->map_priv_1 + ofs);
++}
 +
-+      if (!mtd) {
-+        printk("Failed to allocate memory for MTD device\n");
-+        kfree(cfi->cmdset_priv);
-+        return NULL;
-+      }
++__u32 bcm947xx_map_read32(struct map_info *map, unsigned long ofs)
++{
++      return __raw_readl(map->map_priv_1 + ofs);
++}
 +
-+      memset(mtd, 0, sizeof(*mtd));
-+      mtd->priv = map;
-+      mtd->type = MTD_NORFLASH;
-+      /* Also select the correct geometry setup too */ 
-+      mtd->size = devsize * cfi->numchips;
-+      
-+      if (cfi->cfiq->NumEraseRegions == 1) {
-+              /* No need to muck about with multiple erase sizes */
-+              mtd->erasesize = ((cfi->cfiq->EraseRegionInfo[0] >> 8) & ~0xff) * cfi->interleave;
++void bcm947xx_map_copy_from(struct map_info *map, void *to, unsigned long from, ssize_t len)
++{
++      if (len==1) {
++              memcpy_fromio(to, map->map_priv_1 + from, len);
 +      } else {
-+              unsigned long offset = 0;
-+              int i,j;
-+
-+              mtd->numeraseregions = cfi->cfiq->NumEraseRegions * cfi->numchips;
-+              mtd->eraseregions = kmalloc(sizeof(struct mtd_erase_region_info) * mtd->numeraseregions, GFP_KERNEL);
-+              if (!mtd->eraseregions) { 
-+                      printk("Failed to allocate memory for MTD erase region info\n");
-+                      kfree(cfi->cmdset_priv);
-+                      return NULL;
-+              }
-+                      
-+              for (i=0; i<cfi->cfiq->NumEraseRegions; i++) {
-+                      unsigned long ernum, ersize;
-+                      ersize = ((cfi->cfiq->EraseRegionInfo[i] >> 8) & ~0xff) * cfi->interleave;
-+                      ernum = (cfi->cfiq->EraseRegionInfo[i] & 0xffff) + 1;
-+                      
-+                      if (mtd->erasesize < ersize) {
-+                              mtd->erasesize = ersize;
-+                      }
-+                      for (j=0; j<cfi->numchips; j++) {
-+                              mtd->eraseregions[(j*cfi->cfiq->NumEraseRegions)+i].offset = (j*devsize)+offset;
-+                              mtd->eraseregions[(j*cfi->cfiq->NumEraseRegions)+i].erasesize = ersize;
-+                              mtd->eraseregions[(j*cfi->cfiq->NumEraseRegions)+i].numblocks = ernum;
-+                      }
-+                      offset += (ersize * ernum);
-+              }
-+
-+              // debug
-+              for (i=0; i<mtd->numeraseregions;i++){
-+                      printk("%d: offset=0x%x,size=0x%x,blocks=%d\n",
-+                             i,mtd->eraseregions[i].offset,
-+                             mtd->eraseregions[i].erasesize,
-+                             mtd->eraseregions[i].numblocks);
++              int i;
++              u16 *dest = (u16 *) to;
++              u16 *src  = (u16 *) (map->map_priv_1 + from);
++              for (i = 0; i < (len / 2); i++) {
++                      dest[i] = src[i];
 +              }
++              if (len & 1)
++                      *((u8 *)dest+len-1) = src[i] & 0xff;
 +      }
-+
-+      switch (CFIDEV_BUSWIDTH)
-+      {
-+      case 1:
-+      case 2:
-+      case 4:
-+              if (mtd->numeraseregions > 1)
-+                      mtd->erase = cfi_sststd_erase_varsize;
-+              else
-+                      mtd->erase = cfi_sststd_erase_onesize;
-+              mtd->read = cfi_sststd_read;
-+              mtd->write = cfi_sststd_write;
-+              break;
-+
-+      default:
-+              printk("Unsupported buswidth\n");
-+              kfree(mtd);
-+              kfree(cfi->cmdset_priv);
-+              return NULL;
-+              break;
-+      }
-+      mtd->sync = cfi_sststd_sync;
-+      mtd->suspend = cfi_sststd_suspend;
-+      mtd->resume = cfi_sststd_resume;
-+      mtd->flags = MTD_CAP_NORFLASH;
-+      map->fldrv = &cfi_sststd_chipdrv;
-+      mtd->name = map->name;
-+      MOD_INC_USE_COUNT;
-+      return mtd;
 +}
 +
-+static inline int do_read_onechip(struct map_info *map, struct flchip *chip, loff_t adr, size_t len, u_char *buf)
++void bcm947xx_map_write8(struct map_info *map, __u8 d, unsigned long adr)
 +{
-+      DECLARE_WAITQUEUE(wait, current);
-+      unsigned long timeo = jiffies + HZ;
-+
-+ retry:
-+      cfi_spin_lock(chip->mutex);
-+
-+      if (chip->state != FL_READY){
-+              printk("Waiting for chip to read, status = %d\n", chip->state);
-+              set_current_state(TASK_UNINTERRUPTIBLE);
-+              add_wait_queue(&chip->wq, &wait);
-+                
-+              cfi_spin_unlock(chip->mutex);
-+
-+              schedule();
-+              remove_wait_queue(&chip->wq, &wait);
-+              timeo = jiffies + HZ;
-+
-+              goto retry;
-+      }       
-+
-+      adr += chip->start;
-+
-+      chip->state = FL_READY;
-+
-+      map->copy_from(map, buf, adr, len);
-+
-+      wake_up(&chip->wq);
-+      cfi_spin_unlock(chip->mutex);
-+
-+      return 0;
++      __raw_writeb(d, map->map_priv_1 + adr);
++      mb();
 +}
 +
-+static int cfi_sststd_read (struct mtd_info *mtd, loff_t from, size_t len, size_t *retlen, u_char *buf)
++void bcm947xx_map_write16(struct map_info *map, __u16 d, unsigned long adr)
 +{
-+      struct map_info *map = mtd->priv;
-+      struct cfi_private *cfi = map->fldrv_priv;
-+      unsigned long ofs;
-+      int chipnum;
-+      int ret = 0;
-+
-+      /* ofs: offset within the first chip that the first read should start */
-+
-+      chipnum = (from >> cfi->chipshift);
-+      ofs = from - (chipnum <<  cfi->chipshift);
-+
-+
-+      *retlen = 0;
-+
-+      while (len) {
-+              unsigned long thislen;
-+
-+              if (chipnum >= cfi->numchips)
-+                      break;
-+
-+              if ((len + ofs -1) >> cfi->chipshift)
-+                      thislen = (1<<cfi->chipshift) - ofs;
-+              else
-+                      thislen = len;
-+
-+              ret = do_read_onechip(map, &cfi->chips[chipnum], ofs, thislen, buf);
-+              if (ret)
-+                      break;
-+
-+              *retlen += thislen;
-+              len -= thislen;
-+              buf += thislen;
-+
-+              ofs = 0;
-+              chipnum++;
-+      }
-+      return ret;
++      __raw_writew(d, map->map_priv_1 + adr);
++      mb();
 +}
 +
-+static int do_write_oneword(struct map_info *map, struct flchip *chip, unsigned long adr, __u32 datum, int fast)
-+{
-+      unsigned long timeo = jiffies + HZ;
-+      unsigned int Last[4];
-+      unsigned long Count = 0;
-+      struct cfi_private *cfi = map->fldrv_priv;
-+      DECLARE_WAITQUEUE(wait, current);
-+      int ret = 0;
-+
-+ retry:
-+      cfi_spin_lock(chip->mutex);
-+
-+      if (chip->state != FL_READY){
-+              printk("Waiting for chip to write, status = %d\n", chip->state);
-+              set_current_state(TASK_UNINTERRUPTIBLE);
-+              add_wait_queue(&chip->wq, &wait);
-+                
-+              cfi_spin_unlock(chip->mutex);
-+
-+              schedule();
-+              remove_wait_queue(&chip->wq, &wait);
-+              printk("Wake up to write:\n");
-+              timeo = jiffies + HZ;
-+
-+              goto retry;
-+      }       
-+
-+      chip->state = FL_WRITING;
-+
-+      adr += chip->start;
-+      ENABLE_VPP(map);
-+    cfi_send_gen_cmd(0xAA, cfi->addr_unlock1, chip->start, map, cfi, CFI_DEVICETYPE_X16, NULL);
-+    cfi_send_gen_cmd(0x55, cfi->addr_unlock2, chip->start, map, cfi, CFI_DEVICETYPE_X16, NULL);
-+    cfi_send_gen_cmd(0xA0, cfi->addr_unlock1, chip->start, map, cfi, CFI_DEVICETYPE_X16, NULL);
-+
-+      cfi_write(map, datum, adr);
-+
-+      cfi_spin_unlock(chip->mutex);
-+      cfi_udelay(chip->word_write_time);
-+      cfi_spin_lock(chip->mutex);
-+
-+      Last[0] = cfi_read(map, adr);
-+      //      printk("Last[0] is %x\n", Last[0]);
-+      Last[1] = cfi_read(map, adr);
-+      //      printk("Last[1] is %x\n", Last[1]);
-+      Last[2] = cfi_read(map, adr);
-+      //      printk("Last[2] is %x\n", Last[2]);
-+
-+      for (Count = 3; Last[(Count - 1) % 4] != Last[(Count - 2) % 4] && Count < 10000; Count++){
-+              cfi_spin_unlock(chip->mutex);
-+              cfi_udelay(10);
-+              cfi_spin_lock(chip->mutex);
-+              
-+              Last[Count % 4] = cfi_read(map, adr);
-+              //              printk("Last[%d%%4] is %x\n", Count, Last[Count%4]);
-+      }
-+      
-+      if (Last[(Count - 1) % 4] != datum){
-+              printk("Last[%ld] is %x, datum is %x\n",(Count - 1) % 4,Last[(Count - 1) % 4],datum);
-+              cfi_send_gen_cmd(0xF0, 0, chip->start, map, cfi, cfi->device_type, NULL);
-+              DISABLE_VPP(map);
-+              ret = -EIO;
-+      }       
-+      DISABLE_VPP(map);
-+      chip->state = FL_READY;
-+      wake_up(&chip->wq);
-+      cfi_spin_unlock(chip->mutex);
-+      
-+      return ret;
-+}
-+
-+static int cfi_sststd_write (struct mtd_info *mtd, loff_t to , size_t len, size_t *retlen, const u_char *buf)
-+{
-+      struct map_info *map = mtd->priv;
-+      struct cfi_private *cfi = map->fldrv_priv;
-+      int ret = 0;
-+      int chipnum;
-+      unsigned long ofs, chipstart;
-+
-+      *retlen = 0;
-+      if (!len)
-+              return 0;
-+
-+      chipnum = to >> cfi->chipshift;
-+      ofs = to  - (chipnum << cfi->chipshift);
-+      chipstart = cfi->chips[chipnum].start;
-+
-+      /* If it's not bus-aligned, do the first byte write */
-+      if (ofs & (CFIDEV_BUSWIDTH-1)) {
-+              unsigned long bus_ofs = ofs & ~(CFIDEV_BUSWIDTH-1);
-+              int i = ofs - bus_ofs;
-+              int n = 0;
-+              u_char tmp_buf[4];
-+              __u32 datum;
-+
-+              map->copy_from(map, tmp_buf, bus_ofs + cfi->chips[chipnum].start, CFIDEV_BUSWIDTH);
-+              while (len && i < CFIDEV_BUSWIDTH)
-+                      tmp_buf[i++] = buf[n++], len--;
-+
-+              if (cfi_buswidth_is_2()) {
-+                      datum = *(__u16*)tmp_buf;
-+              } else if (cfi_buswidth_is_4()) {
-+                      datum = *(__u32*)tmp_buf;
-+              } else {
-+                      return -EINVAL;  /* should never happen, but be safe */
-+              }
-+
-+              ret = do_write_oneword(map, &cfi->chips[chipnum], 
-+                              bus_ofs, datum, 0);
-+              if (ret) 
-+                      return ret;
-+              
-+              ofs += n;
-+              buf += n;
-+              (*retlen) += n;
-+
-+              if (ofs >> cfi->chipshift) {
-+                      chipnum ++; 
-+                      ofs = 0;
-+                      if (chipnum == cfi->numchips)
-+                              return 0;
-+              }
-+      }
-+      
-+      /* We are now aligned, write as much as possible */
-+      while(len >= CFIDEV_BUSWIDTH) {
-+              __u32 datum;
-+
-+              if (cfi_buswidth_is_1()) {
-+                      datum = *(__u8*)buf;
-+              } else if (cfi_buswidth_is_2()) {
-+                      datum = *(__u16*)buf;
-+              } else if (cfi_buswidth_is_4()) {
-+                      datum = *(__u32*)buf;
-+              } else {
-+                      return -EINVAL;
-+              }
-+              ret = do_write_oneword(map, &cfi->chips[chipnum],
-+                                     ofs, datum, cfi->fast_prog);
-+              if (ret) {
-+                      return ret;
-+              }
-+
-+              ofs += CFIDEV_BUSWIDTH;
-+              buf += CFIDEV_BUSWIDTH;
-+              (*retlen) += CFIDEV_BUSWIDTH;
-+              len -= CFIDEV_BUSWIDTH;
-+
-+              if (ofs >> cfi->chipshift) {
-+                      chipnum ++; 
-+                      ofs = 0;
-+                      if (chipnum == cfi->numchips)
-+                              return 0;
-+                      chipstart = cfi->chips[chipnum].start;
-+              }
-+      }
-+
-+      if (len & (CFIDEV_BUSWIDTH-1)) {
-+              int i = 0, n = 0;
-+              u_char tmp_buf[4];
-+              __u32 datum;
-+
-+              map->copy_from(map, tmp_buf, ofs + cfi->chips[chipnum].start, CFIDEV_BUSWIDTH);
-+              while (len--)
-+                      tmp_buf[i++] = buf[n++];
-+
-+              if (cfi_buswidth_is_2()) {
-+                      datum = *(__u16*)tmp_buf;
-+              } else if (cfi_buswidth_is_4()) {
-+                      datum = *(__u32*)tmp_buf;
-+              } else {
-+                      return -EINVAL;  /* should never happen, but be safe */
-+              }
-+
-+              ret = do_write_oneword(map, &cfi->chips[chipnum], 
-+                              ofs, datum, 0);
-+              if (ret) 
-+                      return ret;
-+              
-+              (*retlen) += n;
-+      }
-+
-+      return 0;
-+}
-+
-+static inline int do_erase_oneblock(struct map_info *map, struct flchip *chip, unsigned long adr)
-+{
-+      unsigned int status;
-+      unsigned long timeo = jiffies + HZ;
-+      struct cfi_private *cfi = map->fldrv_priv;
-+      unsigned int rdy_mask;
-+      DECLARE_WAITQUEUE(wait, current);
-+
-+ retry:
-+      cfi_spin_lock(chip->mutex);
-+
-+      if (chip->state != FL_READY){
-+              set_current_state(TASK_UNINTERRUPTIBLE);
-+              add_wait_queue(&chip->wq, &wait);
-+                
-+              cfi_spin_unlock(chip->mutex);
-+
-+              schedule();
-+              remove_wait_queue(&chip->wq, &wait);
-+              timeo = jiffies + HZ;
-+
-+              goto retry;
-+      }       
-+
-+      chip->state = FL_ERASING;
-+
-+      adr += chip->start;
-+      ENABLE_VPP(map);
-+      cfi_send_gen_cmd(0xAA, cfi->addr_unlock1, chip->start, map, cfi, CFI_DEVICETYPE_X16, NULL);
-+      cfi_send_gen_cmd(0x55, cfi->addr_unlock2, chip->start, map, cfi, CFI_DEVICETYPE_X16, NULL);
-+      cfi_send_gen_cmd(0x80, cfi->addr_unlock1, chip->start, map, cfi, CFI_DEVICETYPE_X16, NULL);
-+      cfi_send_gen_cmd(0xAA, cfi->addr_unlock1, chip->start, map, cfi, CFI_DEVICETYPE_X16, NULL);
-+      cfi_send_gen_cmd(0x55, cfi->addr_unlock2, chip->start, map, cfi, CFI_DEVICETYPE_X16, NULL);
-+      cfi_write(map, CMD(0x30), adr);
-+      
-+      timeo = jiffies + (HZ*20);
-+
-+      cfi_spin_unlock(chip->mutex);
-+      schedule_timeout(HZ);
-+      cfi_spin_lock(chip->mutex);
-+      
-+      rdy_mask = CMD(0x80);
-+
-+      /* Once the state machine's known to be working I'll do that */
-+
-+      while ( ( (status = cfi_read(map,adr)) & rdy_mask ) != rdy_mask ) {
-+              static int z=0;
-+
-+              if (chip->state != FL_ERASING) {
-+                      /* Someone's suspended the erase. Sleep */
-+                      set_current_state(TASK_UNINTERRUPTIBLE);
-+                      add_wait_queue(&chip->wq, &wait);
-+                      
-+                      cfi_spin_unlock(chip->mutex);
-+                      printk("erase suspended. Sleeping\n");
-+                      
-+                      schedule();
-+                      remove_wait_queue(&chip->wq, &wait);
-+                      timeo = jiffies + (HZ*2); 
-+                      cfi_spin_lock(chip->mutex);
-+                      continue;
-+              }
-+
-+              /* OK Still waiting */
-+              if (time_after(jiffies, timeo)) {
-+                      chip->state = FL_READY;
-+                      cfi_spin_unlock(chip->mutex);
-+                      printk("waiting for erase to complete timed out.");
-+                      DISABLE_VPP(map);
-+                      return -EIO;
-+              }
-+              
-+              /* Latency issues. Drop the lock, wait a while and retry */
-+              cfi_spin_unlock(chip->mutex);
-+
-+              z++;
-+              if ( 0 && !(z % 100 )) 
-+                      printk("chip not ready yet after erase. looping\n");
-+
-+              cfi_udelay(1);
-+              
-+              cfi_spin_lock(chip->mutex);
-+              continue;
-+      }
-+      
-+      /* Done and happy. */
-+      DISABLE_VPP(map);
-+      chip->state = FL_READY;
-+      wake_up(&chip->wq);
-+      cfi_spin_unlock(chip->mutex);
-+      return 0;
-+}
-+
-+static int cfi_sststd_erase_varsize(struct mtd_info *mtd, struct erase_info *instr)
-+{
-+      struct map_info *map = mtd->priv;
-+      struct cfi_private *cfi = map->fldrv_priv;
-+      unsigned long adr, len;
-+      int chipnum, ret = 0;
-+      int i, first;
-+      struct mtd_erase_region_info *regions = mtd->eraseregions;
-+
-+      if (instr->addr > mtd->size)
-+              return -EINVAL;
-+
-+      if ((instr->len + instr->addr) > mtd->size)
-+              return -EINVAL;
-+
-+      /* Check that both start and end of the requested erase are
-+       * aligned with the erasesize at the appropriate addresses.
-+       */
-+
-+      i = 0;
-+
-+      /* Skip all erase regions which are ended before the start of 
-+         the requested erase. Actually, to save on the calculations,
-+         we skip to the first erase region which starts after the
-+         start of the requested erase, and then go back one.
-+      */
-+      
-+      while (i < mtd->numeraseregions && instr->addr >= regions[i].offset)
-+             i++;
-+      i--;
-+
-+      /* OK, now i is pointing at the erase region in which this 
-+         erase request starts. Check the start of the requested
-+         erase range is aligned with the erase size which is in
-+         effect here.
-+      */
-+
-+      if (instr->addr & (regions[i].erasesize-1))
-+              return -EINVAL;
-+
-+      /* Remember the erase region we start on */
-+      first = i;
-+
-+      /* Next, check that the end of the requested erase is aligned
-+       * with the erase region at that address.
-+       */
-+
-+      while (i<mtd->numeraseregions && (instr->addr + instr->len) >= regions[i].offset)
-+              i++;
-+
-+      /* As before, drop back one to point at the region in which
-+         the address actually falls
-+      */
-+      i--;
-+      
-+      if ((instr->addr + instr->len) & (regions[i].erasesize-1))
-+              return -EINVAL;
-+      
-+      chipnum = instr->addr >> cfi->chipshift;
-+      adr = instr->addr - (chipnum << cfi->chipshift);
-+      len = instr->len;
-+
-+      i=first;
-+
-+      while(len) {
-+              ret = do_erase_oneblock(map, &cfi->chips[chipnum], adr);
-+
-+              if (ret)
-+                      return ret;
-+
-+              adr += regions[i].erasesize;
-+              len -= regions[i].erasesize;
-+
-+              if (adr % (1<< cfi->chipshift) == ((regions[i].offset + (regions[i].erasesize * regions[i].numblocks)) %( 1<< cfi->chipshift)))
-+                      i++;
-+
-+              if (adr >> cfi->chipshift) {
-+                      adr = 0;
-+                      chipnum++;
-+                      
-+                      if (chipnum >= cfi->numchips)
-+                      break;
-+              }
-+      }
-+
-+      instr->state = MTD_ERASE_DONE;
-+      if (instr->callback)
-+              instr->callback(instr);
-+      
-+      return 0;
-+}
-+
-+static int cfi_sststd_erase_onesize(struct mtd_info *mtd, struct erase_info *instr)
-+{
-+      struct map_info *map = mtd->priv;
-+      struct cfi_private *cfi = map->fldrv_priv;
-+      unsigned long adr, len;
-+      int chipnum, ret = 0;
-+
-+      if (instr->addr & (mtd->erasesize - 1))
-+              return -EINVAL;
-+
-+      if (instr->len & (mtd->erasesize -1))
-+              return -EINVAL;
-+
-+      if ((instr->len + instr->addr) > mtd->size)
-+              return -EINVAL;
-+
-+      chipnum = instr->addr >> cfi->chipshift;
-+      adr = instr->addr - (chipnum << cfi->chipshift);
-+      len = instr->len;
-+
-+      while(len) {
-+              ret = do_erase_oneblock(map, &cfi->chips[chipnum], adr);
-+
-+              if (ret)
-+                      return ret;
-+
-+              adr += mtd->erasesize;
-+              len -= mtd->erasesize;
-+
-+              if (adr >> cfi->chipshift) {
-+                      adr = 0;
-+                      chipnum++;
-+                      
-+                      if (chipnum >= cfi->numchips)
-+                      break;
-+              }
-+      }
-+              
-+      instr->state = MTD_ERASE_DONE;
-+      if (instr->callback)
-+              instr->callback(instr);
-+      
-+      return 0;
-+}
-+
-+static void cfi_sststd_sync (struct mtd_info *mtd)
-+{
-+      struct map_info *map = mtd->priv;
-+      struct cfi_private *cfi = map->fldrv_priv;
-+      int i;
-+      struct flchip *chip;
-+      int ret = 0;
-+      DECLARE_WAITQUEUE(wait, current);
-+
-+      for (i=0; !ret && i<cfi->numchips; i++) {
-+              chip = &cfi->chips[i];
-+
-+      retry:
-+              cfi_spin_lock(chip->mutex);
-+
-+              switch(chip->state) {
-+              case FL_READY:
-+              case FL_STATUS:
-+              case FL_CFI_QUERY:
-+              case FL_JEDEC_QUERY:
-+                      chip->oldstate = chip->state;
-+                      chip->state = FL_SYNCING;
-+                      /* No need to wake_up() on this state change - 
-+                       * as the whole point is that nobody can do anything
-+                       * with the chip now anyway.
-+                       */
-+              case FL_SYNCING:
-+                      cfi_spin_unlock(chip->mutex);
-+                      break;
-+
-+              default:
-+                      /* Not an idle state */
-+                      add_wait_queue(&chip->wq, &wait);
-+                      
-+                      cfi_spin_unlock(chip->mutex);
-+
-+                      schedule();
-+
-+                      remove_wait_queue(&chip->wq, &wait);
-+                      
-+                      goto retry;
-+              }
-+      }
-+
-+      /* Unlock the chips again */
-+
-+      for (i--; i >=0; i--) {
-+              chip = &cfi->chips[i];
-+
-+              cfi_spin_lock(chip->mutex);
-+              
-+              if (chip->state == FL_SYNCING) {
-+                      chip->state = chip->oldstate;
-+                      wake_up(&chip->wq);
-+              }
-+              cfi_spin_unlock(chip->mutex);
-+      }
-+}
-+
-+
-+static int cfi_sststd_suspend(struct mtd_info *mtd)
-+{
-+      struct map_info *map = mtd->priv;
-+      struct cfi_private *cfi = map->fldrv_priv;
-+      int i;
-+      struct flchip *chip;
-+      int ret = 0;
-+//printk("suspend\n");
-+
-+      for (i=0; !ret && i<cfi->numchips; i++) {
-+              chip = &cfi->chips[i];
-+
-+              cfi_spin_lock(chip->mutex);
-+
-+              switch(chip->state) {
-+              case FL_READY:
-+              case FL_STATUS:
-+              case FL_CFI_QUERY:
-+              case FL_JEDEC_QUERY:
-+                      chip->oldstate = chip->state;
-+                      chip->state = FL_PM_SUSPENDED;
-+                      /* No need to wake_up() on this state change - 
-+                       * as the whole point is that nobody can do anything
-+                       * with the chip now anyway.
-+                       */
-+              case FL_PM_SUSPENDED:
-+                      break;
-+
-+              default:
-+                      ret = -EAGAIN;
-+                      break;
-+              }
-+              cfi_spin_unlock(chip->mutex);
-+      }
-+
-+      /* Unlock the chips again */
-+
-+      if (ret) {
-+              for (i--; i >=0; i--) {
-+                      chip = &cfi->chips[i];
-+
-+                      cfi_spin_lock(chip->mutex);
-+              
-+                      if (chip->state == FL_PM_SUSPENDED) {
-+                              chip->state = chip->oldstate;
-+                              wake_up(&chip->wq);
-+                      }
-+                      cfi_spin_unlock(chip->mutex);
-+              }
-+      }
-+      
-+      return ret;
-+}
-+
-+static void cfi_sststd_resume(struct mtd_info *mtd)
-+{
-+      struct map_info *map = mtd->priv;
-+      struct cfi_private *cfi = map->fldrv_priv;
-+      int i;
-+      struct flchip *chip;
-+//printk("resume\n");
-+
-+      for (i=0; i<cfi->numchips; i++) {
-+      
-+              chip = &cfi->chips[i];
-+
-+              cfi_spin_lock(chip->mutex);
-+              
-+              if (chip->state == FL_PM_SUSPENDED) {
-+                      chip->state = FL_READY;
-+                      cfi_write(map, CMD(0xF0), chip->start);
-+                      wake_up(&chip->wq);
-+              }
-+              else
-+                      printk("Argh. Chip not in PM_SUSPENDED state upon resume()\n");
-+
-+              cfi_spin_unlock(chip->mutex);
-+      }
-+}
-+
-+static void cfi_sststd_destroy(struct mtd_info *mtd)
-+{
-+      struct map_info *map = mtd->priv;
-+      struct cfi_private *cfi = map->fldrv_priv;
-+      kfree(cfi->cmdset_priv);
-+      kfree(cfi);
-+}
-+
-+#if LINUX_VERSION_CODE < 0x20212 && defined(MODULE)
-+#define cfi_sststd_init init_module
-+#define cfi_sststd_exit cleanup_module
-+#endif
-+
-+static char im_name[]="cfi_cmdset_0701";
-+
-+mod_init_t cfi_sststd_init(void)
-+{
-+      inter_module_register(im_name, THIS_MODULE, &cfi_cmdset_0701);
-+      return 0;
-+}
-+
-+mod_exit_t cfi_sststd_exit(void)
-+{
-+      inter_module_unregister(im_name);
-+}
-+
-+module_init(cfi_sststd_init);
-+module_exit(cfi_sststd_exit);
-+
-diff -Nur linux-2.4.30/drivers/mtd/chips/cfi_probe.c linux-2.4.30-brcm/drivers/mtd/chips/cfi_probe.c
---- linux-2.4.30/drivers/mtd/chips/cfi_probe.c 2003-06-13 16:51:34.000000000 +0200
-+++ linux-2.4.30-brcm/drivers/mtd/chips/cfi_probe.c    2005-05-22 22:55:52.000000000 +0200
-@@ -67,8 +67,15 @@
-       cfi_send_gen_cmd(0xF0, 0, base, map, cfi, cfi->device_type, NULL);
-       cfi_send_gen_cmd(0x98, 0x55, base, map, cfi, cfi->device_type, NULL);
--      if (!qry_present(map,base,cfi))
--              return 0;
-+      if (!qry_present(map,base,cfi)) {
-+              /* rather broken SST cfi probe (requires SST unlock) */
-+              cfi_send_gen_cmd(0xF0, 0, base, map, cfi, cfi->device_type, NULL);
-+              cfi_send_gen_cmd(0xAA, 0x5555, base, map, cfi, cfi->device_type, NULL);
-+              cfi_send_gen_cmd(0x55, 0x2AAA, base, map, cfi, cfi->device_type, NULL);
-+              cfi_send_gen_cmd(0x98, 0x5555, base, map, cfi, cfi->device_type, NULL);
-+              if (!qry_present(map,base,cfi))
-+                      return 0;
-+      }
-       if (!cfi->numchips) {
-               /* This is the first time we're called. Set up the CFI 
-diff -Nur linux-2.4.30/drivers/mtd/chips/Config.in linux-2.4.30-brcm/drivers/mtd/chips/Config.in
---- linux-2.4.30/drivers/mtd/chips/Config.in   2003-06-13 16:51:34.000000000 +0200
-+++ linux-2.4.30-brcm/drivers/mtd/chips/Config.in      2005-05-22 22:55:52.000000000 +0200
-@@ -45,6 +45,7 @@
- dep_tristate '  Support for Intel/Sharp flash chips' CONFIG_MTD_CFI_INTELEXT $CONFIG_MTD_GEN_PROBE
- dep_tristate '  Support for AMD/Fujitsu flash chips' CONFIG_MTD_CFI_AMDSTD $CONFIG_MTD_GEN_PROBE
- dep_tristate '  Support for ST (Advanced Architecture) flash chips' CONFIG_MTD_CFI_STAA $CONFIG_MTD_GEN_PROBE
-+dep_tristate '  Support for SST flash chips' CONFIG_MTD_CFI_SSTSTD $CONFIG_MTD_GEN_PROBE
- dep_tristate '  Support for RAM chips in bus mapping' CONFIG_MTD_RAM $CONFIG_MTD
- dep_tristate '  Support for ROM chips in bus mapping' CONFIG_MTD_ROM $CONFIG_MTD
-diff -Nur linux-2.4.30/drivers/mtd/chips/gen_probe.c linux-2.4.30-brcm/drivers/mtd/chips/gen_probe.c
---- linux-2.4.30/drivers/mtd/chips/gen_probe.c 2003-08-25 13:44:42.000000000 +0200
-+++ linux-2.4.30-brcm/drivers/mtd/chips/gen_probe.c    2005-05-22 22:55:52.000000000 +0200
-@@ -332,9 +332,13 @@
-               return cfi_cmdset_0002(map, primary);
- #endif
- #ifdef CONFIG_MTD_CFI_STAA
--        case 0x0020:
-+      case 0x0020:
-               return cfi_cmdset_0020(map, primary);
- #endif
-+#ifdef CONFIG_MTD_CFI_SSTSTD
-+      case 0x0701:
-+              return cfi_cmdset_0701(map, primary);
-+#endif
-       }
-       return cfi_cmdset_unknown(map, primary);
-diff -Nur linux-2.4.30/drivers/mtd/chips/Makefile linux-2.4.30-brcm/drivers/mtd/chips/Makefile
---- linux-2.4.30/drivers/mtd/chips/Makefile    2003-06-13 16:51:34.000000000 +0200
-+++ linux-2.4.30-brcm/drivers/mtd/chips/Makefile       2005-05-22 22:55:52.000000000 +0200
-@@ -18,6 +18,7 @@
- obj-$(CONFIG_MTD_AMDSTD)      += amd_flash.o 
- obj-$(CONFIG_MTD_CFI)         += cfi_probe.o
- obj-$(CONFIG_MTD_CFI_STAA)    += cfi_cmdset_0020.o
-+obj-$(CONFIG_MTD_CFI_SSTSTD)   += cfi_cmdset_0701.o
- obj-$(CONFIG_MTD_CFI_AMDSTD)  += cfi_cmdset_0002.o
- obj-$(CONFIG_MTD_CFI_INTELEXT)        += cfi_cmdset_0001.o
- obj-$(CONFIG_MTD_GEN_PROBE)   += gen_probe.o
-diff -Nur linux-2.4.30/drivers/mtd/maps/bcm947xx-flash.c linux-2.4.30-brcm/drivers/mtd/maps/bcm947xx-flash.c
---- linux-2.4.30/drivers/mtd/maps/bcm947xx-flash.c     1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/mtd/maps/bcm947xx-flash.c        2005-05-22 22:55:52.000000000 +0200
-@@ -0,0 +1,236 @@
-+/*
-+ * Flash mapping for BCM947XX boards
-+ *
-+ * Copyright 2004, Broadcom Corporation
-+ * All Rights Reserved.
-+ * 
-+ * THIS SOFTWARE IS OFFERED "AS IS", AND BROADCOM GRANTS NO WARRANTIES OF ANY
-+ * KIND, EXPRESS OR IMPLIED, BY STATUTE, COMMUNICATION OR OTHERWISE. BROADCOM
-+ * SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS
-+ * FOR A SPECIFIC PURPOSE OR NONINFRINGEMENT CONCERNING THIS SOFTWARE.
-+ *
-+ * $Id: bcm947xx-flash.c,v 1.1 2005/03/16 13:50:00 wbx Exp $
-+ */
-+
-+#include <linux/module.h>
-+#include <linux/types.h>
-+#include <linux/kernel.h>
-+#include <asm/io.h>
-+#include <linux/mtd/mtd.h>
-+#include <linux/mtd/map.h>
-+#include <linux/mtd/partitions.h>
-+#include <linux/config.h>
-+
-+#include <typedefs.h>
-+#include <bcmnvram.h>
-+#include <bcmutils.h>
-+#include <sbconfig.h>
-+#include <sbchipc.h>
-+#include <sbutils.h>
-+#include <trxhdr.h>
-+
-+/* Global SB handle */
-+extern void *bcm947xx_sbh;
-+extern spinlock_t bcm947xx_sbh_lock;
-+
-+/* Convenience */
-+#define sbh bcm947xx_sbh
-+#define sbh_lock bcm947xx_sbh_lock
-+
-+#ifdef CONFIG_MTD_PARTITIONS
-+extern struct mtd_partition * init_mtd_partitions(struct mtd_info *mtd, size_t size);
-+#endif
-+
-+#define WINDOW_ADDR 0x1fc00000
-+#define WINDOW_SIZE 0x400000
-+#define BUSWIDTH 2
-+
-+/* e.g., flash=2M or flash=4M */
-+static int flash = 0;
-+MODULE_PARM(flash, "i");
-+static int __init
-+bcm947xx_setup(char *str)
-+{
-+      flash = memparse(str, &str);
-+      return 1;
-+}
-+__setup("flash=", bcm947xx_setup);
-+
-+static struct mtd_info *bcm947xx_mtd;
-+
-+__u8 bcm947xx_map_read8(struct map_info *map, unsigned long ofs)
-+{
-+      if (map->map_priv_2 == 1)
-+              return __raw_readb(map->map_priv_1 + ofs);
-+
-+      u16 val = __raw_readw(map->map_priv_1 + (ofs & ~1));
-+      if (ofs & 1)
-+              return ((val >> 8) & 0xff);
-+      else
-+              return (val & 0xff);
-+}
-+
-+__u16 bcm947xx_map_read16(struct map_info *map, unsigned long ofs)
-+{
-+      return __raw_readw(map->map_priv_1 + ofs);
-+}
-+
-+__u32 bcm947xx_map_read32(struct map_info *map, unsigned long ofs)
-+{
-+      return __raw_readl(map->map_priv_1 + ofs);
-+}
-+
-+void bcm947xx_map_copy_from(struct map_info *map, void *to, unsigned long from, ssize_t len)
-+{
-+      if (len==1) {
-+              memcpy_fromio(to, map->map_priv_1 + from, len);
-+      } else {
-+              int i;
-+              u16 *dest = (u16 *) to;
-+              u16 *src  = (u16 *) (map->map_priv_1 + from);
-+              for (i = 0; i < (len / 2); i++) {
-+                      dest[i] = src[i];
-+              }
-+              if (len & 1)
-+                      *((u8 *)dest+len-1) = src[i] & 0xff;
-+      }
-+}
-+
-+void bcm947xx_map_write8(struct map_info *map, __u8 d, unsigned long adr)
-+{
-+      __raw_writeb(d, map->map_priv_1 + adr);
-+      mb();
-+}
-+
-+void bcm947xx_map_write16(struct map_info *map, __u16 d, unsigned long adr)
-+{
-+      __raw_writew(d, map->map_priv_1 + adr);
-+      mb();
-+}
-+
-+void bcm947xx_map_write32(struct map_info *map, __u32 d, unsigned long adr)
++void bcm947xx_map_write32(struct map_info *map, __u32 d, unsigned long adr)
 +{
 +      __raw_writel(d, map->map_priv_1 + adr);
 +      mb();
@@ -13981,335 +13259,86 @@ diff -Nur linux-2.4.30/drivers/mtd/maps/bcm947xx-flash.c linux-2.4.30-brcm/drive
 +
 +mod_exit_t cleanup_bcm947xx_map(void)
 +{
-+#ifdef CONFIG_MTD_PARTITIONS
-+      del_mtd_partitions(bcm947xx_mtd);
-+#endif
-+      map_destroy(bcm947xx_mtd);
-+      iounmap((void *) bcm947xx_map.map_priv_1);
-+      bcm947xx_map.map_priv_1 = 0;
-+}
-+
-+module_init(init_bcm947xx_map);
-+module_exit(cleanup_bcm947xx_map);
-diff -Nur linux-2.4.30/drivers/mtd/maps/Config.in linux-2.4.30-brcm/drivers/mtd/maps/Config.in
---- linux-2.4.30/drivers/mtd/maps/Config.in    2003-06-13 16:51:34.000000000 +0200
-+++ linux-2.4.30-brcm/drivers/mtd/maps/Config.in       2005-05-25 18:58:03.000000000 +0200
-@@ -48,6 +48,7 @@
- fi
- if [ "$CONFIG_MIPS" = "y" ]; then
-+   dep_tristate '  CFI Flash device mapped on Broadcom BCM947XX boards' CONFIG_MTD_BCM947XX $CONFIG_MTD_CFI
-    dep_tristate '  Pb1000 MTD support' CONFIG_MTD_PB1000 $CONFIG_MIPS_PB1000
-    dep_tristate '  Pb1500 MTD support' CONFIG_MTD_PB1500 $CONFIG_MIPS_PB1500
-    dep_tristate '  Pb1100 MTD support' CONFIG_MTD_PB1100 $CONFIG_MIPS_PB1100
-diff -Nur linux-2.4.30/drivers/mtd/maps/Makefile linux-2.4.30-brcm/drivers/mtd/maps/Makefile
---- linux-2.4.30/drivers/mtd/maps/Makefile     2003-06-13 16:51:34.000000000 +0200
-+++ linux-2.4.30-brcm/drivers/mtd/maps/Makefile        2005-05-25 18:57:31.000000000 +0200
-@@ -3,6 +3,8 @@
- #
- # $Id: Makefile,v 1.37 2003/01/24 14:26:38 dwmw2 Exp $
-+EXTRA_CFLAGS := -I$(TOPDIR)/arch/mips/bcm947xx/include
-+
- BELOW25               := $(shell echo $(PATCHLEVEL) | sed s/[1234]/y/)
- ifeq ($(BELOW25),y)
-@@ -10,6 +12,7 @@
- endif
- # Chip mappings
-+obj-$(CONFIG_MTD_BCM947XX)    += bcm947xx-flash.o
- obj-$(CONFIG_MTD_CDB89712)    += cdb89712.o
- obj-$(CONFIG_MTD_ARM_INTEGRATOR)+= integrator-flash.o
- obj-$(CONFIG_MTD_CFI_FLAGADM) += cfi_flagadm.o
-diff -Nur linux-2.4.30/drivers/net/Config.in linux-2.4.30-brcm/drivers/net/Config.in
---- linux-2.4.30/drivers/net/Config.in 2005-01-19 15:09:56.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/net/Config.in    2005-05-25 04:34:51.000000000 +0200
-@@ -2,6 +2,8 @@
- # Network device configuration
- #
-+tristate 'Broadcom Home Network Division' CONFIG_HND $CONFIG_PCI
-+
- source drivers/net/arcnet/Config.in
- tristate 'Dummy net driver support' CONFIG_DUMMY
-@@ -173,6 +175,7 @@
-       dep_tristate '    Apricot Xen-II on board Ethernet' CONFIG_APRICOT $CONFIG_ISA
-       dep_tristate '    Broadcom 4400 ethernet support (EXPERIMENTAL)' CONFIG_B44 $CONFIG_PCI $CONFIG_EXPERIMENTAL
-+      dep_tristate '    Proprietary Broadcom 10/100 Ethernet support' CONFIG_ET $CONFIG_PCI
-       dep_tristate '    CS89x0 support' CONFIG_CS89x0 $CONFIG_ISA
-       dep_tristate '    DECchip Tulip (dc21x4x) PCI support' CONFIG_TULIP $CONFIG_PCI
-       if [ "$CONFIG_TULIP" = "y" -o "$CONFIG_TULIP" = "m" ]; then
-diff -Nur linux-2.4.30/drivers/net/diag/diag_led.c linux-2.4.30-brcm/drivers/net/diag/diag_led.c
---- linux-2.4.30/drivers/net/diag/diag_led.c   1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/net/diag/diag_led.c      2005-05-25 20:41:19.000000000 +0200
-@@ -0,0 +1,244 @@
-+/*
-+ * diag_led.c - replacement diag module
-+ *
-+ * Copyright (C) 2004 Mike Baker,
-+ *                    Imre Kaloz <kaloz@dune.hu>
-+ *
-+ * This program is free software; you can redistribute it and/or
-+ * modify it under the terms of the GNU General Public License
-+ * as published by the Free Software Foundation; either version 2
-+ * of the License, or (at your option) any later version.
-+ *
-+ * This program is distributed in the hope that it will be useful,
-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-+ * GNU General Public License for more details.
-+ *
-+ * You should have received a copy of the GNU General Public License
-+ * along with this program; if not, write to the Free Software
-+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
-+ *
-+ * $Id: diag_led.c,v 1.5 2005/04/18 09:05:24 mbm Exp $
-+ */
-+
-+/*
-+ * ChangeLog:
-+ * 2004/03/28 initial release 
-+ * 2004/08/26 asus & buffalo support added
-+ * 2005/03/14 asus wl-500g deluxe and buffalo v2 support added
-+ * 2005/04/13 added licensing informations
-+ * 2005/04/18 base reset polarity off initial readings
-+ */
-+
-+#include <linux/module.h>
-+#include <linux/init.h>
-+#include <linux/kernel.h>
-+#include <linux/sysctl.h>
-+#include <asm/io.h>
-+#include <typedefs.h>
-+#include <bcmdevs.h>
-+#include <sbutils.h>
-+
-+extern char * nvram_get(const char *name);
-+static void *sbh;
-+
-+// v2.x - - - - -
-+#define DIAG_GPIO (1<<1)
-+#define DMZ_GPIO  (1<<7)
-+
-+static void set_gpio(uint32 mask, uint32 value) {
-+      sb_gpiocontrol(sbh,mask,0);
-+      sb_gpioouten(sbh,mask,mask);
-+      sb_gpioout(sbh,mask,value);
-+}
-+
-+static void v2_set_diag(u8 state) {
-+      set_gpio(DIAG_GPIO,state);
-+}
-+static void v2_set_dmz(u8 state) {
-+      set_gpio(DMZ_GPIO,state);
-+}
-+
-+// v1.x - - - - -
-+#define LED_DIAG   0x13
-+#define LED_DMZ    0x12
-+
-+static void v1_set_diag(u8 state) {
-+      if (!state) {
-+              *(volatile u8*)(KSEG1ADDR(BCM4710_EUART)+LED_DIAG)=0xFF;
-+      } else {
-+              *(volatile u8*)(KSEG1ADDR(BCM4710_EUART)+LED_DIAG);
-+      }
-+}
-+static void v1_set_dmz(u8 state) {
-+      if (!state) {
-+              *(volatile u8*)(KSEG1ADDR(BCM4710_EUART)+LED_DMZ)=0xFF;
-+      } else {
-+              *(volatile u8*)(KSEG1ADDR(BCM4710_EUART)+LED_DMZ);
-+      }
-+}
-+
-+// - - - - -
-+static void ignore(u8 ignored) {};
-+
-+// - - - - -
-+#define BIT_DMZ         0x01
-+#define BIT_DIAG        0x04
-+
-+void (*set_diag)(u8 state);
-+void (*set_dmz)(u8 state);
-+
-+static unsigned int diag = 0;
-+
-+static void diag_change()
-+{
-+      set_diag(0xFF); // off
-+      set_dmz(0xFF); // off
-+
-+      if(diag & BIT_DIAG)
-+              set_diag(0x00); // on
-+      if(diag & BIT_DMZ)
-+              set_dmz(0x00); // on
-+}
-+
-+static int proc_diag(ctl_table *table, int write, struct file *filp,
-+              void *buffer, size_t *lenp)
-+{
-+      int r;
-+      r = proc_dointvec(table, write, filp, buffer, lenp);
-+      if (write && !r) {
-+              diag_change();
-+      }
-+      return r;
-+}
-+
-+// - - - - -
-+static unsigned char reset_gpio = 0;
-+static unsigned char reset_polarity = 0;
-+static unsigned int reset = 0;
-+
-+static int proc_reset(ctl_table *table, int write, struct file *filp,
-+              void *buffer, size_t *lenp)
-+{
-+
-+      if (reset_gpio) {
-+              sb_gpiocontrol(sbh,reset_gpio,reset_gpio);
-+              sb_gpioouten(sbh,reset_gpio,0);
-+              reset=!(sb_gpioin(sbh)&reset_gpio);
-+
-+              if (reset_polarity) reset=!reset;
-+      } else {
-+              reset=0;
-+      }
-+
-+      return proc_dointvec(table, write, filp, buffer, lenp);
-+}
-+
-+// - - - - -
-+static struct ctl_table_header *diag_sysctl_header;
-+
-+static ctl_table sys_diag[] = {
-+         { 
-+         ctl_name: 2000,
-+         procname: "diag", 
-+         data: &diag,
-+         maxlen: sizeof(diag), 
-+         mode: 0644,
-+         proc_handler: proc_diag
-+       },
-+       {
-+         ctl_name: 2001,
-+         procname: "reset",
-+         data: &reset,
-+         maxlen: sizeof(reset),
-+         mode: 0444,
-+         proc_handler: proc_reset 
-+       },
-+         { 0 }
-+};
-+
-+static int __init diag_init()
-+{
-+      char *buf;
-+      u32 board_type;
-+      sbh = sb_kattach();
-+      sb_gpiosetcore(sbh);
-+
-+      board_type = sb_boardtype(sbh);
-+      printk(KERN_INFO "diag boardtype: %08x\n",board_type);
-+
-+      set_diag=ignore;
-+      set_dmz=ignore;
-+      
-+      if ((board_type & 0xf00) == 0x400) {
-+              buf=nvram_get("boardtype")?:"";
-+              if (!strcmp(buf,"bcm94710dev")) {
-+                      buf=nvram_get("boardnum")?:"";
-+                      if (!strcmp(buf,"42")) {
-+                              // wrt54g v1.x
-+                              set_diag=v1_set_diag;
-+                              set_dmz=v1_set_dmz;
-+                              reset_gpio=(1<<6);
-+                      }
-+                      if (!strcmp(buf,"asusX")) {
-+                              //asus wl-500g
-+                              reset_gpio=(1<<6);
-+                      }
-+              }
-+              if (!strcmp(buf,"bcm94710ap")) {
-+                      buf=nvram_get("boardnum")?:"";
-+                      if (!strcmp(buf,"42")) {
-+                              // buffalo
-+                              set_dmz=v2_set_dmz;
-+                              reset_gpio=(1<<4);
-+                      }
-+                      if (!strcmp(buf,"44")) {
-+                              //dell truemobile
-+                              set_dmz=v2_set_dmz;
-+                              reset_gpio=(1<<0);
-+                      }
-+              }
-+      } else {
-+              buf=nvram_get("boardnum")?:"";
-+              if (!strcmp(buf,"42")) {
-+                      //linksys
-+                      set_diag=v2_set_diag;
-+                      set_dmz=v2_set_dmz;
-+                      reset_gpio=(1<<6);
-+              }
-+              if (!strcmp(buf,"44")) {
-+                      //motorola
-+                      reset_gpio=(1<<5);
-+              }
-+              if (!strcmp(buf,"00")) {
-+                      //buffalo
-+                      reset_gpio=(1<<7);
-+              }
-+              if (!strcmp(buf,"45")) {
-+                      //wl-500g deluxe
-+                      reset_gpio=(1<<6);
-+              }
-+      }
-+
-+      
-+      sb_gpiocontrol(sbh,reset_gpio,reset_gpio);
-+      sb_gpioouten(sbh,reset_gpio,0);
-+      reset_polarity=!(sb_gpioin(sbh)&reset_gpio);
-+
-+      diag_sysctl_header = register_sysctl_table(sys_diag, 0);
-+      diag_change();
-+
-+      return 0;
-+}
-+
-+static void __exit diag_exit()
-+{
-+      unregister_sysctl_table(diag_sysctl_header);
++#ifdef CONFIG_MTD_PARTITIONS
++      del_mtd_partitions(bcm947xx_mtd);
++#endif
++      map_destroy(bcm947xx_mtd);
++      iounmap((void *) bcm947xx_map.map_priv_1);
++      bcm947xx_map.map_priv_1 = 0;
 +}
 +
-+EXPORT_NO_SYMBOLS;
-+MODULE_AUTHOR("openwrt.org");
-+MODULE_LICENSE("GPL");
-+
-+module_init(diag_init);
-+module_exit(diag_exit);
-diff -Nur linux-2.4.30/drivers/net/diag/Makefile linux-2.4.30-brcm/drivers/net/diag/Makefile
---- linux-2.4.30/drivers/net/diag/Makefile     1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/net/diag/Makefile        2005-05-26 17:13:16.000000000 +0200
-@@ -0,0 +1,13 @@
-+#$Id$
-+
-+EXTRA_CFLAGS := -I$(TOPDIR)/arch/mips/bcm947xx/include -DBCMDRIVER
++module_init(init_bcm947xx_map);
++module_exit(cleanup_bcm947xx_map);
+diff -urN linux.old/drivers/net/Config.in linux.dev/drivers/net/Config.in
+--- linux.old/drivers/net/Config.in    2005-08-26 13:41:43.481361784 +0200
++++ linux.dev/drivers/net/Config.in    2005-08-26 13:44:34.358384528 +0200
+@@ -2,6 +2,8 @@
+ # Network device configuration
+ #
++tristate 'Broadcom Home Network Division' CONFIG_HND $CONFIG_PCI
 +
-+O_TARGET       := diag.o
+ source drivers/net/arcnet/Config.in
+ tristate 'Dummy net driver support' CONFIG_DUMMY
+@@ -174,6 +176,7 @@
+       dep_tristate '    Apricot Xen-II on board Ethernet' CONFIG_APRICOT $CONFIG_ISA
+       dep_tristate '    Broadcom 4400 ethernet support (EXPERIMENTAL)' CONFIG_B44 $CONFIG_PCI $CONFIG_EXPERIMENTAL
++      dep_tristate '    Proprietary Broadcom 10/100 Ethernet support' CONFIG_ET $CONFIG_PCI
+       dep_tristate '    CS89x0 support' CONFIG_CS89x0 $CONFIG_ISA
+       dep_tristate '    DECchip Tulip (dc21x4x) PCI support' CONFIG_TULIP $CONFIG_PCI
+       if [ "$CONFIG_TULIP" = "y" -o "$CONFIG_TULIP" = "m" ]; then
+diff -urN linux.old/drivers/net/Makefile linux.dev/drivers/net/Makefile
+--- linux.old/drivers/net/Makefile     2005-08-26 13:41:43.082422432 +0200
++++ linux.dev/drivers/net/Makefile     2005-08-26 13:44:34.370382704 +0200
+@@ -3,6 +3,8 @@
+ # Makefile for the Linux network (ethercard) device drivers.
+ #
++EXTRA_CFLAGS := -I$(TOPDIR)/arch/mips/bcm947xx/include
 +
-+MAC_OBJS       := diag_led.o
+ obj-y           :=
+ obj-m           :=
+ obj-n           :=
+@@ -39,6 +41,9 @@
+   obj-$(CONFIG_ISDN) += slhc.o
+ endif
++subdir-$(CONFIG_HND) += hnd
++subdir-$(CONFIG_ET) += et
++subdir-$(CONFIG_WL) += wl
+ subdir-$(CONFIG_NET_PCMCIA) += pcmcia
+ subdir-$(CONFIG_NET_WIRELESS) += wireless
+ subdir-$(CONFIG_TULIP) += tulip
+@@ -69,6 +74,16 @@
+ obj-$(CONFIG_MYRI_SBUS) += myri_sbus.o
+ obj-$(CONFIG_SUNGEM) += sungem.o
++ifeq ($(CONFIG_HND),y)
++  obj-y += hnd/hnd.o
++endif
++ifeq ($(CONFIG_ET),y)
++  obj-y += et/et.o
++endif
++ifeq ($(CONFIG_WL),y)
++  obj-y += wl/wl.o
++endif
 +
-+export-objs    := 
-+obj-y          := $(MAC_OBJS)
-+obj-m          := $(O_TARGET)
+ obj-$(CONFIG_MACE) += mace.o
+ obj-$(CONFIG_BMAC) += bmac.o
+ obj-$(CONFIG_GMAC) += gmac.o
+@@ -266,6 +281,7 @@
+ endif
+ endif
 +
-+include $(TOPDIR)/Rules.make
-diff -Nur linux-2.4.30/drivers/net/et/Makefile linux-2.4.30-brcm/drivers/net/et/Makefile
---- linux-2.4.30/drivers/net/et/Makefile       1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/net/et/Makefile  2005-05-26 02:37:05.000000000 +0200
+ include $(TOPDIR)/Rules.make
+ clean:
+diff -urN linux.old/drivers/net/et/Makefile linux.dev/drivers/net/et/Makefile
+--- linux.old/drivers/net/et/Makefile  1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/drivers/net/et/Makefile  2005-08-26 13:44:34.371382552 +0200
 @@ -0,0 +1,21 @@
 +#
 +# Makefile for the Broadcom et driver
@@ -14332,9 +13361,32 @@ diff -Nur linux-2.4.30/drivers/net/et/Makefile linux-2.4.30-brcm/drivers/net/et/
 +obj-m         := $(O_TARGET)
 +
 +include $(TOPDIR)/Rules.make
-diff -Nur linux-2.4.30/drivers/net/hnd/bcmsrom.c linux-2.4.30-brcm/drivers/net/hnd/bcmsrom.c
---- linux-2.4.30/drivers/net/hnd/bcmsrom.c     1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/net/hnd/bcmsrom.c        2005-05-22 23:00:53.000000000 +0200
+diff -urN linux.old/drivers/net/hnd/Makefile linux.dev/drivers/net/hnd/Makefile
+--- linux.old/drivers/net/hnd/Makefile 1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/drivers/net/hnd/Makefile 2005-08-26 13:44:34.371382552 +0200
+@@ -0,0 +1,19 @@
++#
++# Makefile for the BCM47xx specific kernel interface routines
++# under Linux.
++#
++
++EXTRA_CFLAGS  += -I$(TOPDIR)/arch/mips/bcm947xx/include -DBCMDRIVER
++
++O_TARGET      := hnd.o
++
++HND_OBJS      := bcmutils.o hnddma.o linux_osl.o sbutils.o bcmsrom.o
++
++export-objs   := shared_ksyms.o
++obj-y         := shared_ksyms.o $(HND_OBJS)
++obj-m           := $(O_TARGET)
++
++include $(TOPDIR)/Rules.make
++
++shared_ksyms.c: shared_ksyms.sh $(HND_OBJS)
++      sh -e $< $(HND_OBJS) > $@
+diff -urN linux.old/drivers/net/hnd/bcmsrom.c linux.dev/drivers/net/hnd/bcmsrom.c
+--- linux.old/drivers/net/hnd/bcmsrom.c        1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/drivers/net/hnd/bcmsrom.c        2005-08-26 13:44:34.372382400 +0200
 @@ -0,0 +1,714 @@
 +/*
 + *  Misc useful routines to access NIC SROM/OTP .
@@ -15050,9 +14102,9 @@ diff -Nur linux-2.4.30/drivers/net/hnd/bcmsrom.c linux-2.4.30-brcm/drivers/net/h
 +      return (rc);
 +}
 +
-diff -Nur linux-2.4.30/drivers/net/hnd/bcmutils.c linux-2.4.30-brcm/drivers/net/hnd/bcmutils.c
---- linux-2.4.30/drivers/net/hnd/bcmutils.c    1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/net/hnd/bcmutils.c       2005-05-24 20:26:25.000000000 +0200
+diff -urN linux.old/drivers/net/hnd/bcmutils.c linux.dev/drivers/net/hnd/bcmutils.c
+--- linux.old/drivers/net/hnd/bcmutils.c       1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/drivers/net/hnd/bcmutils.c       2005-08-26 13:44:34.374382096 +0200
 @@ -0,0 +1,862 @@
 +/*
 + * Misc useful OS-independent routines.
@@ -15916,9 +14968,9 @@ diff -Nur linux-2.4.30/drivers/net/hnd/bcmutils.c linux-2.4.30-brcm/drivers/net/
 +}
 +
 +
-diff -Nur linux-2.4.30/drivers/net/hnd/hnddma.c linux-2.4.30-brcm/drivers/net/hnd/hnddma.c
---- linux-2.4.30/drivers/net/hnd/hnddma.c      1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/net/hnd/hnddma.c 2005-05-25 01:12:49.000000000 +0200
+diff -urN linux.old/drivers/net/hnd/hnddma.c linux.dev/drivers/net/hnd/hnddma.c
+--- linux.old/drivers/net/hnd/hnddma.c 1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/drivers/net/hnd/hnddma.c 2005-08-26 13:44:34.375381944 +0200
 @@ -0,0 +1,865 @@
 +/*
 + * Generic Broadcom Home Networking Division (HND) DMA module.
@@ -16785,9 +15837,9 @@ diff -Nur linux-2.4.30/drivers/net/hnd/hnddma.c linux-2.4.30-brcm/drivers/net/hn
 +      /* kick the chip */
 +      W_REG(&di->regs->xmtptr, I2B(di->txout));
 +}
-diff -Nur linux-2.4.30/drivers/net/hnd/linux_osl.c linux-2.4.30-brcm/drivers/net/hnd/linux_osl.c
---- linux-2.4.30/drivers/net/hnd/linux_osl.c   1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/net/hnd/linux_osl.c      2005-05-22 23:01:31.000000000 +0200
+diff -urN linux.old/drivers/net/hnd/linux_osl.c linux.dev/drivers/net/hnd/linux_osl.c
+--- linux.old/drivers/net/hnd/linux_osl.c      1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/drivers/net/hnd/linux_osl.c      2005-08-26 13:44:34.376381792 +0200
 @@ -0,0 +1,640 @@
 +/*
 + * Linux OS Independent Layer
@@ -17429,45 +16481,22 @@ diff -Nur linux-2.4.30/drivers/net/hnd/linux_osl.c linux-2.4.30-brcm/drivers/net
 +}
 +
 +#endif        /* BINOSL */
-diff -Nur linux-2.4.30/drivers/net/hnd/Makefile linux-2.4.30-brcm/drivers/net/hnd/Makefile
---- linux-2.4.30/drivers/net/hnd/Makefile      1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/net/hnd/Makefile 2005-05-25 18:54:08.000000000 +0200
-@@ -0,0 +1,19 @@
-+#
-+# Makefile for the BCM47xx specific kernel interface routines
-+# under Linux.
-+#
-+
-+EXTRA_CFLAGS  += -I$(TOPDIR)/arch/mips/bcm947xx/include -DBCMDRIVER
-+
-+O_TARGET      := hnd.o
-+
-+HND_OBJS      := bcmutils.o hnddma.o linux_osl.o sbutils.o bcmsrom.o
-+
-+export-objs   := shared_ksyms.o
-+obj-y         := shared_ksyms.o $(HND_OBJS)
-+obj-m           := $(O_TARGET)
-+
-+include $(TOPDIR)/Rules.make
-+
-+shared_ksyms.c: shared_ksyms.sh $(HND_OBJS)
-+      sh -e $< $(HND_OBJS) > $@
-diff -Nur linux-2.4.30/drivers/net/hnd/sbutils.c linux-2.4.30-brcm/drivers/net/hnd/sbutils.c
---- linux-2.4.30/drivers/net/hnd/sbutils.c     1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/net/hnd/sbutils.c        2005-05-22 23:01:41.000000000 +0200
-@@ -0,0 +1,2063 @@
+diff -urN linux.old/drivers/net/hnd/sbutils.c linux.dev/drivers/net/hnd/sbutils.c
+--- linux.old/drivers/net/hnd/sbutils.c        1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/drivers/net/hnd/sbutils.c        2005-09-01 01:33:48.212447040 +0200
+@@ -0,0 +1,2061 @@
 +/*
 + * Misc utility routines for accessing chip-specific features
 + * of the SiliconBackplane-based Broadcom chips.
 + *
-+ * Copyright 2004, Broadcom Corporation
++ * Copyright 2005, Broadcom Corporation
 + * All Rights Reserved.
 + * 
 + * THIS SOFTWARE IS OFFERED "AS IS", AND BROADCOM GRANTS NO WARRANTIES OF ANY
 + * KIND, EXPRESS OR IMPLIED, BY STATUTE, COMMUNICATION OR OTHERWISE. BROADCOM
 + * SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS
 + * FOR A SPECIFIC PURPOSE OR NONINFRINGEMENT CONCERNING THIS SOFTWARE.
-+ * $Id$
++ * $Id: sbutils.c,v 1.6 2005/03/07 08:35:32 kanki Exp $
 + */
 +
 +#include <typedefs.h>
@@ -17487,8 +16516,6 @@ diff -Nur linux-2.4.30/drivers/net/hnd/sbutils.c linux-2.4.30-brcm/drivers/net/h
 +#define       SB_ERROR(args)
 +
 +
-+#define CLOCK_BASE_5350               12500000 /* Specific to 5350*/
-+
 +typedef uint32 (*sb_intrsoff_t)(void *intr_arg);
 +typedef void (*sb_intrsrestore_t)(void *intr_arg, uint32 arg);
 +typedef bool (*sb_intrsenabled_t)(void *intr_arg);
@@ -17705,7 +16732,7 @@ diff -Nur linux-2.4.30/drivers/net/hnd/sbutils.c linux-2.4.30-brcm/drivers/net/h
 +              cid = R_REG((uint32 *)regs);
 +              if (((cid & CID_ID_MASK) == BCM4712_DEVICE_ID) &&
 +                  ((cid & CID_PKG_MASK) != BCM4712LARGE_PKG_ID) &&
-+                  ((cid & CID_REV_MASK) <= 0x00020000)) {
++                  ((cid & CID_REV_MASK) <= (3 << CID_REV_SHIFT))) {
 +                      uint32 *scc, val;
 +
 +                      scc = (uint32 *)((uchar*)regs + OFFSETOF(chipcregs_t, slow_clk_ctl));
@@ -18840,7 +17867,10 @@ diff -Nur linux-2.4.30/drivers/net/hnd/sbutils.c linux-2.4.30-brcm/drivers/net/h
 +                      return CC_T6_M1;
 +              else
 +                      return CC_T6_M0;
-+      } else if ((pll_type == PLL_TYPE1) || (pll_type == PLL_TYPE4)|| (pll_type == PLL_TYPE3)) {
++      } else if ((pll_type == PLL_TYPE1) ||
++                 (pll_type == PLL_TYPE3) ||
++                 (pll_type == PLL_TYPE4) ||
++                 (pll_type == PLL_TYPE7)) {
 +              n1 = factor6(n1);
 +              n2 += CC_F5_BIAS;
 +      } else if (pll_type == PLL_TYPE2) {
@@ -18852,12 +17882,13 @@ diff -Nur linux-2.4.30/drivers/net/hnd/sbutils.c linux-2.4.30-brcm/drivers/net/h
 +              return (100000000);
 +      } else
 +              ASSERT((pll_type >= PLL_TYPE1) && (pll_type <= PLL_TYPE4));
-+
-+      /* Special case for 5350 */
-+      if (pll_type == PLL_TYPE3) 
-+              clock =  CLOCK_BASE_5350 * n1 * n2;
++      /* PLL types 3 and 7 use BASE2 (25Mhz) */
++      if ((pll_type == PLL_TYPE3) ||
++          (pll_type == PLL_TYPE7)) { 
++              clock =  CC_CLOCK_BASE2 * n1 * n2;
++      }
 +      else 
-+              clock = CC_CLOCK_BASE * n1 * n2;
++              clock = CC_CLOCK_BASE1 * n1 * n2;
 +
 +      if (clock == 0)
 +              return 0;
@@ -18867,7 +17898,10 @@ diff -Nur linux-2.4.30/drivers/net/hnd/sbutils.c linux-2.4.30-brcm/drivers/net/h
 +      m3 = (m & CC_M3_MASK) >> CC_M3_SHIFT;
 +      mc = (m & CC_MC_MASK) >> CC_MC_SHIFT;
 +
-+      if ((pll_type == PLL_TYPE1) || (pll_type == PLL_TYPE4) || (pll_type == PLL_TYPE3)) {
++      if ((pll_type == PLL_TYPE1) ||
++          (pll_type == PLL_TYPE3) ||
++          (pll_type == PLL_TYPE4) ||
++          (pll_type == PLL_TYPE7)) {
 +              m1 = factor6(m1);
 +              if ((pll_type == PLL_TYPE1) || (pll_type == PLL_TYPE3))
 +                      m2 += CC_F5_BIAS;
@@ -18931,13 +17965,8 @@ diff -Nur linux-2.4.30/drivers/net/hnd/sbutils.c linux-2.4.30-brcm/drivers/net/h
 +              n = R_REG(&cc->clockcontrol_n);
 +              if (pll_type == PLL_TYPE6)
 +                      m = R_REG(&cc->clockcontrol_mips);
-+              else if (pll_type == PLL_TYPE3)
-+              {
-+                      // Added by Chen-I for 5365 
-+                      if (BCMINIT(sb_chip)(sbh) == BCM5365_DEVICE_ID)         
-+                              m = R_REG(&cc->clockcontrol_sb);
-+                      else m = R_REG(&cc->clockcontrol_m2);
-+              }
++              else if ((pll_type == PLL_TYPE3) && (BCMINIT(sb_chip)(sbh) != BCM5365_DEVICE_ID))
++                      m = R_REG(&cc->clockcontrol_m2);
 +              else
 +                      m = R_REG(&cc->clockcontrol_sb);
 +      } else {
@@ -18945,18 +17974,16 @@ diff -Nur linux-2.4.30/drivers/net/hnd/sbutils.c linux-2.4.30-brcm/drivers/net/h
 +              return 0;
 +      }
 +
-+      // Added by Chen-I for 5365 
-+      if (BCMINIT(sb_chip)(sbh) == BCM5365_DEVICE_ID)
-+      {
-+              rate = 100000000;       
-+      }
-+      else
-+      {
++      if (BCMINIT(sb_chip)(sbh) == BCM5365_DEVICE_ID) {
++              rate = 100000000;
++      } else {
 +              /* calculate rate */
 +              rate = sb_clock_rate(pll_type, n, m);
-+              if (pll_type == PLL_TYPE3) rate = rate / 2;
++              if (pll_type == PLL_TYPE3)
++                      rate = rate / 2;
 +      }
 +
++
 +      /* switch back to previous core */
 +      sb_setcoreidx(sbh, idx);
 +
@@ -19519,9 +18546,9 @@ diff -Nur linux-2.4.30/drivers/net/hnd/sbutils.c linux-2.4.30-brcm/drivers/net/h
 +}
 +
 +
-diff -Nur linux-2.4.30/drivers/net/hnd/shared_ksyms.sh linux-2.4.30-brcm/drivers/net/hnd/shared_ksyms.sh
---- linux-2.4.30/drivers/net/hnd/shared_ksyms.sh       1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/net/hnd/shared_ksyms.sh  2005-05-22 22:55:51.000000000 +0200
+diff -urN linux.old/drivers/net/hnd/shared_ksyms.sh linux.dev/drivers/net/hnd/shared_ksyms.sh
+--- linux.old/drivers/net/hnd/shared_ksyms.sh  1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/drivers/net/hnd/shared_ksyms.sh  2005-08-26 13:44:34.406377232 +0200
 @@ -0,0 +1,21 @@
 +#!/bin/sh
 +#
@@ -19544,65 +18571,9 @@ diff -Nur linux-2.4.30/drivers/net/hnd/shared_ksyms.sh linux-2.4.30-brcm/drivers
 +for file in $* ; do
 +    ${NM} $file | sed -ne 's/[0-9A-Fa-f]* [DT] \([^ ]*\)/extern void \1; EXPORT_SYMBOL(\1);/p'
 +done
-diff -Nur linux-2.4.30/drivers/net/Makefile linux-2.4.30-brcm/drivers/net/Makefile
---- linux-2.4.30/drivers/net/Makefile  2005-01-19 15:09:56.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/net/Makefile     2005-05-25 19:07:52.000000000 +0200
-@@ -3,6 +3,8 @@
- # Makefile for the Linux network (ethercard) device drivers.
- #
-+EXTRA_CFLAGS := -I$(TOPDIR)/arch/mips/bcm947xx/include
-+
- obj-y           :=
- obj-m           :=
- obj-n           :=
-@@ -21,6 +23,8 @@
- list-multi    :=      rcpci.o
- rcpci-objs    :=      rcpci45.o rclanmtl.o
-+subdir-m += diag
-+
- ifeq ($(CONFIG_TULIP),y)
-   obj-y += tulip/tulip.o
- endif
-@@ -39,6 +43,9 @@
-   obj-$(CONFIG_ISDN) += slhc.o
- endif
-+subdir-$(CONFIG_HND) += hnd
-+subdir-$(CONFIG_ET) += et
-+subdir-$(CONFIG_WL) += wl
- subdir-$(CONFIG_NET_PCMCIA) += pcmcia
- subdir-$(CONFIG_NET_WIRELESS) += wireless
- subdir-$(CONFIG_TULIP) += tulip
-@@ -69,6 +76,16 @@
- obj-$(CONFIG_MYRI_SBUS) += myri_sbus.o
- obj-$(CONFIG_SUNGEM) += sungem.o
-+ifeq ($(CONFIG_HND),y)
-+  obj-y += hnd/hnd.o
-+endif
-+ifeq ($(CONFIG_ET),y)
-+  obj-y += et/et.o
-+endif
-+ifeq ($(CONFIG_WL),y)
-+  obj-y += wl/wl.o
-+endif
-+
- obj-$(CONFIG_MACE) += mace.o
- obj-$(CONFIG_BMAC) += bmac.o
- obj-$(CONFIG_GMAC) += gmac.o
-@@ -265,6 +282,7 @@
- endif
- endif
-+
- include $(TOPDIR)/Rules.make
- clean:
-diff -Nur linux-2.4.30/drivers/net/wireless/Config.in linux-2.4.30-brcm/drivers/net/wireless/Config.in
---- linux-2.4.30/drivers/net/wireless/Config.in        2004-11-17 12:54:21.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/net/wireless/Config.in   2005-05-22 22:55:52.000000000 +0200
+diff -urN linux.old/drivers/net/wireless/Config.in linux.dev/drivers/net/wireless/Config.in
+--- linux.old/drivers/net/wireless/Config.in   2004-11-17 12:54:21.000000000 +0100
++++ linux.dev/drivers/net/wireless/Config.in   2005-08-26 13:44:34.427374040 +0200
 @@ -13,6 +13,7 @@
  fi
  
@@ -19611,9 +18582,9 @@ diff -Nur linux-2.4.30/drivers/net/wireless/Config.in linux-2.4.30-brcm/drivers/
     dep_tristate '    Hermes in PLX9052 based PCI adaptor support (Netgear MA301 etc.) (EXPERIMENTAL)' CONFIG_PLX_HERMES $CONFIG_HERMES $CONFIG_EXPERIMENTAL
     dep_tristate '    Hermes in TMD7160/NCP130 based PCI adaptor support (Pheecom WL-PCI etc.) (EXPERIMENTAL)' CONFIG_TMD_HERMES $CONFIG_HERMES $CONFIG_EXPERIMENTAL
     dep_tristate '    Prism 2.5 PCI 802.11b adaptor support (EXPERIMENTAL)' CONFIG_PCI_HERMES $CONFIG_HERMES $CONFIG_EXPERIMENTAL
-diff -Nur linux-2.4.30/drivers/net/wl/Makefile linux-2.4.30-brcm/drivers/net/wl/Makefile
---- linux-2.4.30/drivers/net/wl/Makefile       1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/net/wl/Makefile  2005-05-26 12:04:50.000000000 +0200
+diff -urN linux.old/drivers/net/wl/Makefile linux.dev/drivers/net/wl/Makefile
+--- linux.old/drivers/net/wl/Makefile  1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/drivers/net/wl/Makefile  2005-08-26 13:44:34.427374040 +0200
 @@ -0,0 +1,26 @@
 +#
 +# Makefile for the Broadcom wl driver
@@ -19641,9 +18612,9 @@ diff -Nur linux-2.4.30/drivers/net/wl/Makefile linux-2.4.30-brcm/drivers/net/wl/
 +obj-m         := $(O_TARGET)
 +
 +include $(TOPDIR)/Rules.make
-diff -Nur linux-2.4.30/drivers/parport/Config.in linux-2.4.30-brcm/drivers/parport/Config.in
---- linux-2.4.30/drivers/parport/Config.in     2004-02-18 14:36:31.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/parport/Config.in        2005-05-22 22:55:52.000000000 +0200
+diff -urN linux.old/drivers/parport/Config.in linux.dev/drivers/parport/Config.in
+--- linux.old/drivers/parport/Config.in        2004-02-18 14:36:31.000000000 +0100
++++ linux.dev/drivers/parport/Config.in        2005-08-26 13:44:34.428373888 +0200
 @@ -11,6 +11,7 @@
  tristate 'Parallel port support' CONFIG_PARPORT
  if [ "$CONFIG_PARPORT" != "n" ]; then
@@ -19652,9 +18623,9 @@ diff -Nur linux-2.4.30/drivers/parport/Config.in linux-2.4.30-brcm/drivers/parpo
     if [ "$CONFIG_PARPORT_PC" != "n" -a "$CONFIG_SERIAL" != "n" ]; then
        if [ "$CONFIG_SERIAL" = "m" ]; then
           define_tristate CONFIG_PARPORT_PC_CML1 m
-diff -Nur linux-2.4.30/drivers/parport/Makefile linux-2.4.30-brcm/drivers/parport/Makefile
---- linux-2.4.30/drivers/parport/Makefile      2004-08-08 01:26:05.000000000 +0200
-+++ linux-2.4.30-brcm/drivers/parport/Makefile 2005-05-22 22:55:52.000000000 +0200
+diff -urN linux.old/drivers/parport/Makefile linux.dev/drivers/parport/Makefile
+--- linux.old/drivers/parport/Makefile 2004-08-08 01:26:05.000000000 +0200
++++ linux.dev/drivers/parport/Makefile 2005-08-26 13:44:34.428373888 +0200
 @@ -22,6 +22,7 @@
  
  obj-$(CONFIG_PARPORT)         += parport.o
@@ -19663,9 +18634,9 @@ diff -Nur linux-2.4.30/drivers/parport/Makefile linux-2.4.30-brcm/drivers/parpor
  obj-$(CONFIG_PARPORT_PC_PCMCIA)       += parport_cs.o
  obj-$(CONFIG_PARPORT_AMIGA)   += parport_amiga.o
  obj-$(CONFIG_PARPORT_MFC3)    += parport_mfc3.o
-diff -Nur linux-2.4.30/drivers/parport/parport_splink.c linux-2.4.30-brcm/drivers/parport/parport_splink.c
---- linux-2.4.30/drivers/parport/parport_splink.c      1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/parport/parport_splink.c 2005-05-22 22:55:52.000000000 +0200
+diff -urN linux.old/drivers/parport/parport_splink.c linux.dev/drivers/parport/parport_splink.c
+--- linux.old/drivers/parport/parport_splink.c 1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/drivers/parport/parport_splink.c 2005-08-26 13:44:34.429373736 +0200
 @@ -0,0 +1,345 @@
 +/* Low-level parallel port routines for the ASUS WL-500g built-in port
 + *
@@ -20012,9 +18983,32 @@ diff -Nur linux-2.4.30/drivers/parport/parport_splink.c linux-2.4.30-brcm/driver
 +module_init(parport_splink_init)
 +module_exit(parport_splink_cleanup)
 +
-diff -Nur linux-2.4.30/drivers/pcmcia/bcm4710_generic.c linux-2.4.30-brcm/drivers/pcmcia/bcm4710_generic.c
---- linux-2.4.30/drivers/pcmcia/bcm4710_generic.c      1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/pcmcia/bcm4710_generic.c 2005-05-22 22:55:52.000000000 +0200
+diff -urN linux.old/drivers/pcmcia/Makefile linux.dev/drivers/pcmcia/Makefile
+--- linux.old/drivers/pcmcia/Makefile  2005-08-26 13:41:42.048579600 +0200
++++ linux.dev/drivers/pcmcia/Makefile  2005-08-26 13:44:34.430373584 +0200
+@@ -74,6 +74,10 @@
+ au1000_ss-objs-$(CONFIG_MIPS_HYDROGEN3)               += au1000_hydrogen3.o
+ au1000_ss-objs-$(CONFIG_MIPS_XXS1500)                 += au1000_xxs1500.o
++obj-$(CONFIG_PCMCIA_BCM4710)  += bcm4710_ss.o
++bcm4710_ss-objs                                       := bcm4710_generic.o
++bcm4710_ss-objs                                       += bcm4710_pcmcia.o
++
+ obj-$(CONFIG_PCMCIA_SA1100)   += sa1100_cs.o
+ obj-$(CONFIG_PCMCIA_M8XX)     += m8xx_pcmcia.o
+ obj-$(CONFIG_PCMCIA_SIBYTE)   += sibyte_generic.o
+@@ -112,5 +116,8 @@
+ au1x00_ss.o: $(au1000_ss-objs-y)
+       $(LD) -r -o $@ $(au1000_ss-objs-y)
++bcm4710_ss.o: $(bcm4710_ss-objs)
++      $(LD) -r -o $@ $(bcm4710_ss-objs)
++
+ yenta_socket.o: $(yenta_socket-objs)
+       $(LD) $(LD_RFLAG) -r -o $@ $(yenta_socket-objs)
+diff -urN linux.old/drivers/pcmcia/bcm4710_generic.c linux.dev/drivers/pcmcia/bcm4710_generic.c
+--- linux.old/drivers/pcmcia/bcm4710_generic.c 1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/drivers/pcmcia/bcm4710_generic.c 2005-08-26 13:44:34.432373280 +0200
 @@ -0,0 +1,912 @@
 +/*
 + *
@@ -20928,9 +19922,9 @@ diff -Nur linux-2.4.30/drivers/pcmcia/bcm4710_generic.c linux-2.4.30-brcm/driver
 +
 +
 +#endif  /* defined(CONFIG_PROC_FS) */
-diff -Nur linux-2.4.30/drivers/pcmcia/bcm4710_pcmcia.c linux-2.4.30-brcm/drivers/pcmcia/bcm4710_pcmcia.c
---- linux-2.4.30/drivers/pcmcia/bcm4710_pcmcia.c       1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/pcmcia/bcm4710_pcmcia.c  2005-05-22 22:55:52.000000000 +0200
+diff -urN linux.old/drivers/pcmcia/bcm4710_pcmcia.c linux.dev/drivers/pcmcia/bcm4710_pcmcia.c
+--- linux.old/drivers/pcmcia/bcm4710_pcmcia.c  1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/drivers/pcmcia/bcm4710_pcmcia.c  2005-08-26 13:44:34.433373128 +0200
 @@ -0,0 +1,266 @@
 +/*
 + * BCM4710 specific pcmcia routines.
@@ -21198,9 +20192,9 @@ diff -Nur linux-2.4.30/drivers/pcmcia/bcm4710_pcmcia.c linux-2.4.30-brcm/drivers
 +      bcm4710_pcmcia_configure_socket
 +};
 +
-diff -Nur linux-2.4.30/drivers/pcmcia/bcm4710pcmcia.h linux-2.4.30-brcm/drivers/pcmcia/bcm4710pcmcia.h
---- linux-2.4.30/drivers/pcmcia/bcm4710pcmcia.h        1970-01-01 01:00:00.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/pcmcia/bcm4710pcmcia.h   2005-05-22 22:55:52.000000000 +0200
+diff -urN linux.old/drivers/pcmcia/bcm4710pcmcia.h linux.dev/drivers/pcmcia/bcm4710pcmcia.h
+--- linux.old/drivers/pcmcia/bcm4710pcmcia.h   1970-01-01 01:00:00.000000000 +0100
++++ linux.dev/drivers/pcmcia/bcm4710pcmcia.h   2005-08-26 13:44:34.433373128 +0200
 @@ -0,0 +1,118 @@
 +/*
 + *
@@ -21320,32 +20314,9 @@ diff -Nur linux-2.4.30/drivers/pcmcia/bcm4710pcmcia.h linux-2.4.30-brcm/drivers/
 +extern struct pcmcia_low_level bcm4710_pcmcia_ops;
 +
 +#endif  /* !defined(_BCM4710PCMCIA_H) */
-diff -Nur linux-2.4.30/drivers/pcmcia/Makefile linux-2.4.30-brcm/drivers/pcmcia/Makefile
---- linux-2.4.30/drivers/pcmcia/Makefile       2004-02-18 14:36:31.000000000 +0100
-+++ linux-2.4.30-brcm/drivers/pcmcia/Makefile  2005-05-22 22:55:52.000000000 +0200
-@@ -65,6 +65,10 @@
- au1000_ss-objs-$(CONFIG_PCMCIA_DB1X00)                += au1000_db1x00.o
- au1000_ss-objs-$(CONFIG_PCMCIA_XXS1500)       += au1000_xxs1500.o
-+obj-$(CONFIG_PCMCIA_BCM4710)  += bcm4710_ss.o
-+bcm4710_ss-objs                                       := bcm4710_generic.o
-+bcm4710_ss-objs                                       += bcm4710_pcmcia.o
-+
- obj-$(CONFIG_PCMCIA_SA1100)   += sa1100_cs.o
- obj-$(CONFIG_PCMCIA_M8XX)     += m8xx_pcmcia.o
- obj-$(CONFIG_PCMCIA_SIBYTE)   += sibyte_generic.o
-@@ -102,5 +106,8 @@
- au1x00_ss.o: $(au1000_ss-objs-y)
-       $(LD) -r -o $@ $(au1000_ss-objs-y)
-+bcm4710_ss.o: $(bcm4710_ss-objs)
-+      $(LD) -r -o $@ $(bcm4710_ss-objs)
-+
- yenta_socket.o: $(yenta_socket-objs)
-       $(LD) $(LD_RFLAG) -r -o $@ $(yenta_socket-objs)
-diff -Nur linux-2.4.30/include/asm-mips/bootinfo.h linux-2.4.30-brcm/include/asm-mips/bootinfo.h
---- linux-2.4.30/include/asm-mips/bootinfo.h   2004-02-18 14:36:32.000000000 +0100
-+++ linux-2.4.30-brcm/include/asm-mips/bootinfo.h      2005-05-22 22:55:53.000000000 +0200
+diff -urN linux.old/include/asm-mips/bootinfo.h linux.dev/include/asm-mips/bootinfo.h
+--- linux.old/include/asm-mips/bootinfo.h      2005-08-26 13:41:42.329536888 +0200
++++ linux.dev/include/asm-mips/bootinfo.h      2005-08-26 13:44:34.447371000 +0200
 @@ -37,6 +37,7 @@
  #define MACH_GROUP_HP_LJ       20 /* Hewlett Packard LaserJet               */
  #define MACH_GROUP_LASAT       21
@@ -21354,7 +20325,7 @@ diff -Nur linux-2.4.30/include/asm-mips/bootinfo.h linux-2.4.30-brcm/include/asm
  
  /*
   * Valid machtype values for group unknown (low order halfword of mips_machtype)
-@@ -194,6 +195,15 @@
+@@ -197,6 +198,15 @@
  #define MACH_TANBAC_TB0229    7       /* TANBAC TB0229 (VR4131DIMM) */
  
  /*
@@ -21370,9 +20341,9 @@ diff -Nur linux-2.4.30/include/asm-mips/bootinfo.h linux-2.4.30-brcm/include/asm
   * Valid machtype for group TITAN
   */
  #define       MACH_TITAN_YOSEMITE     1       /* PMC-Sierra Yosemite */
-diff -Nur linux-2.4.30/include/asm-mips/cpu.h linux-2.4.30-brcm/include/asm-mips/cpu.h
---- linux-2.4.30/include/asm-mips/cpu.h        2005-01-19 15:10:11.000000000 +0100
-+++ linux-2.4.30-brcm/include/asm-mips/cpu.h   2005-05-22 22:55:53.000000000 +0200
+diff -urN linux.old/include/asm-mips/cpu.h linux.dev/include/asm-mips/cpu.h
+--- linux.old/include/asm-mips/cpu.h   2005-01-19 15:10:11.000000000 +0100
++++ linux.dev/include/asm-mips/cpu.h   2005-08-26 13:44:34.455369784 +0200
 @@ -22,6 +22,11 @@
     spec.
  */
@@ -21421,9 +20392,9 @@ diff -Nur linux-2.4.30/include/asm-mips/cpu.h linux-2.4.30-brcm/include/asm-mips
  
  /*
   * ISA Level encodings
-diff -Nur linux-2.4.30/include/asm-mips/r4kcache.h linux-2.4.30-brcm/include/asm-mips/r4kcache.h
---- linux-2.4.30/include/asm-mips/r4kcache.h   2004-02-18 14:36:32.000000000 +0100
-+++ linux-2.4.30-brcm/include/asm-mips/r4kcache.h      2005-05-25 18:01:08.000000000 +0200
+diff -urN linux.old/include/asm-mips/r4kcache.h linux.dev/include/asm-mips/r4kcache.h
+--- linux.old/include/asm-mips/r4kcache.h      2004-02-18 14:36:32.000000000 +0100
++++ linux.dev/include/asm-mips/r4kcache.h      2005-08-26 13:44:34.457369480 +0200
 @@ -567,4 +567,17 @@
                        cache128_unroll32(addr|ws,Index_Writeback_Inv_SD);
  }
@@ -21442,9 +20413,9 @@ diff -Nur linux-2.4.30/include/asm-mips/r4kcache.h linux-2.4.30-brcm/include/asm
 +}      
 +
  #endif /* __ASM_R4KCACHE_H */
-diff -Nur linux-2.4.30/include/asm-mips/serial.h linux-2.4.30-brcm/include/asm-mips/serial.h
---- linux-2.4.30/include/asm-mips/serial.h     2005-01-19 15:10:12.000000000 +0100
-+++ linux-2.4.30-brcm/include/asm-mips/serial.h        2005-05-22 22:55:53.000000000 +0200
+diff -urN linux.old/include/asm-mips/serial.h linux.dev/include/asm-mips/serial.h
+--- linux.old/include/asm-mips/serial.h        2005-01-19 15:10:12.000000000 +0100
++++ linux.dev/include/asm-mips/serial.h        2005-08-26 13:44:34.459369176 +0200
 @@ -223,6 +223,13 @@
  #define TXX927_SERIAL_PORT_DEFNS
  #endif
@@ -21467,10 +20438,10 @@ diff -Nur linux-2.4.30/include/asm-mips/serial.h linux-2.4.30-brcm/include/asm-m
        COBALT_SERIAL_PORT_DEFNS                \
        DDB5477_SERIAL_PORT_DEFNS               \
        EV96100_SERIAL_PORT_DEFNS               \
-diff -Nur linux-2.4.30/init/do_mounts.c linux-2.4.30-brcm/init/do_mounts.c
---- linux-2.4.30/init/do_mounts.c      2003-11-28 19:26:21.000000000 +0100
-+++ linux-2.4.30-brcm/init/do_mounts.c 2005-05-22 22:55:53.000000000 +0200
-@@ -253,7 +253,13 @@
+diff -urN linux.old/init/do_mounts.c linux.dev/init/do_mounts.c
+--- linux.old/init/do_mounts.c 2005-08-26 13:41:42.608494480 +0200
++++ linux.dev/init/do_mounts.c 2005-08-26 13:44:34.481365832 +0200
+@@ -254,7 +254,13 @@
        { "ftlb", 0x2c08 },
        { "ftlc", 0x2c10 },
        { "ftld", 0x2c18 },
@@ -21484,67 +20455,3 @@ diff -Nur linux-2.4.30/init/do_mounts.c linux-2.4.30-brcm/init/do_mounts.c
        { "nb", 0x2b00 },
        { NULL, 0 }
  };
-diff -Nur linux-2.4.30/Makefile linux-2.4.30-brcm/Makefile
---- linux-2.4.30/Makefile      2005-04-04 03:42:20.000000000 +0200
-+++ linux-2.4.30-brcm/Makefile 2005-05-22 22:55:53.000000000 +0200
-@@ -17,9 +17,9 @@
- FINDHPATH     = $(HPATH)/asm $(HPATH)/linux $(HPATH)/scsi $(HPATH)/net $(HPATH)/math-emu
- HOSTCC        = gcc
--HOSTCFLAGS    = -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer
-+HOSTCFLAGS    = -Wall -Wstrict-prototypes -Os -fomit-frame-pointer
--CROSS_COMPILE         =
-+CROSS_COMPILE=
- #
- # Include the make variables (CC, etc...)
-@@ -91,8 +91,10 @@
- CPPFLAGS := -D__KERNEL__ -I$(HPATH)
--CFLAGS := $(CPPFLAGS) -Wall -Wstrict-prototypes -Wno-trigraphs -O2 \
-+CFLAGS := $(CPPFLAGS) -Wall -Wstrict-prototypes -Wno-trigraphs -Os \
-         -fno-strict-aliasing -fno-common
-+
-+
- ifndef CONFIG_FRAME_POINTER
- CFLAGS += -fomit-frame-pointer
- endif
-@@ -354,7 +356,7 @@
-       @rm -f .ver1
- include/linux/version.h: ./Makefile
--      @expr length "$(KERNELRELEASE)" \<= $(uts_len) > /dev/null || \
-+      @-expr length "$(KERNELRELEASE)" \<= $(uts_len) > /dev/null || \
-         (echo KERNELRELEASE \"$(KERNELRELEASE)\" exceeds $(uts_len) characters >&2; false)
-       @echo \#define UTS_RELEASE \"$(KERNELRELEASE)\" > .ver
-       @echo \#define LINUX_VERSION_CODE `expr $(VERSION) \\* 65536 + $(PATCHLEVEL) \\* 256 + $(SUBLEVEL)` >> .ver
-@@ -500,7 +502,7 @@
- ifdef CONFIG_MODVERSIONS
-       $(MAKE) update-modverfile
- endif
--      scripts/mkdep -- `find $(FINDHPATH) \( -name SCCS -o -name .svn \) -prune -o -follow -name \*.h ! -name modversions.h -print` > .hdepend
-+      (find $(FINDHPATH) \( -name SCCS -o -name .svn \) -prune -o -follow -name \*.h ! -name modversions.h -print | xargs -r scripts/mkdep -- ) > .hdepend
-       scripts/mkdep -- init/*.c > .depend
- ifdef CONFIG_MODVERSIONS
-diff -Nur linux-2.4.30/Rules.make linux-2.4.30-brcm/Rules.make
---- linux-2.4.30/Rules.make    2004-02-18 14:36:30.000000000 +0100
-+++ linux-2.4.30-brcm/Rules.make       2005-05-26 17:11:14.000000000 +0200
-@@ -176,7 +176,14 @@
- _modinst__: dummy
- ifneq "$(strip $(ALL_MOBJS))" ""
-       mkdir -p $(MODLIB)/kernel/$(MOD_DESTDIR)
--      cp $(sort $(ALL_MOBJS)) $(MODLIB)/kernel/$(MOD_DESTDIR)
-+      #@cp $(sort $(ALL_MOBJS)) $(MODLIB)/kernel/$(MOD_DESTDIR)
-+      for f in $(ALL_MOBJS) ; do \
-+              $(OBJCOPY) -R __ksymtab -R .comment -R .note -x \
-+              `$(NM) $$f | cut -f3- -d' ' | sed -n \
-+                      -e 's/__module_parm_\(.*\)/-K \1/p' \
-+                      -e 's/__ks..tab_\(.*\)/-K \1/p'` \
-+              $$f $(MODLIB)/kernel/$(MOD_DESTDIR)$(MOD_TARGET)$$f; \
-+      done
- endif
- .PHONY: modules_install
This page took 0.184004 seconds and 4 git commands to generate.