changeset 605:9b36b9dbfc4c

Upgrade stable to 2.6.28 linux kernel.
author Rob Landley <rob@landley.net>
date Sun, 01 Feb 2009 17:36:28 -0600
parents 7fc1f4695c29
children 2b6d9dd9f6b3
files download.sh sources/patches/alt-linux-2.6.25-shutup.patch sources/patches/alt-linux-boot-raw.patch sources/patches/alt-linux-noperl-out-out-damned-perl.patch sources/patches/alt-linux-noperl-yesreally.patch sources/patches/alt-linux-noperl.patch sources/patches/alt-linux-ppcqemu.patch sources/patches/linux-2.6.25-rc1-noperl.patch sources/patches/linux-2.6.28-boot-raw.patch sources/patches/linux-2.6.28-perl2.patch sources/patches/linux-2.6.28-perl3.patch sources/patches/linux-bcm47xx.patch sources/patches/linux-ppcqemu.patch sources/targets/hw-wrt610n/miniconfig-linux sources/targets/i586/miniconfig-linux sources/targets/i686/miniconfig-linux sources/targets/mips/miniconfig-linux sources/targets/mipsel/miniconfig-linux sources/targets/powerpc/details sources/targets/powerpc/miniconfig-linux sources/targets/x86_64/miniconfig-linux
diffstat 21 files changed, 786 insertions(+), 5738 deletions(-) [+]
line wrap: on
line diff
--- a/download.sh	Sun Feb 01 16:45:51 2009 -0600
+++ b/download.sh	Sun Feb 01 17:36:28 2009 -0600
@@ -24,9 +24,9 @@
 # then cut and paste the sha1 from the output and run it again to confirm.
 
 # Required for cross compile toolchain
-URL=http://kernel.org/pub/linux/kernel/v2.6/linux-2.6.25.10.tar.bz2 \
-SHA1=2911e1c01cd75d7e0fad2afb8329cd8ad1e742fb \
-UNSTABLE=http://kernel.org/pub/linux/kernel/v2.6/linux-2.6.28.tar.bz2 \
+URL=http://kernel.org/pub/linux/kernel/v2.6/linux-2.6.28.2.tar.bz2 \
+SHA1=8bf10c46b52e75f3cbfb4601af162d86bf077a2f \
+UNSTABLE=http://kernel.org/pub/linux/kernel/v2.6/testing/linux-2.6.29-rc3.tar.bz2 \
 download || dienow
 
 URL=http://www.uclibc.org/downloads/uClibc-0.9.30.tar.bz2 \
--- a/sources/patches/alt-linux-2.6.25-shutup.patch	Sun Feb 01 16:45:51 2009 -0600
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,1 +0,0 @@
-linux-2.6.25-shutup.patch
\ No newline at end of file
--- a/sources/patches/alt-linux-boot-raw.patch	Sun Feb 01 16:45:51 2009 -0600
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,33 +0,0 @@
-diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
-index f4af967..023604d 100644
---- a/arch/mips/Kconfig
-+++ b/arch/mips/Kconfig
-@@ -670,9 +670,6 @@ config ARC
- config ARCH_MAY_HAVE_PC_FDC
- 	bool
- 
--config BOOT_RAW
--	bool
--
- config CEVT_BCM1480
- 	bool
- 
-@@ -1887,6 +1884,18 @@ config SECCOMP
- 
- 	  If unsure, say Y. Only embedded should say N here.
- 
-+config BOOT_RAW
-+	bool "Enable the kernel to be executed from the load address"
-+	default n
-+	help
-+	 Allow the kernel to be executed from the load address for
-+	 bootloaders which cannot read the ELF format. This places
-+	 a jump to start_kernel at the load address.
-+
-+	 If unsure, say N.
-+
-+
-+
- endmenu
- 
- config RWSEM_GENERIC_SPINLOCK
--- a/sources/patches/alt-linux-noperl-out-out-damned-perl.patch	Sun Feb 01 16:45:51 2009 -0600
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,101 +0,0 @@
-From: Rob Landley <rob@landley.net>
-
-Convert kernel/cpu/mkcapflags.pl to kernel/cpu/mkcapflags.sh.
-
-This script generates kernel/cpu/capflags.c from include/asm/cpufeature.h.
-
-Changes from last time: changed shebang to #!/bin/sh and tested under bash
-and dash.
-
-Signed-off-by: Rob Landley <rob@landley.net>
----
-
- arch/x86/kernel/cpu/Makefile      |    4 +--
- arch/x86/kernel/cpu/mkcapflags.pl |   32 ----------------------------
- arch/x86/kernel/cpu/mkcapflags.sh |   28 ++++++++++++++++++++++++
- 3 files changed, 30 insertions(+), 34 deletions(-)
-
-diff -ruN linux-2.6.28/arch/x86/kernel/cpu/Makefile linux-2.6.28-new/arch/x86/kernel/cpu/Makefile
---- linux-2.6.28/arch/x86/kernel/cpu/Makefile	2008-12-24 17:26:37.000000000 -0600
-+++ linux-2.6.28-new/arch/x86/kernel/cpu/Makefile	2009-01-02 01:10:00.000000000 -0600
-@@ -23,10 +23,10 @@
- obj-$(CONFIG_X86_LOCAL_APIC) += perfctr-watchdog.o
- 
- quiet_cmd_mkcapflags = MKCAP   $@
--      cmd_mkcapflags = $(PERL) $(srctree)/$(src)/mkcapflags.pl $< $@
-+      cmd_mkcapflags = $(CONFIG_SHELL) $(srctree)/$(src)/mkcapflags.sh $< $@
- 
- cpufeature = $(src)/../../include/asm/cpufeature.h
- 
- targets += capflags.c
--$(obj)/capflags.c: $(cpufeature) $(src)/mkcapflags.pl FORCE
-+$(obj)/capflags.c: $(cpufeature) $(src)/mkcapflags.sh FORCE
- 	$(call if_changed,mkcapflags)
-diff -ruN linux-2.6.28/arch/x86/kernel/cpu/mkcapflags.pl linux-2.6.28-new/arch/x86/kernel/cpu/mkcapflags.pl
---- linux-2.6.28/arch/x86/kernel/cpu/mkcapflags.pl	2008-12-24 17:26:37.000000000 -0600
-+++ linux-2.6.28-new/arch/x86/kernel/cpu/mkcapflags.pl	1969-12-31 18:00:00.000000000 -0600
-@@ -1,32 +0,0 @@
--#!/usr/bin/perl
--#
--# Generate the x86_cap_flags[] array from include/asm-x86/cpufeature.h
--#
--
--($in, $out) = @ARGV;
--
--open(IN, "< $in\0")   or die "$0: cannot open: $in: $!\n";
--open(OUT, "> $out\0") or die "$0: cannot create: $out: $!\n";
--
--print OUT "#include <asm/cpufeature.h>\n\n";
--print OUT "const char * const x86_cap_flags[NCAPINTS*32] = {\n";
--
--while (defined($line = <IN>)) {
--	if ($line =~ /^\s*\#\s*define\s+(X86_FEATURE_(\S+))\s+(.*)$/) {
--		$macro = $1;
--		$feature = $2;
--		$tail = $3;
--		if ($tail =~ /\/\*\s*\"([^"]*)\".*\*\//) {
--			$feature = $1;
--		}
--
--		if ($feature ne '') {
--			printf OUT "\t%-32s = \"%s\",\n",
--				"[$macro]", "\L$feature";
--		}
--	}
--}
--print OUT "};\n";
--
--close(IN);
--close(OUT);
-diff -ruN linux-2.6.28/arch/x86/kernel/cpu/mkcapflags.sh linux-2.6.28-new/arch/x86/kernel/cpu/mkcapflags.sh
---- linux-2.6.28/arch/x86/kernel/cpu/mkcapflags.sh	1969-12-31 18:00:00.000000000 -0600
-+++ linux-2.6.28-new/arch/x86/kernel/cpu/mkcapflags.sh	2009-01-02 01:10:00.000000000 -0600
-@@ -0,0 +1,28 @@
-+#!/bin/sh
-+#
-+# Generate the x86_cap_flags[] array from include/asm/cpufeature.h
-+#
-+
-+IN=$1
-+OUT=$2
-+
-+(
-+	echo "#include <asm/cpufeature.h>"
-+	echo ""
-+	echo "const char * const x86_cap_flags[NCAPINTS*32] = {"
-+
-+	# Iterate through any input lines starting with #define X86_FEATURE_
-+	sed -n -e 's/\t/ /g' -e 's/^ *# *define *X86_FEATURE_//p' $IN |
-+	while read i
-+	do
-+		# Name is everything up to the first whitespace
-+		NAME="$(echo "$i" | sed 's/ .*//')"
-+
-+		# If the /* comment */ starts with a quote string, grab that.
-+		VALUE="$(echo "$i" | sed -n 's@.*/\* *\("[^"]*"\).*\*/@\1@p')"
-+		[ -z "$VALUE" ] && VALUE="\"$(echo "$NAME" | tr A-Z a-z)\""
-+
-+		[ "$VALUE" != '""' ] && echo "	[X86_FEATURE_$NAME] = $VALUE,"
-+	done
-+	echo "};"
-+) > $OUT
--- a/sources/patches/alt-linux-noperl-yesreally.patch	Sun Feb 01 16:45:51 2009 -0600
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,137 +0,0 @@
-From: Rob Landley <rob@landley.net>
-
-Remove perl from make headers_install by replacing a perl script (doing
-a simple regex search and replace) with a smaller and faster shell script
-implementation.  The new shell script is a single for loop calling sed and
-piping its output through unifdef to produce the target file.
-
-Changes from previous version: Added help text and a check for the right
-number of arguments.  Removed unused ARCH input from script and makefile
-(the makefile incorporates ARCH into INDIR, so the script doesn't care),
-fixed a whitespace mistake in the makefile pointed out by Sam Ravnborg,
-changed the shebang to #!/bin/sh and tested under bash and dash.
-
-
-put_changelog_here
-
-Signed-off-by: Rob Landley <rob@landley.net>
----
-
- scripts/Makefile.headersinst |    6 ++--
- scripts/headers_install.pl   |   46 ---------------------------------
- scripts/headers_install.sh   |   36 +++++++++++++++++++++++++
- 3 files changed, 39 insertions(+), 49 deletions(-)
-
-diff -ruN linux-2.6.28/scripts/headers_install.sh linux-2.6.28-new/scripts/headers_install.sh
---- linux-2.6.28/scripts/headers_install.sh	1969-12-31 18:00:00.000000000 -0600
-+++ linux-2.6.28-new/scripts/headers_install.sh	2009-01-02 22:35:17.000000000 -0600
-@@ -0,0 +1,36 @@
-+#!/bin/sh
-+
-+if [ $# -lt 2 ]
-+then
-+	echo "Usage: headers_install.sh INDIR OUTDIR [FILES...]
-+	echo
-+	echo "Prepares kernel header files for use by user space, by removing"
-+	echo "all compiler.h definitions and #includes, and removing any"
-+	echo "#ifdef __KERNEL__ sections."
-+	echo
-+	echo "INDIR:  directory to read each kernel header FILE from."
-+	echo "OUTDIR: directory to write each userspace header FILE to."
-+	echo "FILES:  list of header files to operate on."
-+
-+	exit 1
-+fi
-+
-+# Grab arguments
-+
-+INDIR="$1"
-+shift
-+OUTDIR="$1"
-+shift
-+
-+# Iterate through files listed on command line
-+
-+for i in "$@"
-+do
-+	sed -r \
-+		-e 's/([ \t(])(__user|__force|__iomem)[ \t]/\1/g' \
-+		-e 's/__attribute_const__([ \t]|$)/\1/g' \
-+		-e 's@^#include <linux/compiler.h>@@' "$INDIR/$i" |
-+	scripts/unifdef -U__KERNEL__ - > "$OUTDIR/$i"
-+done
-+
-+exit 0
-diff -ruN linux-2.6.28/scripts/Makefile.headersinst linux-2.6.28-new/scripts/Makefile.headersinst
---- linux-2.6.28/scripts/Makefile.headersinst	2008-12-24 17:26:37.000000000 -0600
-+++ linux-2.6.28-new/scripts/Makefile.headersinst	2009-01-02 22:36:42.000000000 -0600
-@@ -44,8 +44,8 @@
- quiet_cmd_install = INSTALL $(printdir) ($(words $(all-files))\
-                             file$(if $(word 2, $(all-files)),s))
-       cmd_install = \
--        $(PERL) $< $(srctree)/$(obj) $(install) $(SRCARCH) $(header-y); \
--        $(PERL) $< $(objtree)/$(obj) $(install) $(SRCARCH) $(objhdr-y); \
-+      $(CONFIG_SHELL) $< $(srctree)/$(obj) $(install) $(header-y); \
-+      $(CONFIG_SHELL) $< $(objtree)/$(obj) $(install) $(objhdr-y); \
-         touch $@
- 
- quiet_cmd_remove = REMOVE  $(unwanted)
-@@ -64,7 +64,7 @@
- 	@:
- 
- targets += $(install-file)
--$(install-file): scripts/headers_install.pl $(input-files) FORCE
-+$(install-file): scripts/headers_install.sh $(input-files) FORCE
- 	$(if $(unwanted),$(call cmd,remove),)
- 	$(if $(wildcard $(dir $@)),,$(shell mkdir -p $(dir $@)))
- 	$(call if_changed,install)
-diff -ruN linux-2.6.28/scripts/headers_install.pl linux-2.6.28-new/scripts/headers_install.pl
---- linux-2.6.28/scripts/headers_install.pl	2008-12-24 17:26:37.000000000 -0600
-+++ linux-2.6.28-new/scripts/headers_install.pl	1969-12-31 18:00:00.000000000 -0600
-@@ -1,46 +0,0 @@
--#!/usr/bin/perl -w
--#
--# headers_install prepare the listed header files for use in
--# user space and copy the files to their destination.
--#
--# Usage: headers_install.pl readdir installdir arch [files...]
--# readdir:    dir to open files
--# installdir: dir to install the files
--# arch:       current architecture
--#             arch is used to force a reinstallation when the arch
--#             changes because kbuild then detect a command line change.
--# files:      list of files to check
--#
--# Step in preparation for users space:
--# 1) Drop all use of compiler.h definitions
--# 2) Drop include of compiler.h
--# 3) Drop all sections defined out by __KERNEL__ (using unifdef)
--
--use strict;
--
--my ($readdir, $installdir, $arch, @files) = @ARGV;
--
--my $unifdef = "scripts/unifdef -U__KERNEL__";
--
--foreach my $file (@files) {
--	local *INFILE;
--	local *OUTFILE;
--	my $tmpfile = "$installdir/$file.tmp";
--	open(INFILE, "<$readdir/$file")
--		or die "$readdir/$file: $!\n";
--	open(OUTFILE, ">$tmpfile") or die "$tmpfile: $!\n";
--	while (my $line = <INFILE>) {
--		$line =~ s/([\s(])__user\s/$1/g;
--		$line =~ s/([\s(])__force\s/$1/g;
--		$line =~ s/([\s(])__iomem\s/$1/g;
--		$line =~ s/\s__attribute_const__\s/ /g;
--		$line =~ s/\s__attribute_const__$//g;
--		$line =~ s/^#include <linux\/compiler.h>//;
--		printf OUTFILE "%s", $line;
--	}
--	close OUTFILE;
--	close INFILE;
--	system $unifdef . " $tmpfile > $installdir/$file";
--	unlink $tmpfile;
--}
--exit 0;
--- a/sources/patches/alt-linux-noperl.patch	Sun Feb 01 16:45:51 2009 -0600
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,571 +0,0 @@
-From: Rob Landley <rob@landley.net>
-
-Replace kernel/timeconst.pl with kernel/timeconst.sh.  The new shell script
-is much simpler, about 1/4 the size, and runs on Red Hat 9 from 2003.
-
-It requires a shell which can do 64 bit math, such as bash, busybox ash,
-or dash running on a 64 bit host.
-
-Changes from previous version:
-
-Redo ADJ32 math to avoid integer overflow for small HZ sizes (such as 24 or
-122).  In the pathological case (HZ=1) both versions now produce
-USEC_TO_HZ_ADJ32 of 0x7ffff79c842fa.  (See source comments for details.)
-
-Also expand usage message, add error message when no 64 bit math available in
-shell (and suggest some shells that support it), add whitespace around
-operators in equations, added underscores before __KERNEL_TIMECONST_H, change
-makefile so script is responsible for creating output file, make script delete 
-output file on error, change shebang to #!/bin/sh and test with dash and bash.
-
-Signed-off-by: Rob Landley <rob@landley.net>
----
-
- kernel/Makefile     |    4 
- kernel/timeconst.pl |  378 ------------------------------------------
- kernel/timeconst.sh |  149 ++++++++++++++++
- 3 files changed, 151 insertions(+), 380 deletions(-)
-
---- linux-2.6.28/kernel/timeconst.pl	2008-12-24 17:26:37.000000000 -0600
-+++ /dev/null	2008-11-21 04:46:41.000000000 -0600
-@@ -1,378 +0,0 @@
--#!/usr/bin/perl
--# -----------------------------------------------------------------------
--#
--#   Copyright 2007-2008 rPath, Inc. - All Rights Reserved
--#
--#   This file is part of the Linux kernel, and is made available under
--#   the terms of the GNU General Public License version 2 or (at your
--#   option) any later version; incorporated herein by reference.
--#
--# -----------------------------------------------------------------------
--#
--
--#
--# Usage: timeconst.pl HZ > timeconst.h
--#
--
--# Precomputed values for systems without Math::BigInt
--# Generated by:
--# timeconst.pl --can 24 32 48 64 100 122 128 200 250 256 300 512 1000 1024 1200
--%canned_values = (
--	24 => [
--		'0xa6aaaaab','0x2aaaaaa',26,
--		125,3,
--		'0xc49ba5e4','0x1fbe76c8b4',37,
--		3,125,
--		'0xa2c2aaab','0xaaaa',16,
--		125000,3,
--		'0xc9539b89','0x7fffbce4217d',47,
--		3,125000,
--	], 32 => [
--		'0xfa000000','0x6000000',27,
--		125,4,
--		'0x83126e98','0xfdf3b645a',36,
--		4,125,
--		'0xf4240000','0x0',17,
--		31250,1,
--		'0x8637bd06','0x3fff79c842fa',46,
--		1,31250,
--	], 48 => [
--		'0xa6aaaaab','0x6aaaaaa',27,
--		125,6,
--		'0xc49ba5e4','0xfdf3b645a',36,
--		6,125,
--		'0xa2c2aaab','0x15555',17,
--		62500,3,
--		'0xc9539b89','0x3fffbce4217d',46,
--		3,62500,
--	], 64 => [
--		'0xfa000000','0xe000000',28,
--		125,8,
--		'0x83126e98','0x7ef9db22d',35,
--		8,125,
--		'0xf4240000','0x0',18,
--		15625,1,
--		'0x8637bd06','0x1fff79c842fa',45,
--		1,15625,
--	], 100 => [
--		'0xa0000000','0x0',28,
--		10,1,
--		'0xcccccccd','0x733333333',35,
--		1,10,
--		'0x9c400000','0x0',18,
--		10000,1,
--		'0xd1b71759','0x1fff2e48e8a7',45,
--		1,10000,
--	], 122 => [
--		'0x8325c53f','0xfbcda3a',28,
--		500,61,
--		'0xf9db22d1','0x7fbe76c8b',35,
--		61,500,
--		'0x8012e2a0','0x3ef36',18,
--		500000,61,
--		'0xffda4053','0x1ffffbce4217',45,
--		61,500000,
--	], 128 => [
--		'0xfa000000','0x1e000000',29,
--		125,16,
--		'0x83126e98','0x3f7ced916',34,
--		16,125,
--		'0xf4240000','0x40000',19,
--		15625,2,
--		'0x8637bd06','0xfffbce4217d',44,
--		2,15625,
--	], 200 => [
--		'0xa0000000','0x0',29,
--		5,1,
--		'0xcccccccd','0x333333333',34,
--		1,5,
--		'0x9c400000','0x0',19,
--		5000,1,
--		'0xd1b71759','0xfff2e48e8a7',44,
--		1,5000,
--	], 250 => [
--		'0x80000000','0x0',29,
--		4,1,
--		'0x80000000','0x180000000',33,
--		1,4,
--		'0xfa000000','0x0',20,
--		4000,1,
--		'0x83126e98','0x7ff7ced9168',43,
--		1,4000,
--	], 256 => [
--		'0xfa000000','0x3e000000',30,
--		125,32,
--		'0x83126e98','0x1fbe76c8b',33,
--		32,125,
--		'0xf4240000','0xc0000',20,
--		15625,4,
--		'0x8637bd06','0x7ffde7210be',43,
--		4,15625,
--	], 300 => [
--		'0xd5555556','0x2aaaaaaa',30,
--		10,3,
--		'0x9999999a','0x1cccccccc',33,
--		3,10,
--		'0xd0555556','0xaaaaa',20,
--		10000,3,
--		'0x9d495183','0x7ffcb923a29',43,
--		3,10000,
--	], 512 => [
--		'0xfa000000','0x7e000000',31,
--		125,64,
--		'0x83126e98','0xfdf3b645',32,
--		64,125,
--		'0xf4240000','0x1c0000',21,
--		15625,8,
--		'0x8637bd06','0x3ffef39085f',42,
--		8,15625,
--	], 1000 => [
--		'0x80000000','0x0',31,
--		1,1,
--		'0x80000000','0x0',31,
--		1,1,
--		'0xfa000000','0x0',22,
--		1000,1,
--		'0x83126e98','0x1ff7ced9168',41,
--		1,1000,
--	], 1024 => [
--		'0xfa000000','0xfe000000',32,
--		125,128,
--		'0x83126e98','0x7ef9db22',31,
--		128,125,
--		'0xf4240000','0x3c0000',22,
--		15625,16,
--		'0x8637bd06','0x1fff79c842f',41,
--		16,15625,
--	], 1200 => [
--		'0xd5555556','0xd5555555',32,
--		5,6,
--		'0x9999999a','0x66666666',31,
--		6,5,
--		'0xd0555556','0x2aaaaa',22,
--		2500,3,
--		'0x9d495183','0x1ffcb923a29',41,
--		3,2500,
--	]
--);
--
--$has_bigint = eval 'use Math::BigInt qw(bgcd); 1;';
--
--sub bint($)
--{
--	my($x) = @_;
--	return Math::BigInt->new($x);
--}
--
--#
--# Constants for division by reciprocal multiplication.
--# (bits, numerator, denominator)
--#
--sub fmul($$$)
--{
--	my ($b,$n,$d) = @_;
--
--	$n = bint($n);
--	$d = bint($d);
--
--	return scalar (($n << $b)+$d-bint(1))/$d;
--}
--
--sub fadj($$$)
--{
--	my($b,$n,$d) = @_;
--
--	$n = bint($n);
--	$d = bint($d);
--
--	$d = $d/bgcd($n, $d);
--	return scalar (($d-bint(1)) << $b)/$d;
--}
--
--sub fmuls($$$) {
--	my($b,$n,$d) = @_;
--	my($s,$m);
--	my($thres) = bint(1) << ($b-1);
--
--	$n = bint($n);
--	$d = bint($d);
--
--	for ($s = 0; 1; $s++) {
--		$m = fmul($s,$n,$d);
--		return $s if ($m >= $thres);
--	}
--	return 0;
--}
--
--# Generate a hex value if the result fits in 64 bits;
--# otherwise skip.
--sub bignum_hex($) {
--	my($x) = @_;
--	my $s = $x->as_hex();
--
--	return (length($s) > 18) ? undef : $s;
--}
--
--# Provides mul, adj, and shr factors for a specific
--# (bit, time, hz) combination
--sub muladj($$$) {
--	my($b, $t, $hz) = @_;
--	my $s = fmuls($b, $t, $hz);
--	my $m = fmul($s, $t, $hz);
--	my $a = fadj($s, $t, $hz);
--	return (bignum_hex($m), bignum_hex($a), $s);
--}
--
--# Provides numerator, denominator values
--sub numden($$) {
--	my($n, $d) = @_;
--	my $g = bgcd($n, $d);
--	return ($n/$g, $d/$g);
--}
--
--# All values for a specific (time, hz) combo
--sub conversions($$) {
--	my ($t, $hz) = @_;
--	my @val = ();
--
--	# HZ_TO_xx
--	push(@val, muladj(32, $t, $hz));
--	push(@val, numden($t, $hz));
--
--	# xx_TO_HZ
--	push(@val, muladj(32, $hz, $t));
--	push(@val, numden($hz, $t));
--
--	return @val;
--}
--
--sub compute_values($) {
--	my($hz) = @_;
--	my @val = ();
--	my $s, $m, $a, $g;
--
--	if (!$has_bigint) {
--		die "$0: HZ == $hz not canned and ".
--		    "Math::BigInt not available\n";
--	}
--
--	# MSEC conversions
--	push(@val, conversions(1000, $hz));
--
--	# USEC conversions
--	push(@val, conversions(1000000, $hz));
--
--	return @val;
--}
--
--sub outputval($$)
--{
--	my($name, $val) = @_;
--	my $csuf;
--
--	if (defined($val)) {
--	    if ($name !~ /SHR/) {
--		$val = "U64_C($val)";
--	    }
--	    printf "#define %-23s %s\n", $name.$csuf, $val.$csuf;
--	}
--}
--
--sub output($@)
--{
--	my($hz, @val) = @_;
--	my $pfx, $bit, $suf, $s, $m, $a;
--
--	print "/* Automatically generated by kernel/timeconst.pl */\n";
--	print "/* Conversion constants for HZ == $hz */\n";
--	print "\n";
--	print "#ifndef KERNEL_TIMECONST_H\n";
--	print "#define KERNEL_TIMECONST_H\n";
--	print "\n";
--
--	print "#include <linux/param.h>\n";
--	print "#include <linux/types.h>\n";
--
--	print "\n";
--	print "#if HZ != $hz\n";
--	print "#error \"kernel/timeconst.h has the wrong HZ value!\"\n";
--	print "#endif\n";
--	print "\n";
--
--	foreach $pfx ('HZ_TO_MSEC','MSEC_TO_HZ',
--		      'HZ_TO_USEC','USEC_TO_HZ') {
--		foreach $bit (32) {
--			foreach $suf ('MUL', 'ADJ', 'SHR') {
--				outputval("${pfx}_$suf$bit", shift(@val));
--			}
--		}
--		foreach $suf ('NUM', 'DEN') {
--			outputval("${pfx}_$suf", shift(@val));
--		}
--	}
--
--	print "\n";
--	print "#endif /* KERNEL_TIMECONST_H */\n";
--}
--
--# Pretty-print Perl values
--sub perlvals(@) {
--	my $v;
--	my @l = ();
--
--	foreach $v (@_) {
--		if (!defined($v)) {
--			push(@l, 'undef');
--		} elsif ($v =~ /^0x/) {
--			push(@l, "\'".$v."\'");
--		} else {
--			push(@l, $v.'');
--		}
--	}
--	return join(',', @l);
--}
--
--($hz) = @ARGV;
--
--# Use this to generate the %canned_values structure
--if ($hz eq '--can') {
--	shift(@ARGV);
--	@hzlist = sort {$a <=> $b} (@ARGV);
--
--	print "# Precomputed values for systems without Math::BigInt\n";
--	print "# Generated by:\n";
--	print "# timeconst.pl --can ", join(' ', @hzlist), "\n";
--	print "\%canned_values = (\n";
--	my $pf = "\t";
--	foreach $hz (@hzlist) {
--		my @values = compute_values($hz);
--		print "$pf$hz => [\n";
--		while (scalar(@values)) {
--			my $bit;
--			foreach $bit (32) {
--				my $m = shift(@values);
--				my $a = shift(@values);
--				my $s = shift(@values);
--				print "\t\t", perlvals($m,$a,$s), ",\n";
--			}
--			my $n = shift(@values);
--			my $d = shift(@values);
--			print "\t\t", perlvals($n,$d), ",\n";
--		}
--		print "\t]";
--		$pf = ', ';
--	}
--	print "\n);\n";
--} else {
--	$hz += 0;			# Force to number
--	if ($hz < 1) {
--		die "Usage: $0 HZ\n";
--	}
--
--	@val = @{$canned_values{$hz}};
--	if (!defined(@val)) {
--		@val = compute_values($hz);
--	}
--	output($hz, @val);
--}
--exit 0;
---- /dev/null	2008-11-21 04:46:41.000000000 -0600
-+++ linux-2.6.28-new/kernel/timeconst.sh	2009-01-03 15:24:01.000000000 -0600
-@@ -0,0 +1,147 @@
-+#!/bin/sh
-+
-+if [ $# -ne 2 ]
-+then
-+	echo "Usage: timeconst.sh HZ FILENAME"
-+	echo
-+	echo "Generate a header file with constants for coverting between"
-+	echo "decimal HZ timer ticks and milisecond or microsecond delays."
-+	echo
-+	exit 1
-+fi
-+
-+HZ=$1
-+shift
-+FILENAME=$1
-+
-+# Sanity test: even the shell in Red Hat 9 (circa 2003) supported 64 bit math.
-+
-+if [ $((1 << 32)) -lt 0 ]
-+then
-+	echo "timeconst.sh needs a shell with 64 bit math, such as bash,"
-+	echo "busybox ash, or dash running on a 64 bit host."
-+	exit 1
-+fi
-+
-+# If this script exits for any reason before this trap is removed,
-+# delete the output file so a partial file won't confuse the build.
-+
-+trap "rm $FILENAME" EXIT
-+
-+# Output start of header file
-+
-+cat > $FILENAME << EOF || exit 1
-+/* Automatically generated by kernel/timeconst.sh */
-+/* Conversion constants for HZ == $HZ */
-+
-+#ifndef __KERNEL_TIMECONST_H
-+#define __KERNEL_TIMECONST_H
-+
-+#include <linux/param.h>
-+#include <linux/types.h>
-+
-+#if HZ != $HZ
-+#error "kernel/timeconst.h has the wrong HZ value!"
-+#endif
-+
-+EOF
-+
-+# For both Milliseconds and Microseconds
-+
-+for i in "MSEC 1000" "USEC 1000000"
-+do
-+	NAME=$(echo $i | cut -d ' ' -f 1)
-+	PERIOD=$(echo $i | cut -d ' ' -f 2)
-+
-+	# Find greatest common denominator (using Euclid's algorithm)
-+
-+	A=$HZ
-+	B=$PERIOD
-+
-+	while [ $B -ne 0 ]
-+	do
-+		C=$(( $A % $B ))
-+		A=$B
-+		B=$C
-+	done
-+
-+	GCD=$A
-+
-+	# Do this for each direction (HZ_TO_PERIOD and PERIOD_TO_HZ)
-+
-+	for DIRECTION in 0 1
-+	do
-+		if [ $DIRECTION -eq 0 ]
-+		then
-+			CONVERT="HZ_TO_${NAME}"
-+			FROM=$HZ
-+			TO=$PERIOD
-+		else
-+			CONVERT="${NAME}_TO_HZ"
-+			FROM=$PERIOD
-+			TO=$HZ
-+		fi
-+
-+		# Calculate 32 significant bits of MUL32 data.
-+
-+		SHIFT=0
-+		while true
-+		do
-+			# This can't overflow 64 bit math.  Pathological case
-+			# (TO=1, FROM=1000000) uses around 32+20=52 bits.
-+
-+			MUL32=$(( ( ( $TO << $SHIFT ) + $FROM - 1 ) / $FROM ))
-+
-+			# Keep increasing $SHIFT until we've got 32 bits.
-+
-+			[ $MUL32 -gt $(( 1 << 31 )) ] && break
-+			SHIFT=$(( $SHIFT + 1 ))
-+		done
-+		MUL32=$( printf %x $MUL32 )
-+
-+		# ADJ32 is just (((FROM/GCD)-1)<<SHIFT)/(FROM/GCD) but this
-+		# can overflow 64 bit math (examples, HZ=24 or HZ=122).
-+		# Pathological case could use 32+20+20=72 bits.  (And this is
-+		# the pathological case because a larger $HZ results in a
-+		# smaller $SHIFT, so even insane HZ>USEC cases should be ok.)
-+
-+		# To get around this, we chop the bottom 32 bits off the
-+		# calculation and then reassemble it to avoid overflow:
-+		# 32+64=96, which is > 72.
-+
-+		ADJ32=$(( $FROM / $GCD ))
-+		if [ $SHIFT -gt 32 ]
-+		then
-+			UPPER=$(( ( $ADJ32 - 1 ) << ( $SHIFT - 32 ) ))
-+			LOWER=$(( ( $UPPER % $ADJ32 ) << 32 ))
-+			ADJ32=$(( ( ( $UPPER / $ADJ32 ) << 32 ) + ( $LOWER / $ADJ32 )))
-+		else
-+			ADJ32=$(( ( ( $ADJ32 - 1 ) << $SHIFT) / $ADJ32 ))
-+		fi
-+		ADJ32=$( printf %x $ADJ32 )
-+
-+		NUM=$(( $TO / $GCD ))
-+		DEN=$(( $FROM / $GCD ))
-+
-+		# Output next chunk of header data to file
-+
-+		(
-+			echo "#define ${CONVERT}_MUL32	U64_C(0x$MUL32)" &&
-+			echo "#define ${CONVERT}_ADJ32	U64_C(0x$ADJ32)" &&
-+			echo "#define ${CONVERT}_SHR32	$SHIFT" &&
-+			echo "#define ${CONVERT}_NUM		U64_C($NUM)" &&
-+			echo "#define ${CONVERT}_DEN		U64_C($DEN)"
-+		) >> $FILENAME || exit 1
-+	done
-+done
-+
-+(
-+	echo
-+	echo "#endif /* __KERNEL_TIMECHONST_H */"
-+) >> $FILENAME || exit 1
-+
-+# Don't rm $FILENAME on exit anymore.
-+
-+trap "" EXIT
-+
-+exit 0
---- linux-2.6.28/kernel/Makefile	2008-12-24 17:26:37.000000000 -0600
-+++ linux-2.6.28-new/kernel/Makefile	2009-01-03 00:40:21.000000000 -0600
-@@ -116,7 +116,7 @@
- $(obj)/time.o: $(obj)/timeconst.h
- 
- quiet_cmd_timeconst  = TIMEC   $@
--      cmd_timeconst  = $(PERL) $< $(CONFIG_HZ) > $@
-+      cmd_timeconst  = $(CONFIG_SHELL) $< $(CONFIG_HZ) $@
- targets += timeconst.h
--$(obj)/timeconst.h: $(src)/timeconst.pl FORCE
-+$(obj)/timeconst.h: $(src)/timeconst.sh FORCE
- 	$(call if_changed,timeconst)
--- a/sources/patches/alt-linux-ppcqemu.patch	Sun Feb 01 16:45:51 2009 -0600
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,1633 +0,0 @@
-From miltonm@bga.com Sat Sep 22 09:08:31 2007
-From: Milton Miller <miltonm@bga.com>
-Subject: [PATCH 1/2] qemu platform, v2
-Date: Sat, 22 Sep 2007 09:08:31 +1000
-X-Patchwork-ID: 13689
-
-Here is the second rev of patches to boot a arch powerpc kernel on
-qemu with the prep architecture.
-
-The goal is to provide an environment for use with the existing qemu
-hardware suppplied hardware, as oposed to changing the qemu
-machine description.
-
-This patch contains only the kernel portion.  While the diff was
-generated against for-2.6.24, this first patch applies cleanly
-to 2.6.23-rc7.  With the rom image created in the next patch,
-a kernel built by this patch should boot when using qemu -kernel.
-
-I debated putting this in the embedded6xx tree, especially when I
-discovered that the bridge is suposedly a '105, but saw no advantage
-in the end.
-
-pci config space is now working, however cirrusfb causes crashes
-and ohci times out, so at least pci memory is likely still broken.
-
-ide and serial work, floppy and parallel are untested.
-
-I added a defconfig based on chrp32; hardware options still need
-tweaking (eg isa ne2k).
-
-
----
-Index: kernel/arch/powerpc/platforms/Kconfig
-===================================================================
---- kernel.orig/arch/powerpc/platforms/Kconfig	2007-09-19 02:32:54.000000000 -0500
-+++ kernel/arch/powerpc/platforms/Kconfig	2007-09-19 02:41:00.000000000 -0500
-@@ -46,6 +46,7 @@ source "arch/powerpc/platforms/chrp/Kcon
- source "arch/powerpc/platforms/52xx/Kconfig"
- source "arch/powerpc/platforms/powermac/Kconfig"
- source "arch/powerpc/platforms/prep/Kconfig"
-+source "arch/powerpc/platforms/qemu/Kconfig"
- source "arch/powerpc/platforms/maple/Kconfig"
- source "arch/powerpc/platforms/pasemi/Kconfig"
- source "arch/powerpc/platforms/ps3/Kconfig"
-Index: kernel/arch/powerpc/platforms/qemu/Kconfig
-===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ kernel/arch/powerpc/platforms/qemu/Kconfig	2007-09-20 14:12:57.000000000 -0500
-@@ -0,0 +1,10 @@
-+config PPC_QEMU
-+	bool "QEMU emulated PowerPC Reference Platform (PReP) system"
-+	depends on PPC_MULTIPLATFORM && PPC32
-+	select PPC_I8259
-+	select PPC_INDIRECT_PCI
-+	select PPC_UDBG_16550
-+	select PPC_NATIVE
-+	select WANT_DEVICE_TREE
-+	default n
-+
-Index: kernel/arch/powerpc/platforms/qemu/Makefile
-===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ kernel/arch/powerpc/platforms/qemu/Makefile	2007-09-19 02:41:00.000000000 -0500
-@@ -0,0 +1,2 @@
-+obj-y			+= setup.o
-+obj-$(CONFIG_PCI)	+= pci.o
-Index: kernel/arch/powerpc/platforms/qemu/pci.c
-===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ kernel/arch/powerpc/platforms/qemu/pci.c	2007-09-19 02:56:36.000000000 -0500
-@@ -0,0 +1,133 @@
-+/*
-+ * prep Port to arch/powerpc:
-+ * Copyright 2007 David Gibson, IBM Corporation.
-+ *
-+ * prep Port to qemu:
-+ * Copyright 2007 Milton Miller, IBM Corporation.
-+ *
-+ * Based on OpenHackware 0.4
-+ * Copyright (c) 2004-2005 Jocelyn Mayer
-+ *
-+ * pci config based on arch/powerpc/platforms/chrp/pci.c GoldenGate code
-+ *
-+ */
-+
-+#include <linux/init.h>
-+
-+#include <asm/io.h>
-+#include <asm/prom.h>
-+#include <asm/pci-bridge.h>
-+#include <asm/udbg.h>
-+
-+static volatile void __iomem *qemu_config_addr(struct pci_bus *bus,
-+	unsigned int devfn, int off)
-+{
-+	int dev, fn;
-+	struct pci_controller *hose = bus->sysdata;
-+
-+	if (!hose->cfg_data)
-+		return NULL;
-+
-+	if (bus->number != 0)
-+		return NULL;
-+
-+	dev = devfn >> 3;
-+	fn = devfn & 7;
-+
-+	if (dev < 11 || dev > 21)
-+		return NULL;
-+
-+	return hose->cfg_data + ((1 << dev) | (fn << 8) | off);
-+}
-+
-+int qemu_read_config(struct pci_bus *bus, unsigned int devfn, int off,
-+			   int len, u32 *val)
-+{
-+	volatile void __iomem *cfg_data = qemu_config_addr(bus, devfn, off);
-+
-+	if (cfg_data == NULL)
-+		return PCIBIOS_DEVICE_NOT_FOUND;
-+
-+	/*
-+	 * Note: the caller has already checked that off is
-+	 * suitably aligned and that len is 1, 2 or 4.
-+	 */
-+	switch (len) {
-+	case 1:
-+		*val =  in_8(cfg_data);
-+		break;
-+	case 2:
-+		*val = in_le16(cfg_data);
-+		break;
-+	default:
-+		*val = in_le32(cfg_data);
-+		break;
-+	}
-+	return PCIBIOS_SUCCESSFUL;
-+}
-+
-+int qemu_write_config(struct pci_bus *bus, unsigned int devfn, int off,
-+			    int len, u32 val)
-+{
-+	volatile void __iomem *cfg_data = qemu_config_addr(bus, devfn, off);
-+
-+	if (cfg_data == NULL)
-+		return PCIBIOS_DEVICE_NOT_FOUND;
-+
-+	/*
-+	 * Note: the caller has already checked that off is
-+	 * suitably aligned and that len is 1, 2 or 4.
-+	 */
-+	switch (len) {
-+	case 1:
-+		out_8(cfg_data, val);
-+		break;
-+	case 2:
-+		out_le16(cfg_data, val);
-+		break;
-+	default:
-+		out_le32(cfg_data, val);
-+		break;
-+	}
-+	return PCIBIOS_SUCCESSFUL;
-+}
-+
-+static struct pci_ops qemu_pci_ops =
-+{
-+	qemu_read_config,
-+	qemu_write_config
-+};
-+
-+void __init qemu_find_bridges(void)
-+{
-+	struct device_node *phb;
-+	struct pci_controller *hose;
-+
-+	phb = of_find_node_by_type(NULL, "pci");
-+	if (!phb) {
-+		printk(KERN_ERR "PReP: Cannot find PCI bridge OF node\n");
-+		return;
-+	}
-+
-+	hose = pcibios_alloc_controller(phb);
-+	if (!hose)
-+		return;
-+
-+	pci_process_bridge_OF_ranges(hose, phb, 1);
-+
-+#define PREP_PCI_DRAM_OFFSET 	0x80000000
-+
-+	pci_dram_offset = PREP_PCI_DRAM_OFFSET;
-+	ISA_DMA_THRESHOLD = 0x00ffffff;
-+	DMA_MODE_READ = 0x44;
-+	DMA_MODE_WRITE = 0x48;
-+
-+	hose->cfg_data = ioremap(0x80800000, 1 << 22);
-+
-+	hose->ops = &qemu_pci_ops;
-+
-+	udbg_init_uart(hose->io_base_virt + 0x3f8, 0, 0);
-+	register_early_udbg_console();
-+	printk(KERN_INFO "qemu_find_bridges: config at %p\n", hose->cfg_data);
-+}
-+
-Index: kernel/arch/powerpc/platforms/qemu/setup.c
-===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ kernel/arch/powerpc/platforms/qemu/setup.c	2007-09-19 02:41:00.000000000 -0500
-@@ -0,0 +1,178 @@
-+/*
-+ * Copyright (C) 1995  Linus Torvalds
-+ * Adapted from 'alpha' version by Gary Thomas
-+ * Modified by Cort Dougan (cort@cs.nmt.edu)
-+ *
-+ * Support for PReP (Motorola MTX/MVME)
-+ * by Troy Benjegerdes (hozer@drgw.net)
-+ *
-+ * Port to arch/powerpc:
-+ * Copyright 2007 David Gibson, IBM Corporation.
-+ *
-+ * Port to qemu:
-+ * Copyright 2007 Milton Miller, IBM Corporation.
-+ *
-+ * Some information based on OpenHackware 0.4
-+ * Copyright (c) 2004-2005 Jocelyn Mayer
-+ *
-+ */
-+
-+#include <linux/init.h>
-+#include <linux/seq_file.h>
-+#include <linux/initrd.h>
-+#include <linux/ide.h>
-+
-+#include <asm/io.h>
-+#include <asm/prom.h>
-+#include <asm/pci-bridge.h>
-+/* #include <asm/mpic.h> */
-+#include <asm/i8259.h>
-+#include <asm/time.h>
-+#include <asm/udbg.h>
-+
-+static const char *qemu_model = "(unknown)";
-+
-+extern void qemu_find_bridges(void);
-+
-+/* cpuinfo code common to all IBM PReP */
-+static void qemu_ibm_cpuinfo(struct seq_file *m)
-+{
-+	seq_printf(m, "machine\t\t: PReP %s\n", qemu_model);
-+}
-+
-+#define NVRAM_AS0 0x74
-+#define NVRAM_AS1 0x75
-+#define NVRAM_DAT 0x77
-+
-+static unsigned char qemu_nvram_read_val(int addr)
-+{
-+	outb(NVRAM_AS0, addr & 0xff);
-+	outb(NVRAM_AS1, (addr >> 8) & 0xff);
-+	return inb(NVRAM_DAT);
-+}
-+
-+
-+static void qemu_nvram_write_val(int addr, unsigned char val)
-+{
-+	outb(NVRAM_AS0, addr & 0xff);
-+	outb(NVRAM_AS1, (addr >> 8) & 0xff);
-+	outb(NVRAM_DAT, val);
-+}
-+
-+
-+static void __init qemu_setup_arch(void)
-+{
-+	struct device_node *root;
-+	const char *model;
-+
-+	root = of_find_node_by_path("/");
-+	model = of_get_property(root, "model", NULL);
-+	of_node_put(root);
-+	if (model)
-+		qemu_model = model;
-+
-+	/* Lookup PCI host bridges */
-+	qemu_find_bridges();
-+
-+	/* Read in NVRAM data */
-+/* 	init_qemu_nvram(); */
-+}
-+
-+static void __init qemu_init_IRQ(void)
-+{
-+	struct device_node *pic = NULL;
-+	unsigned long int_ack = 0;
-+
-+	pic = of_find_node_by_type(NULL, "i8259");
-+	if (!pic) {
-+		printk(KERN_ERR "No interrupt controller found!\n");
-+		return;
-+	}
-+
-+	/* polling */
-+	i8259_init(pic, int_ack);
-+	//ppc_md.get_irq = i8259_irq;
-+
-+	/* set default host */
-+	irq_set_default_host(i8259_get_host());
-+}
-+
-+#if defined(CONFIG_BLK_DEV_IDE) || defined(CONFIG_BLK_DEV_IDE_MODULE)
-+/*
-+ * IDE stuff.
-+ */
-+static int qemu_ide_default_irq(unsigned long base)
-+{
-+	switch (base) {
-+	case 0x1f0: return 13;
-+	case 0x170: return 13;
-+	case 0x1e8: return 11;
-+	case 0x168: return 10;
-+	case 0xfff0: return 14;		/* MCP(N)750 ide0 */
-+	case 0xffe0: return 15;		/* MCP(N)750 ide1 */
-+	default: return 0;
-+	}
-+}
-+
-+static unsigned long qemu_ide_default_io_base(int index)
-+{
-+	switch (index) {
-+	case 0: return 0x1f0;
-+	case 1: return 0x170;
-+	case 2: return 0x1e8;
-+	case 3: return 0x168;
-+	default:
-+		return 0;
-+	}
-+}
-+#endif
-+
-+#if 0
-+static int __init prep_request_io(void)
-+{
-+#ifdef CONFIG_NVRAM
-+	request_region(PREP_NVRAM_AS0, 0x8, "nvram");
-+#endif
-+	request_region(0x00,0x20,"dma1");
-+	request_region(0x40,0x20,"timer");
-+	request_region(0x80,0x10,"dma page reg");
-+	request_region(0xc0,0x20,"dma2");
-+
-+	return 0;
-+}
-+device_initcall(prep_request_io);
-+#endif
-+
-+
-+static int __init qemu_probe(void)
-+{
-+	if (!of_flat_dt_is_compatible(of_get_flat_dt_root(), "qemu-prep"))
-+		return 0;
-+
-+#if defined(CONFIG_BLK_DEV_IDE) || defined(CONFIG_BLK_DEV_IDE_MODULE)
-+//	ppc_ide_md.default_irq = qemu_ide_default_irq;
-+//	ppc_ide_md.default_io_base = qemu_ide_default_io_base;
-+#endif
-+
-+	return 1;
-+}
-+
-+define_machine(qemu) {
-+	.name			= "QEMU",
-+	.probe			= qemu_probe,
-+	.setup_arch		= qemu_setup_arch,
-+	.progress		= udbg_progress,
-+	.show_cpuinfo		= qemu_ibm_cpuinfo,
-+	.init_IRQ		= qemu_init_IRQ,
-+/* 	.pcibios_fixup		= qemu_pcibios_fixup, */
-+/*	.restart		= qemu_restart, */
-+/*	.power_off		= qemu_halt, */
-+/*	.halt			= qemu_halt, */
-+/* 	.time_init		= todc_time_init, */
-+/* 	.set_rtc_time		= todc_set_rtc_time, */
-+/* 	.get_rtc_time		= todc_get_rtc_time, */
-+	.calibrate_decr		= generic_calibrate_decr,
-+ 	.nvram_read_val		= qemu_nvram_read_val,
-+ 	.nvram_write_val	= qemu_nvram_write_val,
-+	.phys_mem_access_prot	= pci_phys_mem_access_prot,
-+};
-Index: kernel/arch/powerpc/platforms/Makefile
-===================================================================
---- kernel.orig/arch/powerpc/platforms/Makefile	2007-09-19 02:32:54.000000000 -0500
-+++ kernel/arch/powerpc/platforms/Makefile	2007-09-19 02:41:00.000000000 -0500
-@@ -17,6 +17,7 @@ obj-$(CONFIG_PPC_82xx)		+= 82xx/
- obj-$(CONFIG_PPC_83xx)		+= 83xx/
- obj-$(CONFIG_PPC_85xx)		+= 85xx/
- obj-$(CONFIG_PPC_86xx)		+= 86xx/
-+obj-$(CONFIG_PPC_QEMU)		+= qemu/
- obj-$(CONFIG_PPC_PSERIES)	+= pseries/
- obj-$(CONFIG_PPC_ISERIES)	+= iseries/
- obj-$(CONFIG_PPC_MAPLE)		+= maple/
-Index: kernel/arch/powerpc/configs/qemu_defconfig
-===================================================================
---- /dev/null	1970-01-01 00:00:00.000000000 +0000
-+++ kernel/arch/powerpc/configs/qemu_defconfig	2007-09-19 02:41:00.000000000 -0500
-@@ -0,0 +1,1217 @@
-+#
-+# Automatically generated make config: don't edit
-+# Linux kernel version: 2.6.23-rc6
-+# Tue Sep 18 15:18:32 2007
-+#
-+# CONFIG_PPC64 is not set
-+
-+#
-+# Processor support
-+#
-+CONFIG_6xx=y
-+# CONFIG_PPC_85xx is not set
-+# CONFIG_PPC_8xx is not set
-+# CONFIG_40x is not set
-+# CONFIG_44x is not set
-+# CONFIG_E200 is not set
-+CONFIG_PPC_FPU=y
-+# CONFIG_ALTIVEC is not set
-+CONFIG_PPC_STD_MMU=y
-+CONFIG_PPC_STD_MMU_32=y
-+# CONFIG_PPC_MM_SLICES is not set
-+# CONFIG_SMP is not set
-+CONFIG_PPC32=y
-+CONFIG_PPC_MERGE=y
-+CONFIG_MMU=y
-+CONFIG_GENERIC_HARDIRQS=y
-+CONFIG_IRQ_PER_CPU=y
-+CONFIG_RWSEM_XCHGADD_ALGORITHM=y
-+CONFIG_ARCH_HAS_ILOG2_U32=y
-+CONFIG_GENERIC_HWEIGHT=y
-+CONFIG_GENERIC_CALIBRATE_DELAY=y
-+CONFIG_GENERIC_FIND_NEXT_BIT=y
-+# CONFIG_ARCH_NO_VIRT_TO_BUS is not set
-+CONFIG_PPC=y
-+CONFIG_EARLY_PRINTK=y
-+CONFIG_GENERIC_NVRAM=y
-+CONFIG_SCHED_NO_NO_OMIT_FRAME_POINTER=y
-+CONFIG_ARCH_MAY_HAVE_PC_FDC=y
-+CONFIG_PPC_OF=y
-+CONFIG_OF=y
-+CONFIG_PPC_UDBG_16550=y
-+# CONFIG_GENERIC_TBSYNC is not set
-+CONFIG_AUDIT_ARCH=y
-+CONFIG_GENERIC_BUG=y
-+# CONFIG_DEFAULT_UIMAGE is not set
-+# CONFIG_PPC_DCR_NATIVE is not set
-+# CONFIG_PPC_DCR_MMIO is not set
-+CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config"
-+
-+#
-+# General setup
-+#
-+CONFIG_EXPERIMENTAL=y
-+CONFIG_BROKEN_ON_SMP=y
-+CONFIG_INIT_ENV_ARG_LIMIT=32
-+CONFIG_LOCALVERSION=""
-+# CONFIG_LOCALVERSION_AUTO is not set
-+CONFIG_SWAP=y
-+CONFIG_SYSVIPC=y
-+CONFIG_SYSVIPC_SYSCTL=y
-+CONFIG_POSIX_MQUEUE=y
-+# CONFIG_BSD_PROCESS_ACCT is not set
-+# CONFIG_TASKSTATS is not set
-+# CONFIG_USER_NS is not set
-+# CONFIG_AUDIT is not set
-+CONFIG_IKCONFIG=y
-+CONFIG_IKCONFIG_PROC=y
-+CONFIG_LOG_BUF_SHIFT=15
-+CONFIG_SYSFS_DEPRECATED=y
-+# CONFIG_RELAY is not set
-+CONFIG_BLK_DEV_INITRD=y
-+CONFIG_INITRAMFS_SOURCE=""
-+# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set
-+CONFIG_SYSCTL=y
-+# CONFIG_EMBEDDED is not set
-+CONFIG_SYSCTL_SYSCALL=y
-+CONFIG_KALLSYMS=y
-+# CONFIG_KALLSYMS_ALL is not set
-+# CONFIG_KALLSYMS_EXTRA_PASS is not set
-+CONFIG_HOTPLUG=y
-+CONFIG_PRINTK=y
-+CONFIG_BUG=y
-+CONFIG_ELF_CORE=y
-+CONFIG_BASE_FULL=y
-+CONFIG_FUTEX=y
-+CONFIG_ANON_INODES=y
-+CONFIG_EPOLL=y
-+CONFIG_SIGNALFD=y
-+CONFIG_TIMERFD=y
-+CONFIG_EVENTFD=y
-+CONFIG_SHMEM=y
-+CONFIG_VM_EVENT_COUNTERS=y
-+CONFIG_SLAB=y
-+# CONFIG_SLUB is not set
-+# CONFIG_SLOB is not set
-+CONFIG_RT_MUTEXES=y
-+# CONFIG_TINY_SHMEM is not set
-+CONFIG_BASE_SMALL=0
-+CONFIG_MODULES=y
-+CONFIG_MODULE_UNLOAD=y
-+CONFIG_MODULE_FORCE_UNLOAD=y
-+# CONFIG_MODVERSIONS is not set
-+# CONFIG_MODULE_SRCVERSION_ALL is not set
-+CONFIG_KMOD=y
-+CONFIG_BLOCK=y
-+CONFIG_LBD=y
-+# CONFIG_BLK_DEV_IO_TRACE is not set
-+# CONFIG_LSF is not set
-+# CONFIG_BLK_DEV_BSG is not set
-+
-+#
-+# IO Schedulers
-+#
-+CONFIG_IOSCHED_NOOP=y
-+CONFIG_IOSCHED_AS=y
-+CONFIG_IOSCHED_DEADLINE=y
-+CONFIG_IOSCHED_CFQ=y
-+CONFIG_DEFAULT_AS=y
-+# CONFIG_DEFAULT_DEADLINE is not set
-+# CONFIG_DEFAULT_CFQ is not set
-+# CONFIG_DEFAULT_NOOP is not set
-+CONFIG_DEFAULT_IOSCHED="anticipatory"
-+
-+#
-+# Platform support
-+#
-+CONFIG_PPC_MULTIPLATFORM=y
-+# CONFIG_EMBEDDED6xx is not set
-+# CONFIG_PPC_82xx is not set
-+# CONFIG_PPC_83xx is not set
-+# CONFIG_PPC_86xx is not set
-+CONFIG_CLASSIC32=y
-+# CONFIG_PPC_CHRP is not set
-+# CONFIG_PPC_MPC52xx is not set
-+# CONFIG_PPC_MPC5200 is not set
-+# CONFIG_PPC_EFIKA is not set
-+# CONFIG_PPC_LITE5200 is not set
-+# CONFIG_PPC_PMAC is not set
-+CONFIG_PPC_QEMU=y
-+# CONFIG_PPC_CELL is not set
-+# CONFIG_PPC_CELL_NATIVE is not set
-+# CONFIG_PQ2ADS is not set
-+CONFIG_PPC_NATIVE=y
-+# CONFIG_MPIC is not set
-+# CONFIG_MPIC_WEIRD is not set
-+CONFIG_PPC_I8259=y
-+# CONFIG_PPC_RTAS is not set
-+# CONFIG_MMIO_NVRAM is not set
-+# CONFIG_PPC_MPC106 is not set
-+# CONFIG_PPC_970_NAP is not set
-+# CONFIG_PPC_INDIRECT_IO is not set
-+# CONFIG_GENERIC_IOMAP is not set
-+# CONFIG_CPU_FREQ is not set
-+# CONFIG_TAU is not set
-+# CONFIG_CPM2 is not set
-+# CONFIG_FSL_ULI1575 is not set
-+
-+#
-+# Kernel options
-+#
-+CONFIG_HIGHMEM=y
-+# CONFIG_HZ_100 is not set
-+CONFIG_HZ_250=y
-+# CONFIG_HZ_300 is not set
-+# CONFIG_HZ_1000 is not set
-+CONFIG_HZ=250
-+CONFIG_PREEMPT_NONE=y
-+# CONFIG_PREEMPT_VOLUNTARY is not set
-+# CONFIG_PREEMPT is not set
-+CONFIG_BINFMT_ELF=y
-+CONFIG_BINFMT_MISC=y
-+CONFIG_ARCH_ENABLE_MEMORY_HOTPLUG=y
-+# CONFIG_KEXEC is not set
-+CONFIG_ARCH_FLATMEM_ENABLE=y
-+CONFIG_ARCH_POPULATES_NODE_MAP=y
-+CONFIG_SELECT_MEMORY_MODEL=y
-+CONFIG_FLATMEM_MANUAL=y
-+# CONFIG_DISCONTIGMEM_MANUAL is not set
-+# CONFIG_SPARSEMEM_MANUAL is not set
-+CONFIG_FLATMEM=y
-+CONFIG_FLAT_NODE_MEM_MAP=y
-+# CONFIG_SPARSEMEM_STATIC is not set
-+CONFIG_SPLIT_PTLOCK_CPUS=4
-+# CONFIG_RESOURCES_64BIT is not set
-+CONFIG_ZONE_DMA_FLAG=1
-+CONFIG_BOUNCE=y
-+CONFIG_VIRT_TO_BUS=y
-+CONFIG_PROC_DEVICETREE=y
-+# CONFIG_CMDLINE_BOOL is not set
-+# CONFIG_PM is not set
-+CONFIG_SUSPEND_UP_POSSIBLE=y
-+CONFIG_HIBERNATION_UP_POSSIBLE=y
-+CONFIG_SECCOMP=y
-+CONFIG_WANT_DEVICE_TREE=y
-+CONFIG_DEVICE_TREE="qemu.dts"
-+CONFIG_ISA_DMA_API=y
-+
-+#
-+# Bus options
-+#
-+CONFIG_ZONE_DMA=y
-+CONFIG_GENERIC_ISA_DMA=y
-+CONFIG_PPC_INDIRECT_PCI=y
-+CONFIG_PCI=y
-+CONFIG_PCI_DOMAINS=y
-+CONFIG_PCI_SYSCALL=y
-+# CONFIG_PCIEPORTBUS is not set
-+CONFIG_ARCH_SUPPORTS_MSI=y
-+# CONFIG_PCI_MSI is not set
-+# CONFIG_PCI_DEBUG is not set
-+
-+#
-+# PCCARD (PCMCIA/CardBus) support
-+#
-+# CONFIG_PCCARD is not set
-+# CONFIG_HOTPLUG_PCI is not set
-+
-+#
-+# Advanced setup
-+#
-+# CONFIG_ADVANCED_OPTIONS is not set
-+
-+#
-+# Default settings for advanced configuration options are used
-+#
-+CONFIG_HIGHMEM_START=0xfe000000
-+CONFIG_LOWMEM_SIZE=0x30000000
-+CONFIG_KERNEL_START=0xc0000000
-+CONFIG_TASK_SIZE=0x80000000
-+CONFIG_BOOT_LOAD=0x00800000
-+
-+#
-+# Networking
-+#
-+CONFIG_NET=y
-+
-+#
-+# Networking options
-+#
-+CONFIG_PACKET=y
-+# CONFIG_PACKET_MMAP is not set
-+CONFIG_UNIX=y
-+# CONFIG_NET_KEY is not set
-+CONFIG_INET=y
-+CONFIG_IP_MULTICAST=y
-+# CONFIG_IP_ADVANCED_ROUTER is not set
-+CONFIG_IP_FIB_HASH=y
-+# CONFIG_IP_PNP is not set
-+# CONFIG_NET_IPIP is not set
-+# CONFIG_NET_IPGRE is not set
-+# CONFIG_IP_MROUTE is not set
-+# CONFIG_ARPD is not set
-+CONFIG_SYN_COOKIES=y
-+# CONFIG_INET_AH is not set
-+# CONFIG_INET_ESP is not set
-+# CONFIG_INET_IPCOMP is not set
-+# CONFIG_INET_XFRM_TUNNEL is not set
-+# CONFIG_INET_TUNNEL is not set
-+# CONFIG_INET_XFRM_MODE_TRANSPORT is not set
-+# CONFIG_INET_XFRM_MODE_TUNNEL is not set
-+# CONFIG_INET_XFRM_MODE_BEET is not set
-+CONFIG_INET_DIAG=y
-+CONFIG_INET_TCP_DIAG=y
-+# CONFIG_TCP_CONG_ADVANCED is not set
-+CONFIG_TCP_CONG_CUBIC=y
-+CONFIG_DEFAULT_TCP_CONG="cubic"
-+# CONFIG_TCP_MD5SIG is not set
-+# CONFIG_IP_VS is not set
-+# CONFIG_IPV6 is not set
-+# CONFIG_INET6_XFRM_TUNNEL is not set
-+# CONFIG_INET6_TUNNEL is not set
-+# CONFIG_NETWORK_SECMARK is not set
-+CONFIG_NETFILTER=y
-+# CONFIG_NETFILTER_DEBUG is not set
-+
-+#
-+# Core Netfilter Configuration
-+#
-+# CONFIG_NETFILTER_NETLINK is not set
-+CONFIG_NF_CONNTRACK_ENABLED=m
-+CONFIG_NF_CONNTRACK=m
-+# CONFIG_NF_CT_ACCT is not set
-+# CONFIG_NF_CONNTRACK_MARK is not set
-+# CONFIG_NF_CONNTRACK_EVENTS is not set
-+# CONFIG_NF_CT_PROTO_SCTP is not set
-+# CONFIG_NF_CT_PROTO_UDPLITE is not set
-+# CONFIG_NF_CONNTRACK_AMANDA is not set
-+CONFIG_NF_CONNTRACK_FTP=m
-+# CONFIG_NF_CONNTRACK_H323 is not set
-+CONFIG_NF_CONNTRACK_IRC=m
-+# CONFIG_NF_CONNTRACK_NETBIOS_NS is not set
-+# CONFIG_NF_CONNTRACK_PPTP is not set
-+# CONFIG_NF_CONNTRACK_SANE is not set
-+CONFIG_NF_CONNTRACK_SIP=m
-+CONFIG_NF_CONNTRACK_TFTP=m
-+CONFIG_NETFILTER_XTABLES=m
-+# CONFIG_NETFILTER_XT_TARGET_CLASSIFY is not set
-+# CONFIG_NETFILTER_XT_TARGET_MARK is not set
-+# CONFIG_NETFILTER_XT_TARGET_NFQUEUE is not set
-+# CONFIG_NETFILTER_XT_TARGET_NFLOG is not set
-+# CONFIG_NETFILTER_XT_TARGET_TCPMSS is not set
-+# CONFIG_NETFILTER_XT_MATCH_COMMENT is not set
-+# CONFIG_NETFILTER_XT_MATCH_CONNBYTES is not set
-+# CONFIG_NETFILTER_XT_MATCH_CONNLIMIT is not set
-+# CONFIG_NETFILTER_XT_MATCH_CONNMARK is not set
-+# CONFIG_NETFILTER_XT_MATCH_CONNTRACK is not set
-+# CONFIG_NETFILTER_XT_MATCH_DCCP is not set
-+# CONFIG_NETFILTER_XT_MATCH_DSCP is not set
-+# CONFIG_NETFILTER_XT_MATCH_ESP is not set
-+# CONFIG_NETFILTER_XT_MATCH_HELPER is not set
-+# CONFIG_NETFILTER_XT_MATCH_LENGTH is not set
-+# CONFIG_NETFILTER_XT_MATCH_LIMIT is not set
-+# CONFIG_NETFILTER_XT_MATCH_MAC is not set
-+# CONFIG_NETFILTER_XT_MATCH_MARK is not set
-+# CONFIG_NETFILTER_XT_MATCH_MULTIPORT is not set
-+# CONFIG_NETFILTER_XT_MATCH_PKTTYPE is not set
-+# CONFIG_NETFILTER_XT_MATCH_QUOTA is not set
-+# CONFIG_NETFILTER_XT_MATCH_REALM is not set
-+# CONFIG_NETFILTER_XT_MATCH_SCTP is not set
-+# CONFIG_NETFILTER_XT_MATCH_STATE is not set
-+# CONFIG_NETFILTER_XT_MATCH_STATISTIC is not set
-+# CONFIG_NETFILTER_XT_MATCH_STRING is not set
-+# CONFIG_NETFILTER_XT_MATCH_TCPMSS is not set
-+# CONFIG_NETFILTER_XT_MATCH_U32 is not set
-+# CONFIG_NETFILTER_XT_MATCH_HASHLIMIT is not set
-+
-+#
-+# IP: Netfilter Configuration
-+#
-+CONFIG_NF_CONNTRACK_IPV4=m
-+CONFIG_NF_CONNTRACK_PROC_COMPAT=y
-+# CONFIG_IP_NF_QUEUE is not set
-+CONFIG_IP_NF_IPTABLES=m
-+# CONFIG_IP_NF_MATCH_IPRANGE is not set
-+# CONFIG_IP_NF_MATCH_TOS is not set
-+# CONFIG_IP_NF_MATCH_RECENT is not set
-+# CONFIG_IP_NF_MATCH_ECN is not set
-+# CONFIG_IP_NF_MATCH_AH is not set
-+# CONFIG_IP_NF_MATCH_TTL is not set
-+# CONFIG_IP_NF_MATCH_OWNER is not set
-+# CONFIG_IP_NF_MATCH_ADDRTYPE is not set
-+CONFIG_IP_NF_FILTER=m
-+CONFIG_IP_NF_TARGET_REJECT=m
-+CONFIG_IP_NF_TARGET_LOG=m
-+# CONFIG_IP_NF_TARGET_ULOG is not set
-+CONFIG_NF_NAT=m
-+CONFIG_NF_NAT_NEEDED=y
-+CONFIG_IP_NF_TARGET_MASQUERADE=m
-+CONFIG_IP_NF_TARGET_REDIRECT=m
-+# CONFIG_IP_NF_TARGET_NETMAP is not set
-+# CONFIG_IP_NF_TARGET_SAME is not set
-+# CONFIG_NF_NAT_SNMP_BASIC is not set
-+CONFIG_NF_NAT_FTP=m
-+CONFIG_NF_NAT_IRC=m
-+CONFIG_NF_NAT_TFTP=m
-+# CONFIG_NF_NAT_AMANDA is not set
-+# CONFIG_NF_NAT_PPTP is not set
-+# CONFIG_NF_NAT_H323 is not set
-+CONFIG_NF_NAT_SIP=m
-+# CONFIG_IP_NF_MANGLE is not set
-+# CONFIG_IP_NF_RAW is not set
-+# CONFIG_IP_NF_ARPTABLES is not set
-+# CONFIG_IP_DCCP is not set
-+# CONFIG_IP_SCTP is not set
-+# CONFIG_TIPC is not set
-+# CONFIG_ATM is not set
-+# CONFIG_BRIDGE is not set
-+# CONFIG_VLAN_8021Q is not set
-+# CONFIG_DECNET is not set
-+# CONFIG_LLC2 is not set
-+# CONFIG_IPX is not set
-+# CONFIG_ATALK is not set
-+# CONFIG_X25 is not set
-+# CONFIG_LAPB is not set
-+# CONFIG_ECONET is not set
-+# CONFIG_WAN_ROUTER is not set
-+
-+#
-+# QoS and/or fair queueing
-+#
-+# CONFIG_NET_SCHED is not set
-+
-+#
-+# Network testing
-+#
-+# CONFIG_NET_PKTGEN is not set
-+# CONFIG_HAMRADIO is not set
-+# CONFIG_IRDA is not set
-+# CONFIG_BT is not set
-+# CONFIG_AF_RXRPC is not set
-+
-+#
-+# Wireless
-+#
-+# CONFIG_CFG80211 is not set
-+# CONFIG_WIRELESS_EXT is not set
-+# CONFIG_MAC80211 is not set
-+# CONFIG_IEEE80211 is not set
-+# CONFIG_RFKILL is not set
-+# CONFIG_NET_9P is not set
-+
-+#
-+# Device Drivers
-+#
-+
-+#
-+# Generic Driver Options
-+#
-+# CONFIG_STANDALONE is not set
-+CONFIG_PREVENT_FIRMWARE_BUILD=y
-+# CONFIG_FW_LOADER is not set
-+# CONFIG_DEBUG_DRIVER is not set
-+# CONFIG_DEBUG_DEVRES is not set
-+# CONFIG_SYS_HYPERVISOR is not set
-+# CONFIG_CONNECTOR is not set
-+# CONFIG_MTD is not set
-+CONFIG_OF_DEVICE=y
-+# CONFIG_PARPORT is not set
-+CONFIG_BLK_DEV=y
-+CONFIG_BLK_DEV_FD=y
-+# CONFIG_BLK_CPQ_DA is not set
-+# CONFIG_BLK_CPQ_CISS_DA is not set
-+# CONFIG_BLK_DEV_DAC960 is not set
-+# CONFIG_BLK_DEV_UMEM is not set
-+# CONFIG_BLK_DEV_COW_COMMON is not set
-+CONFIG_BLK_DEV_LOOP=y
-+# CONFIG_BLK_DEV_CRYPTOLOOP is not set
-+# CONFIG_BLK_DEV_NBD is not set
-+# CONFIG_BLK_DEV_SX8 is not set
-+# CONFIG_BLK_DEV_UB is not set
-+CONFIG_BLK_DEV_RAM=y
-+CONFIG_BLK_DEV_RAM_COUNT=16
-+CONFIG_BLK_DEV_RAM_SIZE=4096
-+CONFIG_BLK_DEV_RAM_BLOCKSIZE=1024
-+# CONFIG_CDROM_PKTCDVD is not set
-+# CONFIG_ATA_OVER_ETH is not set
-+CONFIG_MISC_DEVICES=y
-+# CONFIG_PHANTOM is not set
-+# CONFIG_EEPROM_93CX6 is not set
-+# CONFIG_SGI_IOC4 is not set
-+# CONFIG_TIFM_CORE is not set
-+CONFIG_IDE=y
-+CONFIG_BLK_DEV_IDE=y
-+
-+#
-+# Please see Documentation/ide.txt for help/info on IDE drives
-+#
-+# CONFIG_BLK_DEV_IDE_SATA is not set
-+CONFIG_BLK_DEV_IDEDISK=y
-+CONFIG_IDEDISK_MULTI_MODE=y
-+CONFIG_BLK_DEV_IDECD=y
-+# CONFIG_BLK_DEV_IDETAPE is not set
-+# CONFIG_BLK_DEV_IDEFLOPPY is not set
-+# CONFIG_IDE_TASK_IOCTL is not set
-+CONFIG_IDE_PROC_FS=y
-+
-+#
-+# IDE chipset support/bugfixes
-+#
-+CONFIG_IDE_GENERIC=y
-+CONFIG_BLK_DEV_IDEPCI=y
-+CONFIG_IDEPCI_SHARE_IRQ=y
-+CONFIG_IDEPCI_PCIBUS_ORDER=y
-+# CONFIG_BLK_DEV_OFFBOARD is not set
-+CONFIG_BLK_DEV_GENERIC=y
-+# CONFIG_BLK_DEV_OPTI621 is not set
-+CONFIG_BLK_DEV_IDEDMA_PCI=y
-+# CONFIG_BLK_DEV_IDEDMA_FORCED is not set
-+# CONFIG_IDEDMA_ONLYDISK is not set
-+# CONFIG_BLK_DEV_AEC62XX is not set
-+# CONFIG_BLK_DEV_ALI15X3 is not set
-+# CONFIG_BLK_DEV_AMD74XX is not set
-+# CONFIG_BLK_DEV_CMD64X is not set
-+# CONFIG_BLK_DEV_TRIFLEX is not set
-+# CONFIG_BLK_DEV_CY82C693 is not set
-+# CONFIG_BLK_DEV_CS5520 is not set
-+# CONFIG_BLK_DEV_CS5530 is not set
-+# CONFIG_BLK_DEV_HPT34X is not set
-+# CONFIG_BLK_DEV_HPT366 is not set
-+# CONFIG_BLK_DEV_JMICRON is not set
-+# CONFIG_BLK_DEV_SC1200 is not set
-+# CONFIG_BLK_DEV_PIIX is not set
-+# CONFIG_BLK_DEV_IT8213 is not set
-+# CONFIG_BLK_DEV_IT821X is not set
-+# CONFIG_BLK_DEV_NS87415 is not set
-+# CONFIG_BLK_DEV_PDC202XX_OLD is not set
-+# CONFIG_BLK_DEV_PDC202XX_NEW is not set
-+# CONFIG_BLK_DEV_SVWKS is not set
-+# CONFIG_BLK_DEV_SIIMAGE is not set
-+# CONFIG_BLK_DEV_SL82C105 is not set
-+# CONFIG_BLK_DEV_SLC90E66 is not set
-+# CONFIG_BLK_DEV_TRM290 is not set
-+# CONFIG_BLK_DEV_VIA82CXXX is not set
-+# CONFIG_BLK_DEV_TC86C001 is not set
-+# CONFIG_IDE_ARM is not set
-+CONFIG_BLK_DEV_IDEDMA=y
-+# CONFIG_IDEDMA_IVB is not set
-+# CONFIG_BLK_DEV_HD is not set
-+
-+#
-+# SCSI device support
-+#
-+# CONFIG_RAID_ATTRS is not set
-+# CONFIG_SCSI is not set
-+# CONFIG_SCSI_DMA is not set
-+# CONFIG_SCSI_NETLINK is not set
-+# CONFIG_ATA is not set
-+# CONFIG_MD is not set
-+
-+#
-+# Fusion MPT device support
-+#
-+# CONFIG_FUSION is not set
-+
-+#
-+# IEEE 1394 (FireWire) support
-+#
-+# CONFIG_FIREWIRE is not set
-+# CONFIG_IEEE1394 is not set
-+# CONFIG_I2O is not set
-+# CONFIG_MACINTOSH_DRIVERS is not set
-+CONFIG_NETDEVICES=y
-+# CONFIG_NETDEVICES_MULTIQUEUE is not set
-+# CONFIG_DUMMY is not set
-+# CONFIG_BONDING is not set
-+# CONFIG_MACVLAN is not set
-+# CONFIG_EQUALIZER is not set
-+# CONFIG_TUN is not set
-+# CONFIG_ARCNET is not set
-+# CONFIG_PHYLIB is not set
-+CONFIG_NET_ETHERNET=y
-+CONFIG_MII=y
-+# CONFIG_HAPPYMEAL is not set
-+# CONFIG_SUNGEM is not set
-+# CONFIG_CASSINI is not set
-+# CONFIG_NET_VENDOR_3COM is not set
-+# CONFIG_NET_TULIP is not set
-+# CONFIG_HP100 is not set
-+CONFIG_NET_PCI=y
-+CONFIG_PCNET32=y
-+# CONFIG_PCNET32_NAPI is not set
-+# CONFIG_AMD8111_ETH is not set
-+# CONFIG_ADAPTEC_STARFIRE is not set
-+# CONFIG_B44 is not set
-+# CONFIG_FORCEDETH is not set
-+# CONFIG_DGRS is not set
-+# CONFIG_EEPRO100 is not set
-+# CONFIG_E100 is not set
-+# CONFIG_FEALNX is not set
-+# CONFIG_NATSEMI is not set
-+CONFIG_NE2K_PCI=m
-+CONFIG_8139CP=y
-+CONFIG_8139TOO=y
-+# CONFIG_8139TOO_PIO is not set
-+# CONFIG_8139TOO_TUNE_TWISTER is not set
-+# CONFIG_8139TOO_8129 is not set
-+# CONFIG_8139_OLD_RX_RESET is not set
-+# CONFIG_SIS900 is not set
-+# CONFIG_EPIC100 is not set
-+# CONFIG_SUNDANCE is not set
-+# CONFIG_TLAN is not set
-+# CONFIG_VIA_RHINE is not set
-+# CONFIG_SC92031 is not set
-+# CONFIG_NETDEV_1000 is not set
-+# CONFIG_NETDEV_10000 is not set
-+# CONFIG_TR is not set
-+
-+#
-+# Wireless LAN
-+#
-+# CONFIG_WLAN_PRE80211 is not set
-+# CONFIG_WLAN_80211 is not set
-+
-+#
-+# USB Network Adapters
-+#
-+# CONFIG_USB_CATC is not set
-+# CONFIG_USB_KAWETH is not set
-+# CONFIG_USB_PEGASUS is not set
-+# CONFIG_USB_RTL8150 is not set
-+# CONFIG_USB_USBNET_MII is not set
-+# CONFIG_USB_USBNET is not set
-+# CONFIG_WAN is not set
-+# CONFIG_FDDI is not set
-+# CONFIG_HIPPI is not set
-+CONFIG_PPP=m
-+CONFIG_PPP_MULTILINK=y
-+CONFIG_PPP_FILTER=y
-+CONFIG_PPP_ASYNC=m
-+CONFIG_PPP_SYNC_TTY=m
-+CONFIG_PPP_DEFLATE=m
-+CONFIG_PPP_BSDCOMP=m
-+CONFIG_PPP_MPPE=m
-+CONFIG_PPPOE=m
-+# CONFIG_PPPOL2TP is not set
-+# CONFIG_SLIP is not set
-+CONFIG_SLHC=m
-+# CONFIG_SHAPER is not set
-+# CONFIG_NETCONSOLE is not set
-+# CONFIG_NETPOLL is not set
-+# CONFIG_NET_POLL_CONTROLLER is not set
-+# CONFIG_ISDN is not set
-+# CONFIG_PHONE is not set
-+
-+#
-+# Input device support
-+#
-+CONFIG_INPUT=y
-+# CONFIG_INPUT_FF_MEMLESS is not set
-+# CONFIG_INPUT_POLLDEV is not set
-+
-+#
-+# Userland interfaces
-+#
-+CONFIG_INPUT_MOUSEDEV=y
-+CONFIG_INPUT_MOUSEDEV_PSAUX=y
-+CONFIG_INPUT_MOUSEDEV_SCREEN_X=1024
-+CONFIG_INPUT_MOUSEDEV_SCREEN_Y=768
-+# CONFIG_INPUT_JOYDEV is not set
-+CONFIG_INPUT_TSDEV=m
-+CONFIG_INPUT_TSDEV_SCREEN_X=240
-+CONFIG_INPUT_TSDEV_SCREEN_Y=320
-+CONFIG_INPUT_EVDEV=y
-+# CONFIG_INPUT_EVBUG is not set
-+
-+#
-+# Input Device Drivers
-+#
-+CONFIG_INPUT_KEYBOARD=y
-+CONFIG_KEYBOARD_ATKBD=y
-+# CONFIG_KEYBOARD_SUNKBD is not set
-+# CONFIG_KEYBOARD_LKKBD is not set
-+# CONFIG_KEYBOARD_XTKBD is not set
-+# CONFIG_KEYBOARD_NEWTON is not set
-+# CONFIG_KEYBOARD_STOWAWAY is not set
-+CONFIG_INPUT_MOUSE=y
-+CONFIG_MOUSE_PS2=y
-+CONFIG_MOUSE_PS2_ALPS=y
-+CONFIG_MOUSE_PS2_LOGIPS2PP=y
-+CONFIG_MOUSE_PS2_SYNAPTICS=y
-+CONFIG_MOUSE_PS2_LIFEBOOK=y
-+CONFIG_MOUSE_PS2_TRACKPOINT=y
-+# CONFIG_MOUSE_PS2_TOUCHKIT is not set
-+# CONFIG_MOUSE_SERIAL is not set
-+# CONFIG_MOUSE_APPLETOUCH is not set
-+# CONFIG_MOUSE_VSXXXAA is not set
-+# CONFIG_INPUT_JOYSTICK is not set
-+CONFIG_INPUT_TABLET=y
-+# CONFIG_TABLET_USB_ACECAD is not set
-+# CONFIG_TABLET_USB_AIPTEK is not set
-+# CONFIG_TABLET_USB_GTCO is not set
-+# CONFIG_TABLET_USB_KBTAB is not set
-+# CONFIG_TABLET_USB_WACOM is not set
-+# CONFIG_INPUT_TOUCHSCREEN is not set
-+CONFIG_INPUT_MISC=y
-+# CONFIG_INPUT_ATI_REMOTE is not set
-+# CONFIG_INPUT_ATI_REMOTE2 is not set
-+# CONFIG_INPUT_KEYSPAN_REMOTE is not set
-+# CONFIG_INPUT_POWERMATE is not set
-+# CONFIG_INPUT_YEALINK is not set
-+CONFIG_INPUT_UINPUT=y
-+
-+#
-+# Hardware I/O ports
-+#
-+CONFIG_SERIO=y
-+CONFIG_SERIO_I8042=y
-+# CONFIG_SERIO_SERPORT is not set
-+# CONFIG_SERIO_PCIPS2 is not set
-+CONFIG_SERIO_LIBPS2=y
-+# CONFIG_SERIO_RAW is not set
-+# CONFIG_GAMEPORT is not set
-+
-+#
-+# Character devices
-+#
-+CONFIG_VT=y
-+CONFIG_VT_CONSOLE=y
-+CONFIG_HW_CONSOLE=y
-+# CONFIG_VT_HW_CONSOLE_BINDING is not set
-+# CONFIG_SERIAL_NONSTANDARD is not set
-+
-+#
-+# Serial drivers
-+#
-+CONFIG_SERIAL_8250=y
-+CONFIG_SERIAL_8250_CONSOLE=y
-+CONFIG_SERIAL_8250_PCI=y
-+CONFIG_SERIAL_8250_NR_UARTS=4
-+CONFIG_SERIAL_8250_RUNTIME_UARTS=4
-+# CONFIG_SERIAL_8250_EXTENDED is not set
-+
-+#
-+# Non-8250 serial port support
-+#
-+# CONFIG_SERIAL_UARTLITE is not set
-+CONFIG_SERIAL_CORE=y
-+CONFIG_SERIAL_CORE_CONSOLE=y
-+# CONFIG_SERIAL_JSM is not set
-+# CONFIG_SERIAL_OF_PLATFORM is not set
-+CONFIG_UNIX98_PTYS=y
-+CONFIG_LEGACY_PTYS=y
-+CONFIG_LEGACY_PTY_COUNT=256
-+# CONFIG_IPMI_HANDLER is not set
-+# CONFIG_WATCHDOG is not set
-+CONFIG_HW_RANDOM=m
-+CONFIG_NVRAM=y
-+CONFIG_GEN_RTC=y
-+# CONFIG_GEN_RTC_X is not set
-+# CONFIG_R3964 is not set
-+# CONFIG_APPLICOM is not set
-+# CONFIG_AGP is not set
-+# CONFIG_DRM is not set
-+# CONFIG_RAW_DRIVER is not set
-+# CONFIG_TCG_TPM is not set
-+CONFIG_DEVPORT=y
-+CONFIG_I2C=y
-+CONFIG_I2C_BOARDINFO=y
-+# CONFIG_I2C_CHARDEV is not set
-+
-+#
-+# I2C Algorithms
-+#
-+CONFIG_I2C_ALGOBIT=y
-+# CONFIG_I2C_ALGOPCF is not set
-+# CONFIG_I2C_ALGOPCA is not set
-+
-+#
-+# I2C Hardware Bus support
-+#
-+# CONFIG_I2C_ALI1535 is not set
-+# CONFIG_I2C_ALI1563 is not set
-+# CONFIG_I2C_ALI15X3 is not set
-+# CONFIG_I2C_AMD756 is not set
-+# CONFIG_I2C_AMD8111 is not set
-+# CONFIG_I2C_I801 is not set
-+# CONFIG_I2C_I810 is not set
-+# CONFIG_I2C_PIIX4 is not set
-+# CONFIG_I2C_MPC is not set
-+# CONFIG_I2C_NFORCE2 is not set
-+# CONFIG_I2C_OCORES is not set
-+# CONFIG_I2C_PARPORT_LIGHT is not set
-+# CONFIG_I2C_PROSAVAGE is not set
-+# CONFIG_I2C_SAVAGE4 is not set
-+# CONFIG_I2C_SIMTEC is not set
-+# CONFIG_I2C_SIS5595 is not set
-+# CONFIG_I2C_SIS630 is not set
-+# CONFIG_I2C_SIS96X is not set
-+# CONFIG_I2C_TAOS_EVM is not set
-+# CONFIG_I2C_STUB is not set
-+# CONFIG_I2C_TINY_USB is not set
-+# CONFIG_I2C_VIA is not set
-+# CONFIG_I2C_VIAPRO is not set
-+# CONFIG_I2C_VOODOO3 is not set
-+
-+#
-+# Miscellaneous I2C Chip support
-+#
-+# CONFIG_SENSORS_DS1337 is not set
-+# CONFIG_SENSORS_DS1374 is not set
-+# CONFIG_DS1682 is not set
-+# CONFIG_SENSORS_EEPROM is not set
-+# CONFIG_SENSORS_PCF8574 is not set
-+# CONFIG_SENSORS_PCA9539 is not set
-+# CONFIG_SENSORS_PCF8591 is not set
-+# CONFIG_SENSORS_M41T00 is not set
-+# CONFIG_SENSORS_MAX6875 is not set
-+# CONFIG_SENSORS_TSL2550 is not set
-+# CONFIG_I2C_DEBUG_CORE is not set
-+# CONFIG_I2C_DEBUG_ALGO is not set
-+# CONFIG_I2C_DEBUG_BUS is not set
-+# CONFIG_I2C_DEBUG_CHIP is not set
-+
-+#
-+# SPI support
-+#
-+# CONFIG_SPI is not set
-+# CONFIG_SPI_MASTER is not set
-+# CONFIG_W1 is not set
-+# CONFIG_POWER_SUPPLY is not set
-+# CONFIG_HWMON is not set
-+
-+#
-+# Multifunction device drivers
-+#
-+# CONFIG_MFD_SM501 is not set
-+
-+#
-+# Multimedia devices
-+#
-+# CONFIG_VIDEO_DEV is not set
-+# CONFIG_DVB_CORE is not set
-+# CONFIG_DAB is not set
-+
-+#
-+# Graphics support
-+#
-+# CONFIG_BACKLIGHT_LCD_SUPPORT is not set
-+
-+#
-+# Display device support
-+#
-+CONFIG_DISPLAY_SUPPORT=m
-+
-+#
-+# Display hardware drivers
-+#
-+# CONFIG_VGASTATE is not set
-+# CONFIG_VIDEO_OUTPUT_CONTROL is not set
-+# CONFIG_FB is not set
-+# CONFIG_FB_IBM_GXT4500 is not set
-+
-+#
-+# Console display driver support
-+#
-+CONFIG_VGA_CONSOLE=y
-+# CONFIG_VGACON_SOFT_SCROLLBACK is not set
-+CONFIG_DUMMY_CONSOLE=y
-+
-+#
-+# Sound
-+#
-+# CONFIG_SOUND is not set
-+CONFIG_HID_SUPPORT=y
-+CONFIG_HID=y
-+# CONFIG_HID_DEBUG is not set
-+
-+#
-+# USB Input Devices
-+#
-+CONFIG_USB_HID=y
-+# CONFIG_USB_HIDINPUT_POWERBOOK is not set
-+# CONFIG_HID_FF is not set
-+# CONFIG_USB_HIDDEV is not set
-+CONFIG_USB_SUPPORT=y
-+CONFIG_USB_ARCH_HAS_HCD=y
-+CONFIG_USB_ARCH_HAS_OHCI=y
-+CONFIG_USB_ARCH_HAS_EHCI=y
-+CONFIG_USB=y
-+# CONFIG_USB_DEBUG is not set
-+
-+#
-+# Miscellaneous USB options
-+#
-+CONFIG_USB_DEVICEFS=y
-+CONFIG_USB_DEVICE_CLASS=y
-+# CONFIG_USB_DYNAMIC_MINORS is not set
-+# CONFIG_USB_OTG is not set
-+
-+#
-+# USB Host Controller Drivers
-+#
-+# CONFIG_USB_EHCI_HCD is not set
-+# CONFIG_USB_ISP116X_HCD is not set
-+CONFIG_USB_OHCI_HCD=y
-+# CONFIG_USB_OHCI_HCD_PPC_OF is not set
-+# CONFIG_USB_OHCI_BIG_ENDIAN_DESC is not set
-+# CONFIG_USB_OHCI_BIG_ENDIAN_MMIO is not set
-+CONFIG_USB_OHCI_LITTLE_ENDIAN=y
-+# CONFIG_USB_UHCI_HCD is not set
-+# CONFIG_USB_SL811_HCD is not set
-+# CONFIG_USB_R8A66597_HCD is not set
-+
-+#
-+# USB Device Class drivers
-+#
-+# CONFIG_USB_ACM is not set
-+# CONFIG_USB_PRINTER is not set
-+
-+#
-+# NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support'
-+#
-+
-+#
-+# may also be needed; see USB_STORAGE Help for more information
-+#
-+# CONFIG_USB_LIBUSUAL is not set
-+
-+#
-+# USB Imaging devices
-+#
-+# CONFIG_USB_MDC800 is not set
-+CONFIG_USB_MON=y
-+
-+#
-+# USB port drivers
-+#
-+
-+#
-+# USB Serial Converter support
-+#
-+# CONFIG_USB_SERIAL is not set
-+
-+#
-+# USB Miscellaneous drivers
-+#
-+# CONFIG_USB_EMI62 is not set
-+# CONFIG_USB_EMI26 is not set
-+# CONFIG_USB_ADUTUX is not set
-+# CONFIG_USB_AUERSWALD is not set
-+# CONFIG_USB_RIO500 is not set
-+# CONFIG_USB_LEGOTOWER is not set
-+# CONFIG_USB_LCD is not set
-+# CONFIG_USB_BERRY_CHARGE is not set
-+# CONFIG_USB_LED is not set
-+# CONFIG_USB_CYPRESS_CY7C63 is not set
-+# CONFIG_USB_CYTHERM is not set
-+# CONFIG_USB_PHIDGET is not set
-+# CONFIG_USB_IDMOUSE is not set
-+# CONFIG_USB_FTDI_ELAN is not set
-+# CONFIG_USB_APPLEDISPLAY is not set
-+# CONFIG_USB_LD is not set
-+# CONFIG_USB_TRANCEVIBRATOR is not set
-+# CONFIG_USB_IOWARRIOR is not set
-+# CONFIG_USB_TEST is not set
-+
-+#
-+# USB DSL modem support
-+#
-+
-+#
-+# USB Gadget Support
-+#
-+# CONFIG_USB_GADGET is not set
-+# CONFIG_MMC is not set
-+# CONFIG_NEW_LEDS is not set
-+# CONFIG_INFINIBAND is not set
-+# CONFIG_EDAC is not set
-+# CONFIG_RTC_CLASS is not set
-+
-+#
-+# DMA Engine support
-+#
-+# CONFIG_DMA_ENGINE is not set
-+
-+#
-+# DMA Clients
-+#
-+
-+#
-+# DMA Devices
-+#
-+
-+#
-+# Userspace I/O
-+#
-+# CONFIG_UIO is not set
-+
-+#
-+# File systems
-+#
-+CONFIG_EXT2_FS=y
-+# CONFIG_EXT2_FS_XATTR is not set
-+# CONFIG_EXT2_FS_XIP is not set
-+CONFIG_EXT3_FS=y
-+CONFIG_EXT3_FS_XATTR=y
-+# CONFIG_EXT3_FS_POSIX_ACL is not set
-+# CONFIG_EXT3_FS_SECURITY is not set
-+# CONFIG_EXT4DEV_FS is not set
-+CONFIG_JBD=y
-+# CONFIG_JBD_DEBUG is not set
-+CONFIG_FS_MBCACHE=y
-+# CONFIG_REISERFS_FS is not set
-+# CONFIG_JFS_FS is not set
-+# CONFIG_FS_POSIX_ACL is not set
-+# CONFIG_XFS_FS is not set
-+# CONFIG_GFS2_FS is not set
-+# CONFIG_OCFS2_FS is not set
-+# CONFIG_MINIX_FS is not set
-+# CONFIG_ROMFS_FS is not set
-+CONFIG_INOTIFY=y
-+CONFIG_INOTIFY_USER=y
-+# CONFIG_QUOTA is not set
-+CONFIG_DNOTIFY=y
-+# CONFIG_AUTOFS_FS is not set
-+# CONFIG_AUTOFS4_FS is not set
-+# CONFIG_FUSE_FS is not set
-+
-+#
-+# CD-ROM/DVD Filesystems
-+#
-+CONFIG_ISO9660_FS=y
-+# CONFIG_JOLIET is not set
-+# CONFIG_ZISOFS is not set
-+# CONFIG_UDF_FS is not set
-+
-+#
-+# DOS/FAT/NT Filesystems
-+#
-+CONFIG_FAT_FS=m
-+CONFIG_MSDOS_FS=m
-+CONFIG_VFAT_FS=m
-+CONFIG_FAT_DEFAULT_CODEPAGE=437
-+CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1"
-+# CONFIG_NTFS_FS is not set
-+
-+#
-+# Pseudo filesystems
-+#
-+CONFIG_PROC_FS=y
-+CONFIG_PROC_KCORE=y
-+CONFIG_PROC_SYSCTL=y
-+CONFIG_SYSFS=y
-+CONFIG_TMPFS=y
-+# CONFIG_TMPFS_POSIX_ACL is not set
-+# CONFIG_HUGETLB_PAGE is not set
-+CONFIG_RAMFS=y
-+# CONFIG_CONFIGFS_FS is not set
-+
-+#
-+# Miscellaneous filesystems
-+#
-+# CONFIG_ADFS_FS is not set
-+# CONFIG_AFFS_FS is not set
-+# CONFIG_HFS_FS is not set
-+# CONFIG_HFSPLUS_FS is not set
-+# CONFIG_BEFS_FS is not set
-+# CONFIG_BFS_FS is not set
-+# CONFIG_EFS_FS is not set
-+# CONFIG_CRAMFS is not set
-+# CONFIG_VXFS_FS is not set
-+# CONFIG_HPFS_FS is not set
-+# CONFIG_QNX4FS_FS is not set
-+# CONFIG_SYSV_FS is not set
-+# CONFIG_UFS_FS is not set
-+
-+#
-+# Network File Systems
-+#
-+# CONFIG_NFS_FS is not set
-+# CONFIG_NFSD is not set
-+# CONFIG_SMB_FS is not set
-+# CONFIG_CIFS is not set
-+# CONFIG_NCP_FS is not set
-+# CONFIG_CODA_FS is not set
-+# CONFIG_AFS_FS is not set
-+
-+#
-+# Partition Types
-+#
-+CONFIG_PARTITION_ADVANCED=y
-+# CONFIG_ACORN_PARTITION is not set
-+# CONFIG_OSF_PARTITION is not set
-+# CONFIG_AMIGA_PARTITION is not set
-+# CONFIG_ATARI_PARTITION is not set
-+CONFIG_MAC_PARTITION=y
-+CONFIG_MSDOS_PARTITION=y
-+# CONFIG_BSD_DISKLABEL is not set
-+# CONFIG_MINIX_SUBPARTITION is not set
-+# CONFIG_SOLARIS_X86_PARTITION is not set
-+# CONFIG_UNIXWARE_DISKLABEL is not set
-+# CONFIG_LDM_PARTITION is not set
-+# CONFIG_SGI_PARTITION is not set
-+# CONFIG_ULTRIX_PARTITION is not set
-+# CONFIG_SUN_PARTITION is not set
-+# CONFIG_KARMA_PARTITION is not set
-+# CONFIG_EFI_PARTITION is not set
-+# CONFIG_SYSV68_PARTITION is not set
-+
-+#
-+# Native Language Support
-+#
-+CONFIG_NLS=y
-+CONFIG_NLS_DEFAULT="iso8859-1"
-+# CONFIG_NLS_CODEPAGE_437 is not set
-+# CONFIG_NLS_CODEPAGE_737 is not set
-+# CONFIG_NLS_CODEPAGE_775 is not set
-+# CONFIG_NLS_CODEPAGE_850 is not set
-+# CONFIG_NLS_CODEPAGE_852 is not set
-+# CONFIG_NLS_CODEPAGE_855 is not set
-+# CONFIG_NLS_CODEPAGE_857 is not set
-+# CONFIG_NLS_CODEPAGE_860 is not set
-+# CONFIG_NLS_CODEPAGE_861 is not set
-+# CONFIG_NLS_CODEPAGE_862 is not set
-+# CONFIG_NLS_CODEPAGE_863 is not set
-+# CONFIG_NLS_CODEPAGE_864 is not set
-+# CONFIG_NLS_CODEPAGE_865 is not set
-+# CONFIG_NLS_CODEPAGE_866 is not set
-+# CONFIG_NLS_CODEPAGE_869 is not set
-+# CONFIG_NLS_CODEPAGE_936 is not set
-+# CONFIG_NLS_CODEPAGE_950 is not set
-+# CONFIG_NLS_CODEPAGE_932 is not set
-+# CONFIG_NLS_CODEPAGE_949 is not set
-+# CONFIG_NLS_CODEPAGE_874 is not set
-+# CONFIG_NLS_ISO8859_8 is not set
-+# CONFIG_NLS_CODEPAGE_1250 is not set
-+# CONFIG_NLS_CODEPAGE_1251 is not set
-+CONFIG_NLS_ASCII=y
-+CONFIG_NLS_ISO8859_1=m
-+# CONFIG_NLS_ISO8859_2 is not set
-+# CONFIG_NLS_ISO8859_3 is not set
-+# CONFIG_NLS_ISO8859_4 is not set
-+# CONFIG_NLS_ISO8859_5 is not set
-+# CONFIG_NLS_ISO8859_6 is not set
-+# CONFIG_NLS_ISO8859_7 is not set
-+# CONFIG_NLS_ISO8859_9 is not set
-+# CONFIG_NLS_ISO8859_13 is not set
-+# CONFIG_NLS_ISO8859_14 is not set
-+# CONFIG_NLS_ISO8859_15 is not set
-+# CONFIG_NLS_KOI8_R is not set
-+# CONFIG_NLS_KOI8_U is not set
-+# CONFIG_NLS_UTF8 is not set
-+
-+#
-+# Distributed Lock Manager
-+#
-+# CONFIG_DLM is not set
-+# CONFIG_UCC_SLOW is not set
-+
-+#
-+# Library routines
-+#
-+CONFIG_BITREVERSE=y
-+CONFIG_CRC_CCITT=m
-+# CONFIG_CRC16 is not set
-+# CONFIG_CRC_ITU_T is not set
-+CONFIG_CRC32=y
-+# CONFIG_CRC7 is not set
-+# CONFIG_LIBCRC32C is not set
-+CONFIG_ZLIB_INFLATE=m
-+CONFIG_ZLIB_DEFLATE=m
-+CONFIG_PLIST=y
-+CONFIG_HAS_IOMEM=y
-+CONFIG_HAS_IOPORT=y
-+CONFIG_HAS_DMA=y
-+
-+#
-+# Instrumentation Support
-+#
-+# CONFIG_PROFILING is not set
-+# CONFIG_KPROBES is not set
-+
-+#
-+# Kernel hacking
-+#
-+# CONFIG_PRINTK_TIME is not set
-+CONFIG_ENABLE_MUST_CHECK=y
-+CONFIG_MAGIC_SYSRQ=y
-+# CONFIG_UNUSED_SYMBOLS is not set
-+# CONFIG_DEBUG_FS is not set
-+# CONFIG_HEADERS_CHECK is not set
-+CONFIG_DEBUG_KERNEL=y
-+# CONFIG_DEBUG_SHIRQ is not set
-+CONFIG_DETECT_SOFTLOCKUP=y
-+CONFIG_SCHED_DEBUG=y
-+# CONFIG_SCHEDSTATS is not set
-+# CONFIG_TIMER_STATS is not set
-+# CONFIG_DEBUG_SLAB is not set
-+# CONFIG_DEBUG_RT_MUTEXES is not set
-+# CONFIG_RT_MUTEX_TESTER is not set
-+# CONFIG_DEBUG_SPINLOCK is not set
-+CONFIG_DEBUG_MUTEXES=y
-+CONFIG_DEBUG_SPINLOCK_SLEEP=y
-+# CONFIG_DEBUG_LOCKING_API_SELFTESTS is not set
-+# CONFIG_DEBUG_KOBJECT is not set
-+# CONFIG_DEBUG_HIGHMEM is not set
-+CONFIG_DEBUG_BUGVERBOSE=y
-+# CONFIG_DEBUG_INFO is not set
-+# CONFIG_DEBUG_VM is not set
-+# CONFIG_DEBUG_LIST is not set
-+CONFIG_FORCED_INLINING=y
-+# CONFIG_RCU_TORTURE_TEST is not set
-+# CONFIG_FAULT_INJECTION is not set
-+# CONFIG_DEBUG_STACKOVERFLOW is not set
-+# CONFIG_DEBUG_STACK_USAGE is not set
-+# CONFIG_DEBUG_PAGEALLOC is not set
-+CONFIG_DEBUGGER=y
-+CONFIG_XMON=y
-+CONFIG_XMON_DEFAULT=y
-+CONFIG_XMON_DISASSEMBLY=y
-+# CONFIG_BDI_SWITCH is not set
-+# CONFIG_BOOTX_TEXT is not set
-+# CONFIG_PPC_EARLY_DEBUG is not set
-+
-+#
-+# Security options
-+#
-+# CONFIG_KEYS is not set
-+# CONFIG_SECURITY is not set
-+CONFIG_CRYPTO=y
-+CONFIG_CRYPTO_ALGAPI=m
-+CONFIG_CRYPTO_BLKCIPHER=m
-+CONFIG_CRYPTO_MANAGER=m
-+# CONFIG_CRYPTO_HMAC is not set
-+# CONFIG_CRYPTO_XCBC is not set
-+# CONFIG_CRYPTO_NULL is not set
-+# CONFIG_CRYPTO_MD4 is not set
-+# CONFIG_CRYPTO_MD5 is not set
-+CONFIG_CRYPTO_SHA1=m
-+# CONFIG_CRYPTO_SHA256 is not set
-+# CONFIG_CRYPTO_SHA512 is not set
-+# CONFIG_CRYPTO_WP512 is not set
-+# CONFIG_CRYPTO_TGR192 is not set
-+# CONFIG_CRYPTO_GF128MUL is not set
-+CONFIG_CRYPTO_ECB=m
-+CONFIG_CRYPTO_CBC=m
-+CONFIG_CRYPTO_PCBC=m
-+# CONFIG_CRYPTO_LRW is not set
-+# CONFIG_CRYPTO_CRYPTD is not set
-+# CONFIG_CRYPTO_DES is not set
-+# CONFIG_CRYPTO_FCRYPT is not set
-+# CONFIG_CRYPTO_BLOWFISH is not set
-+# CONFIG_CRYPTO_TWOFISH is not set
-+# CONFIG_CRYPTO_SERPENT is not set
-+# CONFIG_CRYPTO_AES is not set
-+# CONFIG_CRYPTO_CAST5 is not set
-+# CONFIG_CRYPTO_CAST6 is not set
-+# CONFIG_CRYPTO_TEA is not set
-+CONFIG_CRYPTO_ARC4=m
-+# CONFIG_CRYPTO_KHAZAD is not set
-+# CONFIG_CRYPTO_ANUBIS is not set
-+# CONFIG_CRYPTO_DEFLATE is not set
-+# CONFIG_CRYPTO_MICHAEL_MIC is not set
-+# CONFIG_CRYPTO_CRC32C is not set
-+# CONFIG_CRYPTO_CAMELLIA is not set
-+# CONFIG_CRYPTO_TEST is not set
-+# CONFIG_CRYPTO_HW is not set
-
---- linux-2.6.23/arch/powerpc/Kconfig	2007-10-09 15:31:38.000000000 -0500
-+++ linux/arch/powerpc/Kconfig	2007-10-27 18:22:07.000000000 -0500
-@@ -387,7 +387,7 @@
- 
- config ISA
- 	bool "Support for ISA-bus hardware"
--	depends on PPC_PREP || PPC_CHRP
-+	depends on PPC_PREP || PPC_CHRP || PPC_QEMU
- 	select PPC_I8259
- 	help
- 	  Find out whether you have ISA slots on your motherboard.  ISA is the
--- a/sources/patches/linux-2.6.25-rc1-noperl.patch	Sun Feb 01 16:45:51 2009 -0600
+++ b/sources/patches/linux-2.6.25-rc1-noperl.patch	Sun Feb 01 17:36:28 2009 -0600
@@ -1,232 +1,319 @@
-diff -ru linux-2.6.25-rc1/kernel/timeconst.pl linux-2.6.25-new/kernel/timeconst.pl
---- linux-2.6.25-rc1/kernel/timeconst.pl	2008-02-10 16:18:14.000000000 -0600
-+++ linux-2.6.25-new/kernel/timeconst.pl	2008-02-15 17:52:02.000000000 -0600
-@@ -11,210 +11,10 @@
- #
- 
- #
+From: Rob Landley <rob@landley.net>
+
+Replace kernel/timeconst.pl with kernel/timeconst.sh.  The new shell script
+is much simpler, about 1/4 the size, and runs on Red Hat 9 from 2003.
+
+It requires a shell which can do 64 bit math, such as bash, busybox ash,
+or dash running on a 64 bit host.
+
+Changes from previous version:
+
+Redo ADJ32 math to avoid integer overflow for small HZ sizes (such as 24 or
+122).  In the pathological case (HZ=1) both versions now produce
+USEC_TO_HZ_ADJ32 of 0x7ffff79c842fa.  (See source comments for details.)
+
+Also expand usage message, add error message when no 64 bit math available in
+shell (and suggest some shells that support it), add whitespace around
+operators in equations, added underscores before __KERNEL_TIMECONST_H, change
+makefile so script is responsible for creating output file, make script delete 
+output file on error, change shebang to #!/bin/sh and test with dash and bash.
+
+Signed-off-by: Rob Landley <rob@landley.net>
+---
+
+ kernel/Makefile     |    4 
+ kernel/timeconst.pl |  378 ------------------------------------------
+ kernel/timeconst.sh |  149 ++++++++++++++++
+ 3 files changed, 151 insertions(+), 380 deletions(-)
+
+--- linux-2.6.28/kernel/timeconst.pl	2008-12-24 17:26:37.000000000 -0600
++++ /dev/null	2008-11-21 04:46:41.000000000 -0600
+@@ -1,378 +0,0 @@
+-#!/usr/bin/perl
+-# -----------------------------------------------------------------------
+-#
+-#   Copyright 2007-2008 rPath, Inc. - All Rights Reserved
+-#
+-#   This file is part of the Linux kernel, and is made available under
+-#   the terms of the GNU General Public License version 2 or (at your
+-#   option) any later version; incorporated herein by reference.
+-#
+-# -----------------------------------------------------------------------
+-#
+-
+-#
 -# Usage: timeconst.pl HZ > timeconst.h
-+# Usage: timeconst.pl HZ... > timeconst.h
- #
- 
+-#
+-
 -# Precomputed values for systems without Math::BigInt
 -# Generated by:
- # timeconst.pl --can 24 32 48 64 100 122 128 200 250 256 300 512 1000 1024 1200
+-# timeconst.pl --can 24 32 48 64 100 122 128 200 250 256 300 512 1000 1024 1200
 -%canned_values = (
 -	24 => [
 -		'0xa6aaaaab','0x2aaaaaa',26,
--		'0xa6aaaaaaaaaaaaab','0x2aaaaaaaaaaaaaa',58,
 -		125,3,
 -		'0xc49ba5e4','0x1fbe76c8b4',37,
--		'0xc49ba5e353f7ceda','0x1fbe76c8b439581062',69,
 -		3,125,
 -		'0xa2c2aaab','0xaaaa',16,
--		'0xa2c2aaaaaaaaaaab','0xaaaaaaaaaaaa',48,
 -		125000,3,
 -		'0xc9539b89','0x7fffbce4217d',47,
--		'0xc9539b8887229e91','0x7fffbce4217d2849cb25',79,
 -		3,125000,
 -	], 32 => [
 -		'0xfa000000','0x6000000',27,
--		'0xfa00000000000000','0x600000000000000',59,
 -		125,4,
 -		'0x83126e98','0xfdf3b645a',36,
--		'0x83126e978d4fdf3c','0xfdf3b645a1cac0831',68,
 -		4,125,
 -		'0xf4240000','0x0',17,
--		'0xf424000000000000','0x0',49,
 -		31250,1,
 -		'0x8637bd06','0x3fff79c842fa',46,
--		'0x8637bd05af6c69b6','0x3fff79c842fa5093964a',78,
 -		1,31250,
 -	], 48 => [
 -		'0xa6aaaaab','0x6aaaaaa',27,
--		'0xa6aaaaaaaaaaaaab','0x6aaaaaaaaaaaaaa',59,
 -		125,6,
 -		'0xc49ba5e4','0xfdf3b645a',36,
--		'0xc49ba5e353f7ceda','0xfdf3b645a1cac0831',68,
 -		6,125,
 -		'0xa2c2aaab','0x15555',17,
--		'0xa2c2aaaaaaaaaaab','0x1555555555555',49,
 -		62500,3,
 -		'0xc9539b89','0x3fffbce4217d',46,
--		'0xc9539b8887229e91','0x3fffbce4217d2849cb25',78,
 -		3,62500,
 -	], 64 => [
 -		'0xfa000000','0xe000000',28,
--		'0xfa00000000000000','0xe00000000000000',60,
 -		125,8,
 -		'0x83126e98','0x7ef9db22d',35,
--		'0x83126e978d4fdf3c','0x7ef9db22d0e560418',67,
 -		8,125,
 -		'0xf4240000','0x0',18,
--		'0xf424000000000000','0x0',50,
 -		15625,1,
 -		'0x8637bd06','0x1fff79c842fa',45,
--		'0x8637bd05af6c69b6','0x1fff79c842fa5093964a',77,
 -		1,15625,
 -	], 100 => [
 -		'0xa0000000','0x0',28,
--		'0xa000000000000000','0x0',60,
 -		10,1,
 -		'0xcccccccd','0x733333333',35,
--		'0xcccccccccccccccd','0x73333333333333333',67,
 -		1,10,
 -		'0x9c400000','0x0',18,
--		'0x9c40000000000000','0x0',50,
 -		10000,1,
 -		'0xd1b71759','0x1fff2e48e8a7',45,
--		'0xd1b71758e219652c','0x1fff2e48e8a71de69ad4',77,
 -		1,10000,
 -	], 122 => [
 -		'0x8325c53f','0xfbcda3a',28,
--		'0x8325c53ef368eb05','0xfbcda3ac10c9714',60,
 -		500,61,
 -		'0xf9db22d1','0x7fbe76c8b',35,
--		'0xf9db22d0e560418a','0x7fbe76c8b43958106',67,
 -		61,500,
 -		'0x8012e2a0','0x3ef36',18,
--		'0x8012e29f79b47583','0x3ef368eb04325',50,
 -		500000,61,
 -		'0xffda4053','0x1ffffbce4217',45,
--		'0xffda4052d666a983','0x1ffffbce4217d2849cb2',77,
 -		61,500000,
 -	], 128 => [
 -		'0xfa000000','0x1e000000',29,
--		'0xfa00000000000000','0x1e00000000000000',61,
 -		125,16,
 -		'0x83126e98','0x3f7ced916',34,
--		'0x83126e978d4fdf3c','0x3f7ced916872b020c',66,
 -		16,125,
 -		'0xf4240000','0x40000',19,
--		'0xf424000000000000','0x4000000000000',51,
 -		15625,2,
 -		'0x8637bd06','0xfffbce4217d',44,
--		'0x8637bd05af6c69b6','0xfffbce4217d2849cb25',76,
 -		2,15625,
 -	], 200 => [
 -		'0xa0000000','0x0',29,
--		'0xa000000000000000','0x0',61,
 -		5,1,
 -		'0xcccccccd','0x333333333',34,
--		'0xcccccccccccccccd','0x33333333333333333',66,
 -		1,5,
 -		'0x9c400000','0x0',19,
--		'0x9c40000000000000','0x0',51,
 -		5000,1,
 -		'0xd1b71759','0xfff2e48e8a7',44,
--		'0xd1b71758e219652c','0xfff2e48e8a71de69ad4',76,
 -		1,5000,
 -	], 250 => [
 -		'0x80000000','0x0',29,
--		'0x8000000000000000','0x0',61,
 -		4,1,
 -		'0x80000000','0x180000000',33,
--		'0x8000000000000000','0x18000000000000000',65,
 -		1,4,
 -		'0xfa000000','0x0',20,
--		'0xfa00000000000000','0x0',52,
 -		4000,1,
 -		'0x83126e98','0x7ff7ced9168',43,
--		'0x83126e978d4fdf3c','0x7ff7ced916872b020c4',75,
 -		1,4000,
 -	], 256 => [
 -		'0xfa000000','0x3e000000',30,
--		'0xfa00000000000000','0x3e00000000000000',62,
 -		125,32,
 -		'0x83126e98','0x1fbe76c8b',33,
--		'0x83126e978d4fdf3c','0x1fbe76c8b43958106',65,
 -		32,125,
 -		'0xf4240000','0xc0000',20,
--		'0xf424000000000000','0xc000000000000',52,
 -		15625,4,
 -		'0x8637bd06','0x7ffde7210be',43,
--		'0x8637bd05af6c69b6','0x7ffde7210be9424e592',75,
 -		4,15625,
 -	], 300 => [
 -		'0xd5555556','0x2aaaaaaa',30,
--		'0xd555555555555556','0x2aaaaaaaaaaaaaaa',62,
 -		10,3,
 -		'0x9999999a','0x1cccccccc',33,
--		'0x999999999999999a','0x1cccccccccccccccc',65,
 -		3,10,
 -		'0xd0555556','0xaaaaa',20,
--		'0xd055555555555556','0xaaaaaaaaaaaaa',52,
 -		10000,3,
 -		'0x9d495183','0x7ffcb923a29',43,
--		'0x9d495182a9930be1','0x7ffcb923a29c779a6b5',75,
 -		3,10000,
 -	], 512 => [
 -		'0xfa000000','0x7e000000',31,
--		'0xfa00000000000000','0x7e00000000000000',63,
 -		125,64,
 -		'0x83126e98','0xfdf3b645',32,
--		'0x83126e978d4fdf3c','0xfdf3b645a1cac083',64,
 -		64,125,
 -		'0xf4240000','0x1c0000',21,
--		'0xf424000000000000','0x1c000000000000',53,
 -		15625,8,
 -		'0x8637bd06','0x3ffef39085f',42,
--		'0x8637bd05af6c69b6','0x3ffef39085f4a1272c9',74,
 -		8,15625,
 -	], 1000 => [
 -		'0x80000000','0x0',31,
--		'0x8000000000000000','0x0',63,
 -		1,1,
 -		'0x80000000','0x0',31,
--		'0x8000000000000000','0x0',63,
 -		1,1,
 -		'0xfa000000','0x0',22,
--		'0xfa00000000000000','0x0',54,
 -		1000,1,
 -		'0x83126e98','0x1ff7ced9168',41,
--		'0x83126e978d4fdf3c','0x1ff7ced916872b020c4',73,
 -		1,1000,
 -	], 1024 => [
 -		'0xfa000000','0xfe000000',32,
--		'0xfa00000000000000','0xfe00000000000000',64,
 -		125,128,
 -		'0x83126e98','0x7ef9db22',31,
--		'0x83126e978d4fdf3c','0x7ef9db22d0e56041',63,
 -		128,125,
 -		'0xf4240000','0x3c0000',22,
--		'0xf424000000000000','0x3c000000000000',54,
 -		15625,16,
 -		'0x8637bd06','0x1fff79c842f',41,
--		'0x8637bd05af6c69b6','0x1fff79c842fa5093964',73,
 -		16,15625,
 -	], 1200 => [
 -		'0xd5555556','0xd5555555',32,
--		'0xd555555555555556','0xd555555555555555',64,
 -		5,6,
 -		'0x9999999a','0x66666666',31,
--		'0x999999999999999a','0x6666666666666666',63,
 -		6,5,
 -		'0xd0555556','0x2aaaaa',22,
--		'0xd055555555555556','0x2aaaaaaaaaaaaa',54,
 -		2500,3,
 -		'0x9d495183','0x1ffcb923a29',41,
--		'0x9d495182a9930be1','0x1ffcb923a29c779a6b5',73,
 -		3,2500,
 -	]
 -);
- 
- $has_bigint = eval 'use Math::BigInt qw(bgcd); 1;';
- 
-@@ -305,8 +105,7 @@
- 	my $s, $m, $a, $g;
- 
- 	if (!$has_bigint) {
+-
+-$has_bigint = eval 'use Math::BigInt qw(bgcd); 1;';
+-
+-sub bint($)
+-{
+-	my($x) = @_;
+-	return Math::BigInt->new($x);
+-}
+-
+-#
+-# Constants for division by reciprocal multiplication.
+-# (bits, numerator, denominator)
+-#
+-sub fmul($$$)
+-{
+-	my ($b,$n,$d) = @_;
+-
+-	$n = bint($n);
+-	$d = bint($d);
+-
+-	return scalar (($n << $b)+$d-bint(1))/$d;
+-}
+-
+-sub fadj($$$)
+-{
+-	my($b,$n,$d) = @_;
+-
+-	$n = bint($n);
+-	$d = bint($d);
+-
+-	$d = $d/bgcd($n, $d);
+-	return scalar (($d-bint(1)) << $b)/$d;
+-}
+-
+-sub fmuls($$$) {
+-	my($b,$n,$d) = @_;
+-	my($s,$m);
+-	my($thres) = bint(1) << ($b-1);
+-
+-	$n = bint($n);
+-	$d = bint($d);
+-
+-	for ($s = 0; 1; $s++) {
+-		$m = fmul($s,$n,$d);
+-		return $s if ($m >= $thres);
+-	}
+-	return 0;
+-}
+-
+-# Generate a hex value if the result fits in 64 bits;
+-# otherwise skip.
+-sub bignum_hex($) {
+-	my($x) = @_;
+-	my $s = $x->as_hex();
+-
+-	return (length($s) > 18) ? undef : $s;
+-}
+-
+-# Provides mul, adj, and shr factors for a specific
+-# (bit, time, hz) combination
+-sub muladj($$$) {
+-	my($b, $t, $hz) = @_;
+-	my $s = fmuls($b, $t, $hz);
+-	my $m = fmul($s, $t, $hz);
+-	my $a = fadj($s, $t, $hz);
+-	return (bignum_hex($m), bignum_hex($a), $s);
+-}
+-
+-# Provides numerator, denominator values
+-sub numden($$) {
+-	my($n, $d) = @_;
+-	my $g = bgcd($n, $d);
+-	return ($n/$g, $d/$g);
+-}
+-
+-# All values for a specific (time, hz) combo
+-sub conversions($$) {
+-	my ($t, $hz) = @_;
+-	my @val = ();
+-
+-	# HZ_TO_xx
+-	push(@val, muladj(32, $t, $hz));
+-	push(@val, numden($t, $hz));
+-
+-	# xx_TO_HZ
+-	push(@val, muladj(32, $hz, $t));
+-	push(@val, numden($hz, $t));
+-
+-	return @val;
+-}
+-
+-sub compute_values($) {
+-	my($hz) = @_;
+-	my @val = ();
+-	my $s, $m, $a, $g;
+-
+-	if (!$has_bigint) {
 -		die "$0: HZ == $hz not canned and ".
 -		    "Math::BigInt not available\n";
-+		die "$0: Math::BigInt not available\n";
- 	}
- 
- 	# MSEC conversions
-@@ -323,19 +122,7 @@
- 	my($hz, @val) = @_;
- 	my $pfx, $bit, $suf, $s, $m, $a;
- 
+-	}
+-
+-	# MSEC conversions
+-	push(@val, conversions(1000, $hz));
+-
+-	# USEC conversions
+-	push(@val, conversions(1000000, $hz));
+-
+-	return @val;
+-}
+-
+-sub outputval($$)
+-{
+-	my($name, $val) = @_;
+-	my $csuf;
+-
+-	if (defined($val)) {
+-	    if ($name !~ /SHR/) {
+-		$val = "U64_C($val)";
+-	    }
+-	    printf "#define %-23s %s\n", $name.$csuf, $val.$csuf;
+-	}
+-}
+-
+-sub output($@)
+-{
+-	my($hz, @val) = @_;
+-	my $pfx, $bit, $suf, $s, $m, $a;
+-
 -	print "/* Automatically generated by kernel/timeconst.pl */\n";
 -	print "/* Conversion constants for HZ == $hz */\n";
 -	print "\n";
@@ -235,27 +322,49 @@
 -	print "\n";
 -
 -	print "#include <linux/param.h>\n";
+-	print "#include <linux/types.h>\n";
 -
 -	print "\n";
 -	print "#if HZ != $hz\n";
 -	print "#error \"kernel/timeconst.h has the wrong HZ value!\"\n";
 -	print "#endif\n";
-+	print "HZ == $hz\n";
- 	print "\n";
- 
- 	foreach $pfx ('HZ_TO_MSEC','MSEC_TO_HZ',
-@@ -352,51 +139,37 @@
- 		}
- 	}
- 
+-	print "\n";
+-
+-	foreach $pfx ('HZ_TO_MSEC','MSEC_TO_HZ',
+-		      'HZ_TO_USEC','USEC_TO_HZ') {
+-		foreach $bit (32) {
+-			foreach $suf ('MUL', 'ADJ', 'SHR') {
+-				outputval("${pfx}_$suf$bit", shift(@val));
+-			}
+-		}
+-		foreach $suf ('NUM', 'DEN') {
+-			outputval("${pfx}_$suf", shift(@val));
+-		}
+-	}
+-
 -	print "\n";
 -	print "#endif /* KERNEL_TIMECONST_H */\n";
-+	print "\n#elif "
- }
- 
+-}
+-
+-# Pretty-print Perl values
+-sub perlvals(@) {
+-	my $v;
+-	my @l = ();
+-
+-	foreach $v (@_) {
+-		if (!defined($v)) {
+-			push(@l, 'undef');
+-		} elsif ($v =~ /^0x/) {
+-			push(@l, "\'".$v."\'");
+-		} else {
+-			push(@l, $v.'');
+-		}
+-	}
+-	return join(',', @l);
+-}
+-
 -($hz) = @ARGV;
-+#($hz) = @ARGV;
- 
+-
 -# Use this to generate the %canned_values structure
 -if ($hz eq '--can') {
 -	shift(@ARGV);
@@ -271,15 +380,15 @@
 -		print "$pf$hz => [\n";
 -		while (scalar(@values)) {
 -			my $bit;
--			foreach $bit (32, 64) {
+-			foreach $bit (32) {
 -				my $m = shift(@values);
 -				my $a = shift(@values);
 -				my $s = shift(@values);
--				print "\t\t\'",$m,"\',\'",$a,"\',",$s,",\n";
+-				print "\t\t", perlvals($m,$a,$s), ",\n";
 -			}
 -			my $n = shift(@values);
 -			my $d = shift(@values);
--			print "\t\t",$n,',',$d,",\n";
+-			print "\t\t", perlvals($n,$d), ",\n";
 -		}
 -		print "\t]";
 -		$pf = ', ';
@@ -287,589 +396,176 @@
 -	print "\n);\n";
 -} else {
 -	$hz += 0;			# Force to number
-+print "/* Automatically generated by kernel/timeconst.pl */\n";
-+print "/* Conversion constants for HZ */\n";
-+print "\n";
-+print "#ifndef KERNEL_TIMECONST_H\n";
-+print "#define KERNEL_TIMECONST_H\n";
-+print "\n";
-+
-+print "#include <linux/param.h>\n";
-+
-+print "#if ";
-+
-+foreach $hz (@ARGV)
-+{
-+	#$hz += 0;			# Force to number
- 	if ($hz < 1) {
- 		die "Usage: $0 HZ\n";
- 	}
- 
+-	if ($hz < 1) {
+-		die "Usage: $0 HZ\n";
+-	}
+-
 -	@val = @{$canned_values{$hz}};
 -	if (!defined(@val)) {
 -		@val = compute_values($hz);
 -	}
-+	@val = compute_values($hz);
- 	output($hz, @val);
- }
+-	output($hz, @val);
+-}
+-exit 0;
+--- /dev/null	2008-11-21 04:46:41.000000000 -0600
++++ linux-2.6.28-new/kernel/timeconst.sh	2009-01-03 15:24:01.000000000 -0600
+@@ -0,0 +1,147 @@
++#!/bin/sh
 +
-+print "1\n";
-+print "#error \"kernel/timeconst.h has unknown HZ value!\"\n";
-+print "#endif\n";
-+print "\n";
-+print "#endif /* KERNEL_TIMECONST_H */\n";
++if [ $# -ne 2 ]
++then
++	echo "Usage: timeconst.sh HZ FILENAME"
++	echo
++	echo "Generate a header file with constants for coverting between"
++	echo "decimal HZ timer ticks and milisecond or microsecond delays."
++	echo
++	exit 1
++fi
++
++HZ=$1
++shift
++FILENAME=$1
 +
- exit 0;
---- /dev/null	2007-10-16 17:06:33.000000000 -0500
-+++ linux-new/kernel/timeconst.h	2008-02-15 18:39:01.000000000 -0600
-@@ -0,0 +1,537 @@
-+/* Automatically generated by kernel/timeconst.pl */
-+/* Conversion constants for HZ */
++# Sanity test: even the shell in Red Hat 9 (circa 2003) supported 64 bit math.
++
++if [ $((1 << 32)) -lt 0 ]
++then
++	echo "timeconst.sh needs a shell with 64 bit math, such as bash,"
++	echo "busybox ash, or dash running on a 64 bit host."
++	exit 1
++fi
 +
-+#ifndef KERNEL_TIMECONST_H
-+#define KERNEL_TIMECONST_H
++# If this script exits for any reason before this trap is removed,
++# delete the output file so a partial file won't confuse the build.
++
++trap "rm $FILENAME" EXIT
++
++# Output start of header file
++
++cat > $FILENAME << EOF || exit 1
++/* Automatically generated by kernel/timeconst.sh */
++/* Conversion constants for HZ == $HZ */
++
++#ifndef __KERNEL_TIMECONST_H
++#define __KERNEL_TIMECONST_H
 +
 +#include <linux/param.h>
-+#if HZ == 24
-+
-+#define HZ_TO_MSEC_MUL32        0xa6aaaaab
-+#define HZ_TO_MSEC_ADJ32        0x2aaaaaa
-+#define HZ_TO_MSEC_SHR32        26
-+#define HZ_TO_MSEC_MUL64        0xa6aaaaaaaaaaaaab
-+#define HZ_TO_MSEC_ADJ64        0x2aaaaaaaaaaaaaa
-+#define HZ_TO_MSEC_SHR64        58
-+#define HZ_TO_MSEC_NUM          125
-+#define HZ_TO_MSEC_DEN          3
-+#define MSEC_TO_HZ_MUL32        0xc49ba5e4
-+#define MSEC_TO_HZ_ADJ32        0x1fbe76c8b4
-+#define MSEC_TO_HZ_SHR32        37
-+#define MSEC_TO_HZ_MUL64        0xc49ba5e353f7ceda
-+#define MSEC_TO_HZ_ADJ64        0x1fbe76c8b439581062
-+#define MSEC_TO_HZ_SHR64        69
-+#define MSEC_TO_HZ_NUM          3
-+#define MSEC_TO_HZ_DEN          125
-+#define HZ_TO_USEC_MUL32        0xa2c2aaab
-+#define HZ_TO_USEC_ADJ32        0xaaaa
-+#define HZ_TO_USEC_SHR32        16
-+#define HZ_TO_USEC_MUL64        0xa2c2aaaaaaaaaaab
-+#define HZ_TO_USEC_ADJ64        0xaaaaaaaaaaaa
-+#define HZ_TO_USEC_SHR64        48
-+#define HZ_TO_USEC_NUM          125000
-+#define HZ_TO_USEC_DEN          3
-+#define USEC_TO_HZ_MUL32        0xc9539b89
-+#define USEC_TO_HZ_ADJ32        0x7fffbce4217d
-+#define USEC_TO_HZ_SHR32        47
-+#define USEC_TO_HZ_MUL64        0xc9539b8887229e91
-+#define USEC_TO_HZ_ADJ64        0x7fffbce4217d2849cb25
-+#define USEC_TO_HZ_SHR64        79
-+#define USEC_TO_HZ_NUM          3
-+#define USEC_TO_HZ_DEN          125000
-+
-+#elif HZ == 32
-+
-+#define HZ_TO_MSEC_MUL32        0xfa000000
-+#define HZ_TO_MSEC_ADJ32        0x6000000
-+#define HZ_TO_MSEC_SHR32        27
-+#define HZ_TO_MSEC_MUL64        0xfa00000000000000
-+#define HZ_TO_MSEC_ADJ64        0x600000000000000
-+#define HZ_TO_MSEC_SHR64        59
-+#define HZ_TO_MSEC_NUM          125
-+#define HZ_TO_MSEC_DEN          4
-+#define MSEC_TO_HZ_MUL32        0x83126e98
-+#define MSEC_TO_HZ_ADJ32        0xfdf3b645a
-+#define MSEC_TO_HZ_SHR32        36
-+#define MSEC_TO_HZ_MUL64        0x83126e978d4fdf3c
-+#define MSEC_TO_HZ_ADJ64        0xfdf3b645a1cac0831
-+#define MSEC_TO_HZ_SHR64        68
-+#define MSEC_TO_HZ_NUM          4
-+#define MSEC_TO_HZ_DEN          125
-+#define HZ_TO_USEC_MUL32        0xf4240000
-+#define HZ_TO_USEC_ADJ32        0x0
-+#define HZ_TO_USEC_SHR32        17
-+#define HZ_TO_USEC_MUL64        0xf424000000000000
-+#define HZ_TO_USEC_ADJ64        0x0
-+#define HZ_TO_USEC_SHR64        49
-+#define HZ_TO_USEC_NUM          31250
-+#define HZ_TO_USEC_DEN          1
-+#define USEC_TO_HZ_MUL32        0x8637bd06
-+#define USEC_TO_HZ_ADJ32        0x3fff79c842fa
-+#define USEC_TO_HZ_SHR32        46
-+#define USEC_TO_HZ_MUL64        0x8637bd05af6c69b6
-+#define USEC_TO_HZ_ADJ64        0x3fff79c842fa5093964a
-+#define USEC_TO_HZ_SHR64        78
-+#define USEC_TO_HZ_NUM          1
-+#define USEC_TO_HZ_DEN          31250
-+
-+#elif HZ == 48
-+
-+#define HZ_TO_MSEC_MUL32        0xa6aaaaab
-+#define HZ_TO_MSEC_ADJ32        0x6aaaaaa
-+#define HZ_TO_MSEC_SHR32        27
-+#define HZ_TO_MSEC_MUL64        0xa6aaaaaaaaaaaaab
-+#define HZ_TO_MSEC_ADJ64        0x6aaaaaaaaaaaaaa
-+#define HZ_TO_MSEC_SHR64        59
-+#define HZ_TO_MSEC_NUM          125
-+#define HZ_TO_MSEC_DEN          6
-+#define MSEC_TO_HZ_MUL32        0xc49ba5e4
-+#define MSEC_TO_HZ_ADJ32        0xfdf3b645a
-+#define MSEC_TO_HZ_SHR32        36
-+#define MSEC_TO_HZ_MUL64        0xc49ba5e353f7ceda
-+#define MSEC_TO_HZ_ADJ64        0xfdf3b645a1cac0831
-+#define MSEC_TO_HZ_SHR64        68
-+#define MSEC_TO_HZ_NUM          6
-+#define MSEC_TO_HZ_DEN          125
-+#define HZ_TO_USEC_MUL32        0xa2c2aaab
-+#define HZ_TO_USEC_ADJ32        0x15555
-+#define HZ_TO_USEC_SHR32        17
-+#define HZ_TO_USEC_MUL64        0xa2c2aaaaaaaaaaab
-+#define HZ_TO_USEC_ADJ64        0x1555555555555
-+#define HZ_TO_USEC_SHR64        49
-+#define HZ_TO_USEC_NUM          62500
-+#define HZ_TO_USEC_DEN          3
-+#define USEC_TO_HZ_MUL32        0xc9539b89
-+#define USEC_TO_HZ_ADJ32        0x3fffbce4217d
-+#define USEC_TO_HZ_SHR32        46
-+#define USEC_TO_HZ_MUL64        0xc9539b8887229e91
-+#define USEC_TO_HZ_ADJ64        0x3fffbce4217d2849cb25
-+#define USEC_TO_HZ_SHR64        78
-+#define USEC_TO_HZ_NUM          3
-+#define USEC_TO_HZ_DEN          62500
-+
-+#elif HZ == 64
-+
-+#define HZ_TO_MSEC_MUL32        0xfa000000
-+#define HZ_TO_MSEC_ADJ32        0xe000000
-+#define HZ_TO_MSEC_SHR32        28
-+#define HZ_TO_MSEC_MUL64        0xfa00000000000000
-+#define HZ_TO_MSEC_ADJ64        0xe00000000000000
-+#define HZ_TO_MSEC_SHR64        60
-+#define HZ_TO_MSEC_NUM          125
-+#define HZ_TO_MSEC_DEN          8
-+#define MSEC_TO_HZ_MUL32        0x83126e98
-+#define MSEC_TO_HZ_ADJ32        0x7ef9db22d
-+#define MSEC_TO_HZ_SHR32        35
-+#define MSEC_TO_HZ_MUL64        0x83126e978d4fdf3c
-+#define MSEC_TO_HZ_ADJ64        0x7ef9db22d0e560418
-+#define MSEC_TO_HZ_SHR64        67
-+#define MSEC_TO_HZ_NUM          8
-+#define MSEC_TO_HZ_DEN          125
-+#define HZ_TO_USEC_MUL32        0xf4240000
-+#define HZ_TO_USEC_ADJ32        0x0
-+#define HZ_TO_USEC_SHR32        18
-+#define HZ_TO_USEC_MUL64        0xf424000000000000
-+#define HZ_TO_USEC_ADJ64        0x0
-+#define HZ_TO_USEC_SHR64        50
-+#define HZ_TO_USEC_NUM          15625
-+#define HZ_TO_USEC_DEN          1
-+#define USEC_TO_HZ_MUL32        0x8637bd06
-+#define USEC_TO_HZ_ADJ32        0x1fff79c842fa
-+#define USEC_TO_HZ_SHR32        45
-+#define USEC_TO_HZ_MUL64        0x8637bd05af6c69b6
-+#define USEC_TO_HZ_ADJ64        0x1fff79c842fa5093964a
-+#define USEC_TO_HZ_SHR64        77
-+#define USEC_TO_HZ_NUM          1
-+#define USEC_TO_HZ_DEN          15625
-+
-+#elif HZ == 100
-+
-+#define HZ_TO_MSEC_MUL32        0xa0000000
-+#define HZ_TO_MSEC_ADJ32        0x0
-+#define HZ_TO_MSEC_SHR32        28
-+#define HZ_TO_MSEC_MUL64        0xa000000000000000
-+#define HZ_TO_MSEC_ADJ64        0x0
-+#define HZ_TO_MSEC_SHR64        60
-+#define HZ_TO_MSEC_NUM          10
-+#define HZ_TO_MSEC_DEN          1
-+#define MSEC_TO_HZ_MUL32        0xcccccccd
-+#define MSEC_TO_HZ_ADJ32        0x733333333
-+#define MSEC_TO_HZ_SHR32        35
-+#define MSEC_TO_HZ_MUL64        0xcccccccccccccccd
-+#define MSEC_TO_HZ_ADJ64        0x73333333333333333
-+#define MSEC_TO_HZ_SHR64        67
-+#define MSEC_TO_HZ_NUM          1
-+#define MSEC_TO_HZ_DEN          10
-+#define HZ_TO_USEC_MUL32        0x9c400000
-+#define HZ_TO_USEC_ADJ32        0x0
-+#define HZ_TO_USEC_SHR32        18
-+#define HZ_TO_USEC_MUL64        0x9c40000000000000
-+#define HZ_TO_USEC_ADJ64        0x0
-+#define HZ_TO_USEC_SHR64        50
-+#define HZ_TO_USEC_NUM          10000
-+#define HZ_TO_USEC_DEN          1
-+#define USEC_TO_HZ_MUL32        0xd1b71759
-+#define USEC_TO_HZ_ADJ32        0x1fff2e48e8a7
-+#define USEC_TO_HZ_SHR32        45
-+#define USEC_TO_HZ_MUL64        0xd1b71758e219652c
-+#define USEC_TO_HZ_ADJ64        0x1fff2e48e8a71de69ad4
-+#define USEC_TO_HZ_SHR64        77
-+#define USEC_TO_HZ_NUM          1
-+#define USEC_TO_HZ_DEN          10000
-+
-+#elif HZ == 122
-+
-+#define HZ_TO_MSEC_MUL32        0x8325c53f
-+#define HZ_TO_MSEC_ADJ32        0xfbcda3a
-+#define HZ_TO_MSEC_SHR32        28
-+#define HZ_TO_MSEC_MUL64        0x8325c53ef368eb05
-+#define HZ_TO_MSEC_ADJ64        0xfbcda3ac10c9714
-+#define HZ_TO_MSEC_SHR64        60
-+#define HZ_TO_MSEC_NUM          500
-+#define HZ_TO_MSEC_DEN          61
-+#define MSEC_TO_HZ_MUL32        0xf9db22d1
-+#define MSEC_TO_HZ_ADJ32        0x7fbe76c8b
-+#define MSEC_TO_HZ_SHR32        35
-+#define MSEC_TO_HZ_MUL64        0xf9db22d0e560418a
-+#define MSEC_TO_HZ_ADJ64        0x7fbe76c8b43958106
-+#define MSEC_TO_HZ_SHR64        67
-+#define MSEC_TO_HZ_NUM          61
-+#define MSEC_TO_HZ_DEN          500
-+#define HZ_TO_USEC_MUL32        0x8012e2a0
-+#define HZ_TO_USEC_ADJ32        0x3ef36
-+#define HZ_TO_USEC_SHR32        18
-+#define HZ_TO_USEC_MUL64        0x8012e29f79b47583
-+#define HZ_TO_USEC_ADJ64        0x3ef368eb04325
-+#define HZ_TO_USEC_SHR64        50
-+#define HZ_TO_USEC_NUM          500000
-+#define HZ_TO_USEC_DEN          61
-+#define USEC_TO_HZ_MUL32        0xffda4053
-+#define USEC_TO_HZ_ADJ32        0x1ffffbce4217
-+#define USEC_TO_HZ_SHR32        45
-+#define USEC_TO_HZ_MUL64        0xffda4052d666a983
-+#define USEC_TO_HZ_ADJ64        0x1ffffbce4217d2849cb2
-+#define USEC_TO_HZ_SHR64        77
-+#define USEC_TO_HZ_NUM          61
-+#define USEC_TO_HZ_DEN          500000
-+
-+#elif HZ == 128
-+
-+#define HZ_TO_MSEC_MUL32        0xfa000000
-+#define HZ_TO_MSEC_ADJ32        0x1e000000
-+#define HZ_TO_MSEC_SHR32        29
-+#define HZ_TO_MSEC_MUL64        0xfa00000000000000
-+#define HZ_TO_MSEC_ADJ64        0x1e00000000000000
-+#define HZ_TO_MSEC_SHR64        61
-+#define HZ_TO_MSEC_NUM          125
-+#define HZ_TO_MSEC_DEN          16
-+#define MSEC_TO_HZ_MUL32        0x83126e98
-+#define MSEC_TO_HZ_ADJ32        0x3f7ced916
-+#define MSEC_TO_HZ_SHR32        34
-+#define MSEC_TO_HZ_MUL64        0x83126e978d4fdf3c
-+#define MSEC_TO_HZ_ADJ64        0x3f7ced916872b020c
-+#define MSEC_TO_HZ_SHR64        66
-+#define MSEC_TO_HZ_NUM          16
-+#define MSEC_TO_HZ_DEN          125
-+#define HZ_TO_USEC_MUL32        0xf4240000
-+#define HZ_TO_USEC_ADJ32        0x40000
-+#define HZ_TO_USEC_SHR32        19
-+#define HZ_TO_USEC_MUL64        0xf424000000000000
-+#define HZ_TO_USEC_ADJ64        0x4000000000000
-+#define HZ_TO_USEC_SHR64        51
-+#define HZ_TO_USEC_NUM          15625
-+#define HZ_TO_USEC_DEN          2
-+#define USEC_TO_HZ_MUL32        0x8637bd06
-+#define USEC_TO_HZ_ADJ32        0xfffbce4217d
-+#define USEC_TO_HZ_SHR32        44
-+#define USEC_TO_HZ_MUL64        0x8637bd05af6c69b6
-+#define USEC_TO_HZ_ADJ64        0xfffbce4217d2849cb25
-+#define USEC_TO_HZ_SHR64        76
-+#define USEC_TO_HZ_NUM          2
-+#define USEC_TO_HZ_DEN          15625
-+
-+#elif HZ == 200
++#include <linux/types.h>
 +
-+#define HZ_TO_MSEC_MUL32        0xa0000000
-+#define HZ_TO_MSEC_ADJ32        0x0
-+#define HZ_TO_MSEC_SHR32        29
-+#define HZ_TO_MSEC_MUL64        0xa000000000000000
-+#define HZ_TO_MSEC_ADJ64        0x0
-+#define HZ_TO_MSEC_SHR64        61
-+#define HZ_TO_MSEC_NUM          5
-+#define HZ_TO_MSEC_DEN          1
-+#define MSEC_TO_HZ_MUL32        0xcccccccd
-+#define MSEC_TO_HZ_ADJ32        0x333333333
-+#define MSEC_TO_HZ_SHR32        34
-+#define MSEC_TO_HZ_MUL64        0xcccccccccccccccd
-+#define MSEC_TO_HZ_ADJ64        0x33333333333333333
-+#define MSEC_TO_HZ_SHR64        66
-+#define MSEC_TO_HZ_NUM          1
-+#define MSEC_TO_HZ_DEN          5
-+#define HZ_TO_USEC_MUL32        0x9c400000
-+#define HZ_TO_USEC_ADJ32        0x0
-+#define HZ_TO_USEC_SHR32        19
-+#define HZ_TO_USEC_MUL64        0x9c40000000000000
-+#define HZ_TO_USEC_ADJ64        0x0
-+#define HZ_TO_USEC_SHR64        51
-+#define HZ_TO_USEC_NUM          5000
-+#define HZ_TO_USEC_DEN          1
-+#define USEC_TO_HZ_MUL32        0xd1b71759
-+#define USEC_TO_HZ_ADJ32        0xfff2e48e8a7
-+#define USEC_TO_HZ_SHR32        44
-+#define USEC_TO_HZ_MUL64        0xd1b71758e219652c
-+#define USEC_TO_HZ_ADJ64        0xfff2e48e8a71de69ad4
-+#define USEC_TO_HZ_SHR64        76
-+#define USEC_TO_HZ_NUM          1
-+#define USEC_TO_HZ_DEN          5000
-+
-+#elif HZ == 250
-+
-+#define HZ_TO_MSEC_MUL32        0x80000000
-+#define HZ_TO_MSEC_ADJ32        0x0
-+#define HZ_TO_MSEC_SHR32        29
-+#define HZ_TO_MSEC_MUL64        0x8000000000000000
-+#define HZ_TO_MSEC_ADJ64        0x0
-+#define HZ_TO_MSEC_SHR64        61
-+#define HZ_TO_MSEC_NUM          4
-+#define HZ_TO_MSEC_DEN          1
-+#define MSEC_TO_HZ_MUL32        0x80000000
-+#define MSEC_TO_HZ_ADJ32        0x180000000
-+#define MSEC_TO_HZ_SHR32        33
-+#define MSEC_TO_HZ_MUL64        0x8000000000000000
-+#define MSEC_TO_HZ_ADJ64        0x18000000000000000
-+#define MSEC_TO_HZ_SHR64        65
-+#define MSEC_TO_HZ_NUM          1
-+#define MSEC_TO_HZ_DEN          4
-+#define HZ_TO_USEC_MUL32        0xfa000000
-+#define HZ_TO_USEC_ADJ32        0x0
-+#define HZ_TO_USEC_SHR32        20
-+#define HZ_TO_USEC_MUL64        0xfa00000000000000
-+#define HZ_TO_USEC_ADJ64        0x0
-+#define HZ_TO_USEC_SHR64        52
-+#define HZ_TO_USEC_NUM          4000
-+#define HZ_TO_USEC_DEN          1
-+#define USEC_TO_HZ_MUL32        0x83126e98
-+#define USEC_TO_HZ_ADJ32        0x7ff7ced9168
-+#define USEC_TO_HZ_SHR32        43
-+#define USEC_TO_HZ_MUL64        0x83126e978d4fdf3c
-+#define USEC_TO_HZ_ADJ64        0x7ff7ced916872b020c4
-+#define USEC_TO_HZ_SHR64        75
-+#define USEC_TO_HZ_NUM          1
-+#define USEC_TO_HZ_DEN          4000
-+
-+#elif HZ == 256
-+
-+#define HZ_TO_MSEC_MUL32        0xfa000000
-+#define HZ_TO_MSEC_ADJ32        0x3e000000
-+#define HZ_TO_MSEC_SHR32        30
-+#define HZ_TO_MSEC_MUL64        0xfa00000000000000
-+#define HZ_TO_MSEC_ADJ64        0x3e00000000000000
-+#define HZ_TO_MSEC_SHR64        62
-+#define HZ_TO_MSEC_NUM          125
-+#define HZ_TO_MSEC_DEN          32
-+#define MSEC_TO_HZ_MUL32        0x83126e98
-+#define MSEC_TO_HZ_ADJ32        0x1fbe76c8b
-+#define MSEC_TO_HZ_SHR32        33
-+#define MSEC_TO_HZ_MUL64        0x83126e978d4fdf3c
-+#define MSEC_TO_HZ_ADJ64        0x1fbe76c8b43958106
-+#define MSEC_TO_HZ_SHR64        65
-+#define MSEC_TO_HZ_NUM          32
-+#define MSEC_TO_HZ_DEN          125
-+#define HZ_TO_USEC_MUL32        0xf4240000
-+#define HZ_TO_USEC_ADJ32        0xc0000
-+#define HZ_TO_USEC_SHR32        20
-+#define HZ_TO_USEC_MUL64        0xf424000000000000
-+#define HZ_TO_USEC_ADJ64        0xc000000000000
-+#define HZ_TO_USEC_SHR64        52
-+#define HZ_TO_USEC_NUM          15625
-+#define HZ_TO_USEC_DEN          4
-+#define USEC_TO_HZ_MUL32        0x8637bd06
-+#define USEC_TO_HZ_ADJ32        0x7ffde7210be
-+#define USEC_TO_HZ_SHR32        43
-+#define USEC_TO_HZ_MUL64        0x8637bd05af6c69b6
-+#define USEC_TO_HZ_ADJ64        0x7ffde7210be9424e592
-+#define USEC_TO_HZ_SHR64        75
-+#define USEC_TO_HZ_NUM          4
-+#define USEC_TO_HZ_DEN          15625
-+
-+#elif HZ == 300
-+
-+#define HZ_TO_MSEC_MUL32        0xd5555556
-+#define HZ_TO_MSEC_ADJ32        0x2aaaaaaa
-+#define HZ_TO_MSEC_SHR32        30
-+#define HZ_TO_MSEC_MUL64        0xd555555555555556
-+#define HZ_TO_MSEC_ADJ64        0x2aaaaaaaaaaaaaaa
-+#define HZ_TO_MSEC_SHR64        62
-+#define HZ_TO_MSEC_NUM          10
-+#define HZ_TO_MSEC_DEN          3
-+#define MSEC_TO_HZ_MUL32        0x9999999a
-+#define MSEC_TO_HZ_ADJ32        0x1cccccccc
-+#define MSEC_TO_HZ_SHR32        33
-+#define MSEC_TO_HZ_MUL64        0x999999999999999a
-+#define MSEC_TO_HZ_ADJ64        0x1cccccccccccccccc
-+#define MSEC_TO_HZ_SHR64        65
-+#define MSEC_TO_HZ_NUM          3
-+#define MSEC_TO_HZ_DEN          10
-+#define HZ_TO_USEC_MUL32        0xd0555556
-+#define HZ_TO_USEC_ADJ32        0xaaaaa
-+#define HZ_TO_USEC_SHR32        20
-+#define HZ_TO_USEC_MUL64        0xd055555555555556
-+#define HZ_TO_USEC_ADJ64        0xaaaaaaaaaaaaa
-+#define HZ_TO_USEC_SHR64        52
-+#define HZ_TO_USEC_NUM          10000
-+#define HZ_TO_USEC_DEN          3
-+#define USEC_TO_HZ_MUL32        0x9d495183
-+#define USEC_TO_HZ_ADJ32        0x7ffcb923a29
-+#define USEC_TO_HZ_SHR32        43
-+#define USEC_TO_HZ_MUL64        0x9d495182a9930be1
-+#define USEC_TO_HZ_ADJ64        0x7ffcb923a29c779a6b5
-+#define USEC_TO_HZ_SHR64        75
-+#define USEC_TO_HZ_NUM          3
-+#define USEC_TO_HZ_DEN          10000
-+
-+#elif HZ == 512
-+
-+#define HZ_TO_MSEC_MUL32        0xfa000000
-+#define HZ_TO_MSEC_ADJ32        0x7e000000
-+#define HZ_TO_MSEC_SHR32        31
-+#define HZ_TO_MSEC_MUL64        0xfa00000000000000
-+#define HZ_TO_MSEC_ADJ64        0x7e00000000000000
-+#define HZ_TO_MSEC_SHR64        63
-+#define HZ_TO_MSEC_NUM          125
-+#define HZ_TO_MSEC_DEN          64
-+#define MSEC_TO_HZ_MUL32        0x83126e98
-+#define MSEC_TO_HZ_ADJ32        0xfdf3b645
-+#define MSEC_TO_HZ_SHR32        32
-+#define MSEC_TO_HZ_MUL64        0x83126e978d4fdf3c
-+#define MSEC_TO_HZ_ADJ64        0xfdf3b645a1cac083
-+#define MSEC_TO_HZ_SHR64        64
-+#define MSEC_TO_HZ_NUM          64
-+#define MSEC_TO_HZ_DEN          125
-+#define HZ_TO_USEC_MUL32        0xf4240000
-+#define HZ_TO_USEC_ADJ32        0x1c0000
-+#define HZ_TO_USEC_SHR32        21
-+#define HZ_TO_USEC_MUL64        0xf424000000000000
-+#define HZ_TO_USEC_ADJ64        0x1c000000000000
-+#define HZ_TO_USEC_SHR64        53
-+#define HZ_TO_USEC_NUM          15625
-+#define HZ_TO_USEC_DEN          8
-+#define USEC_TO_HZ_MUL32        0x8637bd06
-+#define USEC_TO_HZ_ADJ32        0x3ffef39085f
-+#define USEC_TO_HZ_SHR32        42
-+#define USEC_TO_HZ_MUL64        0x8637bd05af6c69b6
-+#define USEC_TO_HZ_ADJ64        0x3ffef39085f4a1272c9
-+#define USEC_TO_HZ_SHR64        74
-+#define USEC_TO_HZ_NUM          8
-+#define USEC_TO_HZ_DEN          15625
-+
-+#elif HZ == 1000
-+
-+#define HZ_TO_MSEC_MUL32        0x80000000
-+#define HZ_TO_MSEC_ADJ32        0x0
-+#define HZ_TO_MSEC_SHR32        31
-+#define HZ_TO_MSEC_MUL64        0x8000000000000000
-+#define HZ_TO_MSEC_ADJ64        0x0
-+#define HZ_TO_MSEC_SHR64        63
-+#define HZ_TO_MSEC_NUM          1
-+#define HZ_TO_MSEC_DEN          1
-+#define MSEC_TO_HZ_MUL32        0x80000000
-+#define MSEC_TO_HZ_ADJ32        0x0
-+#define MSEC_TO_HZ_SHR32        31
-+#define MSEC_TO_HZ_MUL64        0x8000000000000000
-+#define MSEC_TO_HZ_ADJ64        0x0
-+#define MSEC_TO_HZ_SHR64        63
-+#define MSEC_TO_HZ_NUM          1
-+#define MSEC_TO_HZ_DEN          1
-+#define HZ_TO_USEC_MUL32        0xfa000000
-+#define HZ_TO_USEC_ADJ32        0x0
-+#define HZ_TO_USEC_SHR32        22
-+#define HZ_TO_USEC_MUL64        0xfa00000000000000
-+#define HZ_TO_USEC_ADJ64        0x0
-+#define HZ_TO_USEC_SHR64        54
-+#define HZ_TO_USEC_NUM          1000
-+#define HZ_TO_USEC_DEN          1
-+#define USEC_TO_HZ_MUL32        0x83126e98
-+#define USEC_TO_HZ_ADJ32        0x1ff7ced9168
-+#define USEC_TO_HZ_SHR32        41
-+#define USEC_TO_HZ_MUL64        0x83126e978d4fdf3c
-+#define USEC_TO_HZ_ADJ64        0x1ff7ced916872b020c4
-+#define USEC_TO_HZ_SHR64        73
-+#define USEC_TO_HZ_NUM          1
-+#define USEC_TO_HZ_DEN          1000
-+
-+#elif HZ == 1024
-+
-+#define HZ_TO_MSEC_MUL32        0xfa000000
-+#define HZ_TO_MSEC_ADJ32        0xfe000000
-+#define HZ_TO_MSEC_SHR32        32
-+#define HZ_TO_MSEC_MUL64        0xfa00000000000000
-+#define HZ_TO_MSEC_ADJ64        0xfe00000000000000
-+#define HZ_TO_MSEC_SHR64        64
-+#define HZ_TO_MSEC_NUM          125
-+#define HZ_TO_MSEC_DEN          128
-+#define MSEC_TO_HZ_MUL32        0x83126e98
-+#define MSEC_TO_HZ_ADJ32        0x7ef9db22
-+#define MSEC_TO_HZ_SHR32        31
-+#define MSEC_TO_HZ_MUL64        0x83126e978d4fdf3c
-+#define MSEC_TO_HZ_ADJ64        0x7ef9db22d0e56041
-+#define MSEC_TO_HZ_SHR64        63
-+#define MSEC_TO_HZ_NUM          128
-+#define MSEC_TO_HZ_DEN          125
-+#define HZ_TO_USEC_MUL32        0xf4240000
-+#define HZ_TO_USEC_ADJ32        0x3c0000
-+#define HZ_TO_USEC_SHR32        22
-+#define HZ_TO_USEC_MUL64        0xf424000000000000
-+#define HZ_TO_USEC_ADJ64        0x3c000000000000
-+#define HZ_TO_USEC_SHR64        54
-+#define HZ_TO_USEC_NUM          15625
-+#define HZ_TO_USEC_DEN          16
-+#define USEC_TO_HZ_MUL32        0x8637bd06
-+#define USEC_TO_HZ_ADJ32        0x1fff79c842f
-+#define USEC_TO_HZ_SHR32        41
-+#define USEC_TO_HZ_MUL64        0x8637bd05af6c69b6
-+#define USEC_TO_HZ_ADJ64        0x1fff79c842fa5093964
-+#define USEC_TO_HZ_SHR64        73
-+#define USEC_TO_HZ_NUM          16
-+#define USEC_TO_HZ_DEN          15625
-+
-+#elif HZ == 1200
-+
-+#define HZ_TO_MSEC_MUL32        0xd5555556
-+#define HZ_TO_MSEC_ADJ32        0xd5555555
-+#define HZ_TO_MSEC_SHR32        32
-+#define HZ_TO_MSEC_MUL64        0xd555555555555556
-+#define HZ_TO_MSEC_ADJ64        0xd555555555555555
-+#define HZ_TO_MSEC_SHR64        64
-+#define HZ_TO_MSEC_NUM          5
-+#define HZ_TO_MSEC_DEN          6
-+#define MSEC_TO_HZ_MUL32        0x9999999a
-+#define MSEC_TO_HZ_ADJ32        0x66666666
-+#define MSEC_TO_HZ_SHR32        31
-+#define MSEC_TO_HZ_MUL64        0x999999999999999a
-+#define MSEC_TO_HZ_ADJ64        0x6666666666666666
-+#define MSEC_TO_HZ_SHR64        63
-+#define MSEC_TO_HZ_NUM          6
-+#define MSEC_TO_HZ_DEN          5
-+#define HZ_TO_USEC_MUL32        0xd0555556
-+#define HZ_TO_USEC_ADJ32        0x2aaaaa
-+#define HZ_TO_USEC_SHR32        22
-+#define HZ_TO_USEC_MUL64        0xd055555555555556
-+#define HZ_TO_USEC_ADJ64        0x2aaaaaaaaaaaaa
-+#define HZ_TO_USEC_SHR64        54
-+#define HZ_TO_USEC_NUM          2500
-+#define HZ_TO_USEC_DEN          3
-+#define USEC_TO_HZ_MUL32        0x9d495183
-+#define USEC_TO_HZ_ADJ32        0x1ffcb923a29
-+#define USEC_TO_HZ_SHR32        41
-+#define USEC_TO_HZ_MUL64        0x9d495182a9930be1
-+#define USEC_TO_HZ_ADJ64        0x1ffcb923a29c779a6b5
-+#define USEC_TO_HZ_SHR64        73
-+#define USEC_TO_HZ_NUM          3
-+#define USEC_TO_HZ_DEN          2500
-+
-+#elif 1
-+#error "kernel/timeconst.h has unknown HZ value!"
++#if HZ != $HZ
++#error "kernel/timeconst.h has the wrong HZ value!"
 +#endif
 +
-+#endif /* KERNEL_TIMECONST_H */
---- linux/hg/kernel/Makefile	2008-02-08 19:06:59.000000000 -0600
-+++ linux-new/kernel/Makefile	2008-02-15 19:32:08.000000000 -0600
-@@ -95,7 +95,7 @@
++EOF
++
++# For both Milliseconds and Microseconds
++
++for i in "MSEC 1000" "USEC 1000000"
++do
++	NAME=$(echo $i | cut -d ' ' -f 1)
++	PERIOD=$(echo $i | cut -d ' ' -f 2)
++
++	# Find greatest common denominator (using Euclid's algorithm)
++
++	A=$HZ
++	B=$PERIOD
++
++	while [ $B -ne 0 ]
++	do
++		C=$(( $A % $B ))
++		A=$B
++		B=$C
++	done
++
++	GCD=$A
++
++	# Do this for each direction (HZ_TO_PERIOD and PERIOD_TO_HZ)
++
++	for DIRECTION in 0 1
++	do
++		if [ $DIRECTION -eq 0 ]
++		then
++			CONVERT="HZ_TO_${NAME}"
++			FROM=$HZ
++			TO=$PERIOD
++		else
++			CONVERT="${NAME}_TO_HZ"
++			FROM=$PERIOD
++			TO=$HZ
++		fi
++
++		# Calculate 32 significant bits of MUL32 data.
++
++		SHIFT=0
++		while true
++		do
++			# This can't overflow 64 bit math.  Pathological case
++			# (TO=1, FROM=1000000) uses around 32+20=52 bits.
++
++			MUL32=$(( ( ( $TO << $SHIFT ) + $FROM - 1 ) / $FROM ))
++
++			# Keep increasing $SHIFT until we've got 32 bits.
++
++			[ $MUL32 -gt $(( 1 << 31 )) ] && break
++			SHIFT=$(( $SHIFT + 1 ))
++		done
++		MUL32=$( printf %x $MUL32 )
++
++		# ADJ32 is just (((FROM/GCD)-1)<<SHIFT)/(FROM/GCD) but this
++		# can overflow 64 bit math (examples, HZ=24 or HZ=122).
++		# Pathological case could use 32+20+20=72 bits.  (And this is
++		# the pathological case because a larger $HZ results in a
++		# smaller $SHIFT, so even insane HZ>USEC cases should be ok.)
++
++		# To get around this, we chop the bottom 32 bits off the
++		# calculation and then reassemble it to avoid overflow:
++		# 32+64=96, which is > 72.
++
++		ADJ32=$(( $FROM / $GCD ))
++		if [ $SHIFT -gt 32 ]
++		then
++			UPPER=$(( ( $ADJ32 - 1 ) << ( $SHIFT - 32 ) ))
++			LOWER=$(( ( $UPPER % $ADJ32 ) << 32 ))
++			ADJ32=$(( ( ( $UPPER / $ADJ32 ) << 32 ) + ( $LOWER / $ADJ32 )))
++		else
++			ADJ32=$(( ( ( $ADJ32 - 1 ) << $SHIFT) / $ADJ32 ))
++		fi
++		ADJ32=$( printf %x $ADJ32 )
++
++		NUM=$(( $TO / $GCD ))
++		DEN=$(( $FROM / $GCD ))
++
++		# Output next chunk of header data to file
++
++		(
++			echo "#define ${CONVERT}_MUL32	U64_C(0x$MUL32)" &&
++			echo "#define ${CONVERT}_ADJ32	U64_C(0x$ADJ32)" &&
++			echo "#define ${CONVERT}_SHR32	$SHIFT" &&
++			echo "#define ${CONVERT}_NUM		U64_C($NUM)" &&
++			echo "#define ${CONVERT}_DEN		U64_C($DEN)"
++		) >> $FILENAME || exit 1
++	done
++done
++
++(
++	echo
++	echo "#endif /* __KERNEL_TIMECHONST_H */"
++) >> $FILENAME || exit 1
++
++# Don't rm $FILENAME on exit anymore.
++
++trap "" EXIT
++
++exit 0
+--- linux-2.6.28/kernel/Makefile	2008-12-24 17:26:37.000000000 -0600
++++ linux-2.6.28-new/kernel/Makefile	2009-01-03 00:40:21.000000000 -0600
+@@ -116,7 +116,7 @@
  $(obj)/time.o: $(obj)/timeconst.h
  
  quiet_cmd_timeconst  = TIMEC   $@
 -      cmd_timeconst  = $(PERL) $< $(CONFIG_HZ) > $@
--targets += timeconst.h
++      cmd_timeconst  = $(CONFIG_SHELL) $< $(CONFIG_HZ) $@
+ targets += timeconst.h
 -$(obj)/timeconst.h: $(src)/timeconst.pl FORCE
-+      cmd_timeconst  = $(PERL) $< \
-+            24 32 48 64 100 122 128 200 250 256 300 512 1000 1024 1200 > $@
-+$(obj)/timeconst.h:
++$(obj)/timeconst.h: $(src)/timeconst.sh FORCE
  	$(call if_changed,timeconst)
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sources/patches/linux-2.6.28-boot-raw.patch	Sun Feb 01 17:36:28 2009 -0600
@@ -0,0 +1,33 @@
+diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
+index f4af967..023604d 100644
+--- a/arch/mips/Kconfig
++++ b/arch/mips/Kconfig
+@@ -670,9 +670,6 @@ config ARC
+ config ARCH_MAY_HAVE_PC_FDC
+ 	bool
+ 
+-config BOOT_RAW
+-	bool
+-
+ config CEVT_BCM1480
+ 	bool
+ 
+@@ -1887,6 +1884,18 @@ config SECCOMP
+ 
+ 	  If unsure, say Y. Only embedded should say N here.
+ 
++config BOOT_RAW
++	bool "Enable the kernel to be executed from the load address"
++	default n
++	help
++	 Allow the kernel to be executed from the load address for
++	 bootloaders which cannot read the ELF format. This places
++	 a jump to start_kernel at the load address.
++
++	 If unsure, say N.
++
++
++
+ endmenu
+ 
+ config RWSEM_GENERIC_SPINLOCK
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sources/patches/linux-2.6.28-perl2.patch	Sun Feb 01 17:36:28 2009 -0600
@@ -0,0 +1,137 @@
+From: Rob Landley <rob@landley.net>
+
+Remove perl from make headers_install by replacing a perl script (doing
+a simple regex search and replace) with a smaller and faster shell script
+implementation.  The new shell script is a single for loop calling sed and
+piping its output through unifdef to produce the target file.
+
+Changes from previous version: Added help text and a check for the right
+number of arguments.  Removed unused ARCH input from script and makefile
+(the makefile incorporates ARCH into INDIR, so the script doesn't care),
+fixed a whitespace mistake in the makefile pointed out by Sam Ravnborg,
+changed the shebang to #!/bin/sh and tested under bash and dash.
+
+
+put_changelog_here
+
+Signed-off-by: Rob Landley <rob@landley.net>
+---
+
+ scripts/Makefile.headersinst |    6 ++--
+ scripts/headers_install.pl   |   46 ---------------------------------
+ scripts/headers_install.sh   |   36 +++++++++++++++++++++++++
+ 3 files changed, 39 insertions(+), 49 deletions(-)
+
+diff -ruN linux-2.6.28/scripts/headers_install.sh linux-2.6.28-new/scripts/headers_install.sh
+--- linux-2.6.28/scripts/headers_install.sh	1969-12-31 18:00:00.000000000 -0600
++++ linux-2.6.28-new/scripts/headers_install.sh	2009-01-02 22:35:17.000000000 -0600
+@@ -0,0 +1,36 @@
++#!/bin/sh
++
++if [ $# -lt 2 ]
++then
++	echo "Usage: headers_install.sh INDIR OUTDIR [FILES...]
++	echo
++	echo "Prepares kernel header files for use by user space, by removing"
++	echo "all compiler.h definitions and #includes, and removing any"
++	echo "#ifdef __KERNEL__ sections."
++	echo
++	echo "INDIR:  directory to read each kernel header FILE from."
++	echo "OUTDIR: directory to write each userspace header FILE to."
++	echo "FILES:  list of header files to operate on."
++
++	exit 1
++fi
++
++# Grab arguments
++
++INDIR="$1"
++shift
++OUTDIR="$1"
++shift
++
++# Iterate through files listed on command line
++
++for i in "$@"
++do
++	sed -r \
++		-e 's/([ \t(])(__user|__force|__iomem)[ \t]/\1/g' \
++		-e 's/__attribute_const__([ \t]|$)/\1/g' \
++		-e 's@^#include <linux/compiler.h>@@' "$INDIR/$i" |
++	scripts/unifdef -U__KERNEL__ - > "$OUTDIR/$i"
++done
++
++exit 0
+diff -ruN linux-2.6.28/scripts/Makefile.headersinst linux-2.6.28-new/scripts/Makefile.headersinst
+--- linux-2.6.28/scripts/Makefile.headersinst	2008-12-24 17:26:37.000000000 -0600
++++ linux-2.6.28-new/scripts/Makefile.headersinst	2009-01-02 22:36:42.000000000 -0600
+@@ -44,8 +44,8 @@
+ quiet_cmd_install = INSTALL $(printdir) ($(words $(all-files))\
+                             file$(if $(word 2, $(all-files)),s))
+       cmd_install = \
+-        $(PERL) $< $(srctree)/$(obj) $(install) $(SRCARCH) $(header-y); \
+-        $(PERL) $< $(objtree)/$(obj) $(install) $(SRCARCH) $(objhdr-y); \
++      $(CONFIG_SHELL) $< $(srctree)/$(obj) $(install) $(header-y); \
++      $(CONFIG_SHELL) $< $(objtree)/$(obj) $(install) $(objhdr-y); \
+         touch $@
+ 
+ quiet_cmd_remove = REMOVE  $(unwanted)
+@@ -64,7 +64,7 @@
+ 	@:
+ 
+ targets += $(install-file)
+-$(install-file): scripts/headers_install.pl $(input-files) FORCE
++$(install-file): scripts/headers_install.sh $(input-files) FORCE
+ 	$(if $(unwanted),$(call cmd,remove),)
+ 	$(if $(wildcard $(dir $@)),,$(shell mkdir -p $(dir $@)))
+ 	$(call if_changed,install)
+diff -ruN linux-2.6.28/scripts/headers_install.pl linux-2.6.28-new/scripts/headers_install.pl
+--- linux-2.6.28/scripts/headers_install.pl	2008-12-24 17:26:37.000000000 -0600
++++ linux-2.6.28-new/scripts/headers_install.pl	1969-12-31 18:00:00.000000000 -0600
+@@ -1,46 +0,0 @@
+-#!/usr/bin/perl -w
+-#
+-# headers_install prepare the listed header files for use in
+-# user space and copy the files to their destination.
+-#
+-# Usage: headers_install.pl readdir installdir arch [files...]
+-# readdir:    dir to open files
+-# installdir: dir to install the files
+-# arch:       current architecture
+-#             arch is used to force a reinstallation when the arch
+-#             changes because kbuild then detect a command line change.
+-# files:      list of files to check
+-#
+-# Step in preparation for users space:
+-# 1) Drop all use of compiler.h definitions
+-# 2) Drop include of compiler.h
+-# 3) Drop all sections defined out by __KERNEL__ (using unifdef)
+-
+-use strict;
+-
+-my ($readdir, $installdir, $arch, @files) = @ARGV;
+-
+-my $unifdef = "scripts/unifdef -U__KERNEL__";
+-
+-foreach my $file (@files) {
+-	local *INFILE;
+-	local *OUTFILE;
+-	my $tmpfile = "$installdir/$file.tmp";
+-	open(INFILE, "<$readdir/$file")
+-		or die "$readdir/$file: $!\n";
+-	open(OUTFILE, ">$tmpfile") or die "$tmpfile: $!\n";
+-	while (my $line = <INFILE>) {
+-		$line =~ s/([\s(])__user\s/$1/g;
+-		$line =~ s/([\s(])__force\s/$1/g;
+-		$line =~ s/([\s(])__iomem\s/$1/g;
+-		$line =~ s/\s__attribute_const__\s/ /g;
+-		$line =~ s/\s__attribute_const__$//g;
+-		$line =~ s/^#include <linux\/compiler.h>//;
+-		printf OUTFILE "%s", $line;
+-	}
+-	close OUTFILE;
+-	close INFILE;
+-	system $unifdef . " $tmpfile > $installdir/$file";
+-	unlink $tmpfile;
+-}
+-exit 0;
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sources/patches/linux-2.6.28-perl3.patch	Sun Feb 01 17:36:28 2009 -0600
@@ -0,0 +1,101 @@
+From: Rob Landley <rob@landley.net>
+
+Convert kernel/cpu/mkcapflags.pl to kernel/cpu/mkcapflags.sh.
+
+This script generates kernel/cpu/capflags.c from include/asm/cpufeature.h.
+
+Changes from last time: changed shebang to #!/bin/sh and tested under bash
+and dash.
+
+Signed-off-by: Rob Landley <rob@landley.net>
+---
+
+ arch/x86/kernel/cpu/Makefile      |    4 +--
+ arch/x86/kernel/cpu/mkcapflags.pl |   32 ----------------------------
+ arch/x86/kernel/cpu/mkcapflags.sh |   28 ++++++++++++++++++++++++
+ 3 files changed, 30 insertions(+), 34 deletions(-)
+
+diff -ruN linux-2.6.28/arch/x86/kernel/cpu/Makefile linux-2.6.28-new/arch/x86/kernel/cpu/Makefile
+--- linux-2.6.28/arch/x86/kernel/cpu/Makefile	2008-12-24 17:26:37.000000000 -0600
++++ linux-2.6.28-new/arch/x86/kernel/cpu/Makefile	2009-01-02 01:10:00.000000000 -0600
+@@ -23,10 +23,10 @@
+ obj-$(CONFIG_X86_LOCAL_APIC) += perfctr-watchdog.o
+ 
+ quiet_cmd_mkcapflags = MKCAP   $@
+-      cmd_mkcapflags = $(PERL) $(srctree)/$(src)/mkcapflags.pl $< $@
++      cmd_mkcapflags = $(CONFIG_SHELL) $(srctree)/$(src)/mkcapflags.sh $< $@
+ 
+ cpufeature = $(src)/../../include/asm/cpufeature.h
+ 
+ targets += capflags.c
+-$(obj)/capflags.c: $(cpufeature) $(src)/mkcapflags.pl FORCE
++$(obj)/capflags.c: $(cpufeature) $(src)/mkcapflags.sh FORCE
+ 	$(call if_changed,mkcapflags)
+diff -ruN linux-2.6.28/arch/x86/kernel/cpu/mkcapflags.pl linux-2.6.28-new/arch/x86/kernel/cpu/mkcapflags.pl
+--- linux-2.6.28/arch/x86/kernel/cpu/mkcapflags.pl	2008-12-24 17:26:37.000000000 -0600
++++ linux-2.6.28-new/arch/x86/kernel/cpu/mkcapflags.pl	1969-12-31 18:00:00.000000000 -0600
+@@ -1,32 +0,0 @@
+-#!/usr/bin/perl
+-#
+-# Generate the x86_cap_flags[] array from include/asm-x86/cpufeature.h
+-#
+-
+-($in, $out) = @ARGV;
+-
+-open(IN, "< $in\0")   or die "$0: cannot open: $in: $!\n";
+-open(OUT, "> $out\0") or die "$0: cannot create: $out: $!\n";
+-
+-print OUT "#include <asm/cpufeature.h>\n\n";
+-print OUT "const char * const x86_cap_flags[NCAPINTS*32] = {\n";
+-
+-while (defined($line = <IN>)) {
+-	if ($line =~ /^\s*\#\s*define\s+(X86_FEATURE_(\S+))\s+(.*)$/) {
+-		$macro = $1;
+-		$feature = $2;
+-		$tail = $3;
+-		if ($tail =~ /\/\*\s*\"([^"]*)\".*\*\//) {
+-			$feature = $1;
+-		}
+-
+-		if ($feature ne '') {
+-			printf OUT "\t%-32s = \"%s\",\n",
+-				"[$macro]", "\L$feature";
+-		}
+-	}
+-}
+-print OUT "};\n";
+-
+-close(IN);
+-close(OUT);
+diff -ruN linux-2.6.28/arch/x86/kernel/cpu/mkcapflags.sh linux-2.6.28-new/arch/x86/kernel/cpu/mkcapflags.sh
+--- linux-2.6.28/arch/x86/kernel/cpu/mkcapflags.sh	1969-12-31 18:00:00.000000000 -0600
++++ linux-2.6.28-new/arch/x86/kernel/cpu/mkcapflags.sh	2009-01-02 01:10:00.000000000 -0600
+@@ -0,0 +1,28 @@
++#!/bin/sh
++#
++# Generate the x86_cap_flags[] array from include/asm/cpufeature.h
++#
++
++IN=$1
++OUT=$2
++
++(
++	echo "#include <asm/cpufeature.h>"
++	echo ""
++	echo "const char * const x86_cap_flags[NCAPINTS*32] = {"
++
++	# Iterate through any input lines starting with #define X86_FEATURE_
++	sed -n -e 's/\t/ /g' -e 's/^ *# *define *X86_FEATURE_//p' $IN |
++	while read i
++	do
++		# Name is everything up to the first whitespace
++		NAME="$(echo "$i" | sed 's/ .*//')"
++
++		# If the /* comment */ starts with a quote string, grab that.
++		VALUE="$(echo "$i" | sed -n 's@.*/\* *\("[^"]*"\).*\*/@\1@p')"
++		[ -z "$VALUE" ] && VALUE="\"$(echo "$NAME" | tr A-Z a-z)\""
++
++		[ "$VALUE" != '""' ] && echo "	[X86_FEATURE_$NAME] = $VALUE,"
++	done
++	echo "};"
++) > $OUT
--- a/sources/patches/linux-bcm47xx.patch	Sun Feb 01 16:45:51 2009 -0600
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,2468 +0,0 @@
-This patch does three things:
-
-1) Add gigabit support to the broadcom ssb ethernet driver.
-
-2) Add code to read environment variables from the CFE boot loader, and use
-   them during boot.
-
-3) Add code to read the CFE flash partitions as mtd partitions.
-
-diff -ruN linux-2.6.25.10/arch/mips/bcm47xx/cfe_env.c linux-new/arch/mips/bcm47xx/cfe_env.c
---- linux-2.6.25.10/arch/mips/bcm47xx/cfe_env.c	1969-12-31 18:00:00.000000000 -0600
-+++ linux-new/arch/mips/bcm47xx/cfe_env.c	2009-01-09 21:45:52.000000000 -0600
-@@ -0,0 +1,229 @@
-+/*
-+ * CFE environment variable access
-+ *
-+ * Copyright 2001-2003, Broadcom Corporation
-+ * Copyright 2006, Felix Fietkau <nbd@openwrt.org>
-+ * 
-+ * 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.
-+ */
-+
-+#include <linux/init.h>
-+#include <linux/module.h>
-+#include <linux/kernel.h>
-+#include <linux/string.h>
-+#include <asm/io.h>
-+#include <asm/uaccess.h>
-+
-+#define NVRAM_SIZE       (0x1ff0)
-+static char _nvdata[NVRAM_SIZE];
-+static char _valuestr[256];
-+
-+/*
-+ * TLV types.  These codes are used in the "type-length-value"
-+ * encoding of the items stored in the NVRAM device (flash or EEPROM)
-+ *
-+ * The layout of the flash/nvram is as follows:
-+ *
-+ * <type> <length> <data ...> <type> <length> <data ...> <type_end>
-+ *
-+ * The type code of "ENV_TLV_TYPE_END" marks the end of the list.
-+ * The "length" field marks the length of the data section, not
-+ * including the type and length fields.
-+ *
-+ * Environment variables are stored as follows:
-+ *
-+ * <type_env> <length> <flags> <name> = <value>
-+ *
-+ * If bit 0 (low bit) is set, the length is an 8-bit value.
-+ * If bit 0 (low bit) is clear, the length is a 16-bit value
-+ * 
-+ * Bit 7 set indicates "user" TLVs.  In this case, bit 0 still
-+ * indicates the size of the length field.  
-+ *
-+ * Flags are from the constants below:
-+ *
-+ */
-+#define ENV_LENGTH_16BITS	0x00	/* for low bit */
-+#define ENV_LENGTH_8BITS	0x01
-+
-+#define ENV_TYPE_USER		0x80
-+
-+#define ENV_CODE_SYS(n,l) (((n)<<1)|(l))
-+#define ENV_CODE_USER(n,l) ((((n)<<1)|(l)) | ENV_TYPE_USER)
-+
-+/*
-+ * The actual TLV types we support
-+ */
-+
-+#define ENV_TLV_TYPE_END	0x00	
-+#define ENV_TLV_TYPE_ENV	ENV_CODE_SYS(0,ENV_LENGTH_8BITS)
-+
-+/*
-+ * Environment variable flags 
-+ */
-+
-+#define ENV_FLG_NORMAL		0x00	/* normal read/write */
-+#define ENV_FLG_BUILTIN		0x01	/* builtin - not stored in flash */
-+#define ENV_FLG_READONLY	0x02	/* read-only - cannot be changed */
-+
-+#define ENV_FLG_MASK		0xFF	/* mask of attributes we keep */
-+#define ENV_FLG_ADMIN		0x100	/* lets us internally override permissions */
-+
-+
-+/*  *********************************************************************
-+    *  _nvram_read(buffer,offset,length)
-+    *  
-+    *  Read data from the NVRAM device
-+    *  
-+    *  Input parameters: 
-+    *  	   buffer - destination buffer
-+    *  	   offset - offset of data to read
-+    *  	   length - number of bytes to read
-+    *  	   
-+    *  Return value:
-+    *  	   number of bytes read, or <0 if error occured
-+    ********************************************************************* */
-+static int
-+_nvram_read(unsigned char *nv_buf, unsigned char *buffer, int offset, int length)
-+{
-+    int i;
-+    if (offset > NVRAM_SIZE)
-+	return -1; 
-+
-+    for ( i = 0; i < length; i++) {
-+	buffer[i] = ((volatile unsigned char*)nv_buf)[offset + i];
-+    }
-+    return length;
-+}
-+
-+
-+static char*
-+_strnchr(const char *dest,int c,size_t cnt)
-+{
-+	while (*dest && (cnt > 0)) {
-+	if (*dest == c) return (char *) dest;
-+	dest++;
-+	cnt--;
-+	}
-+	return NULL;
-+}
-+
-+
-+
-+/*
-+ * Core support API: Externally visible.
-+ */
-+
-+/*
-+ * Get the value of an NVRAM variable
-+ * @param	name	name of variable to get
-+ * @return	value of variable or NULL if undefined
-+ */
-+
-+char* 
-+cfe_env_get(unsigned char *nv_buf, char* name)
-+{
-+    int size;
-+    unsigned char *buffer;
-+    unsigned char *ptr;
-+    unsigned char *envval;
-+    unsigned int reclen;
-+    unsigned int rectype;
-+    int offset;
-+    int flg;
-+    
-+	if (!strcmp(name, "nvram_type"))
-+		return "cfe";
-+	
-+    size = NVRAM_SIZE;
-+    buffer = &_nvdata[0];
-+
-+    ptr = buffer;
-+    offset = 0;
-+
-+    /* Read the record type and length */
-+    if (_nvram_read(nv_buf, ptr,offset,1) != 1) {
-+	goto error;
-+    }
-+    
-+    while ((*ptr != ENV_TLV_TYPE_END)  && (size > 1)) {
-+
-+	/* Adjust pointer for TLV type */
-+	rectype = *(ptr);
-+	offset++;
-+	size--;
-+
-+	/* 
-+	 * Read the length.  It can be either 1 or 2 bytes
-+	 * depending on the code 
-+	 */
-+	if (rectype & ENV_LENGTH_8BITS) {
-+	    /* Read the record type and length - 8 bits */
-+	    if (_nvram_read(nv_buf, ptr,offset,1) != 1) {
-+		goto error;
-+	    }
-+	    reclen = *(ptr);
-+	    size--;
-+	    offset++;
-+	}
-+	else {
-+	    /* Read the record type and length - 16 bits, MSB first */
-+	    if (_nvram_read(nv_buf, ptr,offset,2) != 2) {
-+		goto error;
-+	    }
-+	    reclen = (((unsigned int) *(ptr)) << 8) + (unsigned int) *(ptr+1);
-+	    size -= 2;
-+	    offset += 2;
-+	}
-+
-+	if (reclen > size)
-+	    break;	/* should not happen, bad NVRAM */
-+
-+	switch (rectype) {
-+	    case ENV_TLV_TYPE_ENV:
-+		/* Read the TLV data */
-+		if (_nvram_read(nv_buf, ptr,offset,reclen) != reclen)
-+		    goto error;
-+		flg = *ptr++;
-+		envval = (unsigned char *) _strnchr(ptr,'=',(reclen-1));
-+		if (envval) {
-+		    *envval++ = '\0';
-+		    memcpy(_valuestr,envval,(reclen-1)-(envval-ptr));
-+		    _valuestr[(reclen-1)-(envval-ptr)] = '\0';
-+#if 0			
-+		    printk(KERN_INFO "NVRAM:%s=%s\n", ptr, _valuestr);
-+#endif
-+		    if(!strcmp(ptr, name)){
-+			return _valuestr;
-+		    }
-+		    if((strlen(ptr) > 1) && !strcmp(&ptr[1], name))
-+			return _valuestr;
-+		}
-+		break;
-+		
-+	    default: 
-+		/* Unknown TLV type, skip it. */
-+		break;
-+	    }
-+
-+	/*
-+	 * Advance to next TLV 
-+	 */
-+		
-+	size -= (int)reclen;
-+	offset += reclen;
-+
-+	/* Read the next record type */
-+	ptr = buffer;
-+	if (_nvram_read(nv_buf, ptr,offset,1) != 1)
-+	    goto error;
-+	}
-+
-+error:
-+    return NULL;
-+
-+}
-+
-diff -ruN linux-2.6.25.10/arch/mips/bcm47xx/include/nvram.h linux-new/arch/mips/bcm47xx/include/nvram.h
---- linux-2.6.25.10/arch/mips/bcm47xx/include/nvram.h	1969-12-31 18:00:00.000000000 -0600
-+++ linux-new/arch/mips/bcm47xx/include/nvram.h	2009-01-09 21:45:52.000000000 -0600
-@@ -0,0 +1,37 @@
-+/*
-+ *  Copyright (C) 2006 Felix Fietkau <nbd@openwrt.org>
-+ *
-+ *  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.
-+ */
-+
-+#ifndef __NVRAM_H
-+#define __NVRAM_H
-+
-+struct nvram_header {
-+	u32 magic;
-+	u32 len;
-+	u32 crc_ver_init;	/* 0:7 crc, 8:15 ver, 16:31 sdram_init */
-+	u32 config_refresh;	/* 0:15 sdram_config, 16:31 sdram_refresh */
-+	u32 config_ncdl;	/* ncdl values for memc */
-+};
-+
-+struct nvram_tuple {
-+	char *name;
-+	char *value;
-+	struct nvram_tuple *next;
-+};
-+
-+#define NVRAM_HEADER		0x48534C46	/* 'FLSH' */
-+#define NVRAM_VERSION		1
-+#define NVRAM_HEADER_SIZE	20
-+#define NVRAM_SPACE		0x8000
-+
-+#define NVRAM_MAX_VALUE_LEN 255
-+#define NVRAM_MAX_PARAM_LEN 64
-+
-+char *nvram_get(const char *name);
-+
-+#endif
-diff -ruN linux-2.6.25.10/arch/mips/bcm47xx/irq.c linux-new/arch/mips/bcm47xx/irq.c
---- linux-2.6.25.10/arch/mips/bcm47xx/irq.c	2008-07-02 22:46:47.000000000 -0500
-+++ linux-new/arch/mips/bcm47xx/irq.c	2009-01-09 21:45:52.000000000 -0600
-@@ -1,5 +1,6 @@
- /*
-  *  Copyright (C) 2004 Florian Schirmer <jolt@tuxbox.org>
-+ *  Copyright (C) 2008 Michael Buesch <mb@bu3sch.de>
-  *
-  *  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
-@@ -23,10 +24,19 @@
-  */
- 
- #include <linux/types.h>
-+#include <linux/errno.h>
-+#include <linux/init.h>
- #include <linux/interrupt.h>
- #include <linux/irq.h>
-+#include <linux/pci.h>
-+#include <linux/ssb/ssb.h>
-+
- #include <asm/irq_cpu.h>
- 
-+
-+extern struct ssb_bus ssb_bcm47xx;
-+
-+
- void plat_irq_dispatch(void)
- {
- 	u32 cause;
-@@ -53,3 +63,19 @@
- {
- 	mips_cpu_irq_init();
- }
-+
-+int pcibios_map_irq(const struct pci_dev *dev, u8 slot, u8 pin)
-+{
-+	int res;
-+
-+	res = ssb_pcibios_map_irq(dev, slot, pin);
-+	if (res < 0) {
-+		printk(KERN_ALERT "PCI: Failed to map IRQ of device %s\n",
-+		       dev->dev.bus_id);
-+		return 0;
-+	}
-+	/* IRQ-0 and IRQ-1 are software interrupts. */
-+	WARN_ON((res == 0) || (res == 1));
-+
-+	return res;
-+}
-diff -ruN linux-2.6.25.10/arch/mips/bcm47xx/Makefile linux-new/arch/mips/bcm47xx/Makefile
---- linux-2.6.25.10/arch/mips/bcm47xx/Makefile	2008-07-02 22:46:47.000000000 -0500
-+++ linux-new/arch/mips/bcm47xx/Makefile	2009-01-09 21:45:52.000000000 -0600
-@@ -3,4 +3,4 @@
- # under Linux.
- #
- 
--obj-y := gpio.o irq.o prom.o serial.o setup.o time.o wgt634u.o
-+obj-y := cfe_env.o gpio.o irq.o nvram.o prom.o serial.o setup.o time.o wgt634u.o
-diff -ruN linux-2.6.25.10/arch/mips/bcm47xx/nvram.c linux-new/arch/mips/bcm47xx/nvram.c
---- linux-2.6.25.10/arch/mips/bcm47xx/nvram.c	1969-12-31 18:00:00.000000000 -0600
-+++ linux-new/arch/mips/bcm47xx/nvram.c	2009-01-09 21:45:52.000000000 -0600
-@@ -0,0 +1,125 @@
-+/*
-+ * BCM947xx nvram variable access
-+ *
-+ * Copyright 2005, Broadcom Corporation
-+ * Copyright 2006, Felix Fietkau <nbd@openwrt.org>
-+ * 
-+ * 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.
-+ */
-+
-+#include <linux/init.h>
-+#include <linux/module.h>
-+#include <linux/ssb/ssb.h>
-+#include <linux/kernel.h>
-+#include <linux/string.h>
-+#include <linux/interrupt.h>
-+#include <linux/spinlock.h>
-+#include <linux/slab.h>
-+#include <asm/byteorder.h>
-+#include <asm/bootinfo.h>
-+#include <asm/addrspace.h>
-+#include <asm/io.h>
-+#include <asm/uaccess.h>
-+
-+#include "include/nvram.h"
-+
-+#define MB * 1048576
-+extern struct ssb_bus ssb_bcm47xx;
-+
-+static char nvram_buf[NVRAM_SPACE];
-+static int cfe_env;
-+extern char *cfe_env_get(char *nv_buf, const char *name);
-+		
-+/* Probe for NVRAM header */
-+static void __init early_nvram_init(void)
-+{
-+	struct ssb_mipscore *mcore = &ssb_bcm47xx.mipscore;
-+	struct nvram_header *header;
-+	int i;
-+	u32 base, lim, off;
-+	u32 *src, *dst;
-+	
-+	base = mcore->flash_window;
-+	lim = mcore->flash_window_size;
-+	cfe_env = 0;
-+
-+	
-+	/* XXX: hack for supporting the CFE environment stuff on WGT634U */
-+	if (lim >= 8 MB) {
-+		src = (u32 *) KSEG1ADDR(base + 8 MB - 0x2000);
-+		dst = (u32 *) nvram_buf;
-+
-+		if ((*src & 0xff00ff) == 0x000001) {
-+			printk("early_nvram_init: WGT634U NVRAM found.\n");
-+
-+			for (i = 0; i < 0x1ff0; i++) {
-+				if (*src == 0xFFFFFFFF)
-+					break;
-+				*dst++ = *src++;
-+			}
-+			cfe_env = 1;
-+			return;
-+		}
-+	}
-+
-+	off = 0x20000;
-+	while (off <= lim) {
-+		/* Windowed flash access */
-+		header = (struct nvram_header *) KSEG1ADDR(base + off - NVRAM_SPACE);
-+		if (header->magic == NVRAM_HEADER)
-+			goto found;
-+		off <<= 1;
-+	}
-+
-+	/* Try embedded NVRAM at 4 KB and 1 KB as last resorts */
-+	header = (struct nvram_header *) KSEG1ADDR(base + 4096);
-+	if (header->magic == NVRAM_HEADER)
-+		goto found;
-+	
-+	header = (struct nvram_header *) KSEG1ADDR(base + 1024);
-+	if (header->magic == NVRAM_HEADER)
-+		goto found;
-+	
-+	return;
-+
-+found:
-+	src = (u32 *) header;
-+	dst = (u32 *) nvram_buf;
-+	for (i = 0; i < sizeof(struct nvram_header); i += 4)
-+		*dst++ = *src++;
-+	for (; i < header->len && i < NVRAM_SPACE; i += 4)
-+		*dst++ = le32_to_cpu(*src++);
-+}
-+
-+char *nvram_get(const char *name)
-+{
-+	char *var, *value, *end, *eq;
-+
-+	if (!name)
-+		return NULL;
-+
-+	if (!nvram_buf[0])
-+		early_nvram_init();
-+
-+	if (cfe_env)
-+		return cfe_env_get(nvram_buf, name);
-+
-+	/* Look for name=value and return value */
-+	var = &nvram_buf[sizeof(struct nvram_header)];
-+	end = nvram_buf + sizeof(nvram_buf) - 2;
-+	end[0] = end[1] = '\0';
-+	for (; *var; var = value + strlen(value) + 1) {
-+		if (!(eq = strchr(var, '=')))
-+			break;
-+		value = eq + 1;
-+		if ((eq - var) == strlen(name) && strncmp(var, name, (eq - var)) == 0)
-+			return value;
-+	}
-+
-+	return NULL;
-+}
-+
-+EXPORT_SYMBOL(nvram_get);
-diff -ruN linux-2.6.25.10/arch/mips/bcm47xx/setup.c linux-new/arch/mips/bcm47xx/setup.c
---- linux-2.6.25.10/arch/mips/bcm47xx/setup.c	2008-07-02 22:46:47.000000000 -0500
-+++ linux-new/arch/mips/bcm47xx/setup.c	2009-01-09 21:45:52.000000000 -0600
-@@ -2,7 +2,7 @@
-  *  Copyright (C) 2004 Florian Schirmer <jolt@tuxbox.org>
-  *  Copyright (C) 2005 Waldemar Brodkorb <wbx@openwrt.org>
-  *  Copyright (C) 2006 Felix Fietkau <nbd@openwrt.org>
-- *  Copyright (C) 2006 Michael Buesch <mb@bu3sch.de>
-+ *  Copyright (C) 2006-2008 Michael Buesch <mb@bu3sch.de>
-  *
-  *  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
-@@ -25,23 +25,52 @@
-  *  675 Mass Ave, Cambridge, MA 02139, USA.
-  */
- 
-+#include <linux/init.h>
- #include <linux/types.h>
--#include <linux/ssb/ssb.h>
-+#include <linux/tty.h>
-+#include <linux/serial.h>
-+#include <linux/serial_core.h>
-+#include <linux/serial_reg.h>
-+#include <linux/serial_8250.h>
- #include <asm/bootinfo.h>
--#include <asm/reboot.h>
- #include <asm/time.h>
--#include <bcm47xx.h>
-+#include <asm/reboot.h>
- #include <asm/fw/cfe/cfe_api.h>
-+#include <linux/pm.h>
-+#include <linux/ssb/ssb.h>
-+#include <linux/ssb/ssb_embedded.h>
-+
-+#include "include/nvram.h"
- 
- struct ssb_bus ssb_bcm47xx;
- EXPORT_SYMBOL(ssb_bcm47xx);
- 
-+extern void bcm47xx_pci_init(void);
-+
-+int pcibios_plat_dev_init(struct pci_dev *dev)
-+{
-+	int err;
-+
-+	err = ssb_pcibios_plat_dev_init(dev);
-+	if (err) {
-+		printk(KERN_ALERT "PCI: Failed to init device %s\n",
-+		       pci_name(dev));
-+	}
-+
-+	return err;
-+}
-+
- static void bcm47xx_machine_restart(char *command)
- {
- 	printk(KERN_ALERT "Please stand by while rebooting the system...\n");
- 	local_irq_disable();
-+	/* CFE has a reboot callback, but that does not work.
-+	 * Oopses with: Reserved instruction in kernel code.
-+	 */
-+
- 	/* Set the watchdog timer to reset immediately */
--	ssb_chipco_watchdog_timer_set(&ssb_bcm47xx.chipco, 1);
-+	if (ssb_watchdog_timer_set(&ssb_bcm47xx, 1))
-+		printk(KERN_EMERG "SSB watchdog-triggered reboot failed!\n");
- 	while (1)
- 		cpu_relax();
- }
-@@ -50,12 +79,13 @@
- {
- 	/* Disable interrupts and watchdog and spin forever */
- 	local_irq_disable();
--	ssb_chipco_watchdog_timer_set(&ssb_bcm47xx.chipco, 0);
-+	if (ssb_watchdog_timer_set(&ssb_bcm47xx, 0))
-+		printk(KERN_EMERG "Failed to disable SSB watchdog!\n");
- 	while (1)
- 		cpu_relax();
- }
- 
--static void str2eaddr(char *str, char *dest)
-+static void e_aton(char *str, char *dest)
- {
- 	int i = 0;
- 
-@@ -72,52 +102,141 @@
- 	}
- }
- 
--static int bcm47xx_get_invariants(struct ssb_bus *bus,
--				   struct ssb_init_invariants *iv)
-+static void bcm47xx_fill_sprom(struct ssb_sprom *sprom)
- {
--	char buf[100];
-+	char *s;
- 
--	/* Fill boardinfo structure */
--	memset(&(iv->boardinfo), 0 , sizeof(struct ssb_boardinfo));
-+	memset(sprom, 0xFF, sizeof(struct ssb_sprom));
- 
--	if (cfe_getenv("boardvendor", buf, sizeof(buf)) >= 0)
--		iv->boardinfo.type = (u16)simple_strtoul(buf, NULL, 0);
--	if (cfe_getenv("boardtype", buf, sizeof(buf)) >= 0)
--		iv->boardinfo.type = (u16)simple_strtoul(buf, NULL, 0);
--	if (cfe_getenv("boardrev", buf, sizeof(buf)) >= 0)
--		iv->boardinfo.rev = (u16)simple_strtoul(buf, NULL, 0);
--
--	/* Fill sprom structure */
--	memset(&(iv->sprom), 0, sizeof(struct ssb_sprom));
--	iv->sprom.revision = 3;
--
--	if (cfe_getenv("et0macaddr", buf, sizeof(buf)) >= 0)
--		str2eaddr(buf, iv->sprom.et0mac);
--	if (cfe_getenv("et1macaddr", buf, sizeof(buf)) >= 0)
--		str2eaddr(buf, iv->sprom.et1mac);
--	if (cfe_getenv("et0phyaddr", buf, sizeof(buf)) >= 0)
--		iv->sprom.et0phyaddr = simple_strtoul(buf, NULL, 10);
--	if (cfe_getenv("et1phyaddr", buf, sizeof(buf)) >= 0)
--		iv->sprom.et1phyaddr = simple_strtoul(buf, NULL, 10);
--	if (cfe_getenv("et0mdcport", buf, sizeof(buf)) >= 0)
--		iv->sprom.et0mdcport = simple_strtoul(buf, NULL, 10);
--	if (cfe_getenv("et1mdcport", buf, sizeof(buf)) >= 0)
--		iv->sprom.et1mdcport = simple_strtoul(buf, NULL, 10);
-+	sprom->revision = 1;
-+	if ((s = nvram_get("il0macaddr")))
-+		e_aton(s, sprom->il0mac);
-+	if ((s = nvram_get("et0macaddr")))
-+		e_aton(s, sprom->et0mac);
-+	if ((s = nvram_get("et1macaddr")))
-+		e_aton(s, sprom->et1mac);
-+	if ((s = nvram_get("et0phyaddr")))
-+		sprom->et0phyaddr = simple_strtoul(s, NULL, 0);
-+	if ((s = nvram_get("et1phyaddr")))
-+		sprom->et1phyaddr = simple_strtoul(s, NULL, 0);
-+	if ((s = nvram_get("et0mdcport")))
-+		sprom->et0mdcport = !!simple_strtoul(s, NULL, 10);
-+	if ((s = nvram_get("et1mdcport")))
-+		sprom->et1mdcport = !!simple_strtoul(s, NULL, 10);
-+	if ((s = nvram_get("pa0b0")))
-+		sprom->pa0b0 = simple_strtoul(s, NULL, 0);
-+	if ((s = nvram_get("pa0b1")))
-+		sprom->pa0b1 = simple_strtoul(s, NULL, 0);
-+	if ((s = nvram_get("pa0b2")))
-+		sprom->pa0b2 = simple_strtoul(s, NULL, 0);
-+	if ((s = nvram_get("pa1b0")))
-+		sprom->pa1b0 = simple_strtoul(s, NULL, 0);
-+	if ((s = nvram_get("pa1b1")))
-+		sprom->pa1b1 = simple_strtoul(s, NULL, 0);
-+	if ((s = nvram_get("pa1b2")))
-+		sprom->pa1b2 = simple_strtoul(s, NULL, 0);
-+	if ((s = nvram_get("wl0gpio0")))
-+		sprom->gpio0 = simple_strtoul(s, NULL, 0);
-+	if ((s = nvram_get("wl0gpio1")))
-+		sprom->gpio1 = simple_strtoul(s, NULL, 0);
-+	if ((s = nvram_get("wl0gpio2")))
-+		sprom->gpio2 = simple_strtoul(s, NULL, 0);
-+	if ((s = nvram_get("wl0gpio3")))
-+		sprom->gpio3 = simple_strtoul(s, NULL, 0);
-+	if ((s = nvram_get("pa0maxpwr")))
-+		sprom->maxpwr_bg = simple_strtoul(s, NULL, 0);
-+	if ((s = nvram_get("pa1maxpwr")))
-+		sprom->maxpwr_a = simple_strtoul(s, NULL, 0);
-+	if ((s = nvram_get("pa0itssit")))
-+		sprom->itssi_bg = simple_strtoul(s, NULL, 0);
-+	if ((s = nvram_get("pa1itssit")))
-+		sprom->itssi_a = simple_strtoul(s, NULL, 0);
-+	sprom->boardflags_lo = 0;
-+	if ((s = nvram_get("boardflags")))
-+		sprom->boardflags_lo = simple_strtoul(s, NULL, 0);
-+	sprom->boardflags_hi = 0;
-+	if ((s = nvram_get("boardflags2")))
-+		sprom->boardflags_hi = simple_strtoul(s, NULL, 0);
-+}
-+
-+static int bcm47xx_get_invariants(struct ssb_bus *bus, struct ssb_init_invariants *iv)
-+{
-+	char *s;
-+
-+	iv->boardinfo.vendor = SSB_BOARDVENDOR_BCM;
-+	if ((s = nvram_get("boardtype")))
-+		iv->boardinfo.type = (u16)simple_strtoul(s, NULL, 0);
-+	if ((s = nvram_get("boardrev")))
-+		iv->boardinfo.rev = (u16)simple_strtoul(s, NULL, 0);
-+
-+	bcm47xx_fill_sprom(&iv->sprom);
-+
-+	if ((s = nvram_get("cardbus")))
-+		iv->has_cardbus_slot = !!simple_strtoul(s, NULL, 10);
- 
- 	return 0;
- }
- 
- void __init plat_mem_setup(void)
- {
--	int err;
-+	int i, err;
-+	char *s;
-+	struct ssb_mipscore *mcore;
-+
-+	err = ssb_bus_ssbbus_register(&ssb_bcm47xx, SSB_ENUM_BASE, bcm47xx_get_invariants);
-+	if (err) {
-+		const char *msg = "Failed to initialize SSB bus (err %d)\n";
-+		printk(msg, err); /* Make sure the message gets out of the box. */
-+		panic(msg, err);
-+	}
-+	mcore = &ssb_bcm47xx.mipscore;
-+
-+	s = nvram_get("kernel_args");
-+	if (s && !strncmp(s, "console=ttyS1", 13)) {
-+		struct ssb_serial_port port;
-+
-+		printk("Swapping serial ports!\n");
-+		/* swap serial ports */
-+		memcpy(&port, &mcore->serial_ports[0], sizeof(port));
-+		memcpy(&mcore->serial_ports[0], &mcore->serial_ports[1], sizeof(port));
-+		memcpy(&mcore->serial_ports[1], &port, sizeof(port));
-+	}
- 
--	err = ssb_bus_ssbbus_register(&ssb_bcm47xx, SSB_ENUM_BASE,
--				      bcm47xx_get_invariants);
--	if (err)
--		panic("Failed to initialize SSB bus (err %d)\n", err);
-+	for (i = 0; i < mcore->nr_serial_ports; i++) {
-+		struct ssb_serial_port *port = &(mcore->serial_ports[i]);
-+		struct uart_port s;
-+
-+		memset(&s, 0, sizeof(s));
-+		s.line = i;
-+		s.membase = port->regs;
-+		s.irq = port->irq + 2;
-+		s.uartclk = port->baud_base;
-+		s.flags = UPF_BOOT_AUTOCONF | UPF_SHARE_IRQ;
-+		s.iotype = SERIAL_IO_MEM;
-+		s.regshift = port->reg_shift;
-+
-+		early_serial_setup(&s);
-+	}
-+	printk("Serial init done.\n");
- 
- 	_machine_restart = bcm47xx_machine_restart;
- 	_machine_halt = bcm47xx_machine_halt;
- 	pm_power_off = bcm47xx_machine_halt;
- }
- 
-+static int __init bcm47xx_register_gpiodev(void)
-+{
-+	static struct resource res = {
-+		.start = 0xFFFFFFFF,
-+	};
-+	struct platform_device *pdev;
-+
-+	pdev = platform_device_register_simple("GPIODEV", 0, &res, 1);
-+	if (!pdev) {
-+		printk(KERN_ERR "bcm47xx: GPIODEV init failed\n");
-+		return -ENODEV;
-+	}
-+
-+	return 0;
-+}
-+device_initcall(bcm47xx_register_gpiodev);
-diff -ruN linux-2.6.25.10/arch/mips/bcm47xx/time.c linux-new/arch/mips/bcm47xx/time.c
---- linux-2.6.25.10/arch/mips/bcm47xx/time.c	2008-07-02 22:46:47.000000000 -0500
-+++ linux-new/arch/mips/bcm47xx/time.c	2009-01-09 21:45:52.000000000 -0600
-@@ -22,11 +22,17 @@
-  *  675 Mass Ave, Cambridge, MA 02139, USA.
-  */
- 
--
- #include <linux/init.h>
-+#include <linux/kernel.h>
-+#include <linux/sched.h>
-+#include <linux/serial_reg.h>
-+#include <linux/interrupt.h>
- #include <linux/ssb/ssb.h>
-+#include <asm/addrspace.h>
-+#include <asm/io.h>
- #include <asm/time.h>
--#include <bcm47xx.h>
-+
-+extern struct ssb_bus ssb_bcm47xx;
- 
- void __init plat_time_init(void)
- {
-diff -ruN linux-2.6.25.10/drivers/mtd/maps/bcm47xx-flash.c linux-new/drivers/mtd/maps/bcm47xx-flash.c
---- linux-2.6.25.10/drivers/mtd/maps/bcm47xx-flash.c	1969-12-31 18:00:00.000000000 -0600
-+++ linux-new/drivers/mtd/maps/bcm47xx-flash.c	2009-01-09 21:45:52.000000000 -0600
-@@ -0,0 +1,439 @@
-+/*
-+ *  Copyright (C) 2006 Felix Fietkau <nbd@openwrt.org>
-+ *  Copyright (C) 2005 Waldemar Brodkorb <wbx@openwrt.org>
-+ *  Copyright (C) 2004 Florian Schirmer (jolt@tuxbox.org)
-+ *
-+ *  original functions for finding root filesystem from Mike Baker 
-+ *
-+ *  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  SOFTWARE  IS PROVIDED   ``AS  IS'' AND   ANY  EXPRESS OR IMPLIED
-+ *  WARRANTIES,   INCLUDING, BUT NOT  LIMITED  TO, THE IMPLIED WARRANTIES OF
-+ *  MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.  IN
-+ *  NO  EVENT  SHALL   THE AUTHOR  BE    LIABLE FOR ANY   DIRECT, INDIRECT,
-+ *  INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
-+ *  NOT LIMITED   TO, PROCUREMENT OF  SUBSTITUTE GOODS  OR SERVICES; LOSS OF
-+ *  USE, DATA,  OR PROFITS; OR  BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
-+ *  ANY THEORY OF LIABILITY, WHETHER IN  CONTRACT, STRICT LIABILITY, OR TORT
-+ *  (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
-+ *  THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-+ *
-+ *  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.,
-+ *  675 Mass Ave, Cambridge, MA 02139, USA.
-+ * 
-+ *  Copyright 2001-2003, 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.
-+ *
-+ *  Flash mapping for BCM947XX boards
-+ */
-+
-+#include <linux/init.h>
-+#include <linux/module.h>
-+#include <linux/types.h>
-+#include <linux/kernel.h>
-+#include <linux/sched.h>
-+#include <linux/wait.h>
-+#include <linux/mtd/mtd.h>
-+#include <linux/mtd/map.h>
-+#ifdef CONFIG_MTD_PARTITIONS
-+#include <linux/mtd/partitions.h>
-+#endif
-+#include <linux/crc32.h>
-+#ifdef CONFIG_SSB
-+#include <linux/ssb/ssb.h>
-+#endif
-+#include <asm/io.h>
-+
-+
-+#define TRX_MAGIC	0x30524448	/* "HDR0" */
-+#define TRX_VERSION	1
-+#define TRX_MAX_LEN	0x3A0000
-+#define TRX_NO_HEADER	1		/* Do not write TRX header */	
-+#define TRX_GZ_FILES	0x2     /* Contains up to TRX_MAX_OFFSET individual gzip files */
-+#define TRX_MAX_OFFSET	3
-+
-+struct trx_header {
-+	u32 magic;		/* "HDR0" */
-+	u32 len;		/* Length of file including header */
-+	u32 crc32;		/* 32-bit CRC from flag_version to end of file */
-+	u32 flag_version;	/* 0:15 flags, 16:31 version */
-+	u32 offsets[TRX_MAX_OFFSET];	/* Offsets of partitions from start of header */
-+};
-+
-+#define ROUNDUP(x, y) ((((x)+((y)-1))/(y))*(y))
-+#define NVRAM_SPACE 0x8000
-+#define WINDOW_ADDR 0x1fc00000
-+#define WINDOW_SIZE 0x400000
-+#define BUSWIDTH 2
-+
-+#ifdef CONFIG_SSB
-+extern struct ssb_bus ssb_bcm47xx;
-+#endif
-+static struct mtd_info *bcm47xx_mtd;
-+
-+static void bcm47xx_map_copy_from(struct map_info *map, void *to, unsigned long from, ssize_t len)
-+{
-+	if (len==1) {
-+		memcpy_fromio(to, map->virt + from, len);
-+	} else {
-+		int i;
-+		u16 *dest = (u16 *) to;
-+		u16 *src  = (u16 *) (map->virt + from);
-+		for (i = 0; i < (len / 2); i++) {
-+			dest[i] = src[i];
-+		}
-+		if (len & 1)
-+			*((u8 *)dest+len-1) = src[i] & 0xff;
-+	}
-+}
-+
-+static struct map_info bcm47xx_map = {
-+	name: "Physically mapped flash",
-+	size: WINDOW_SIZE,
-+	bankwidth: BUSWIDTH,
-+	phys: WINDOW_ADDR,
-+};
-+
-+#ifdef CONFIG_MTD_PARTITIONS
-+
-+static struct mtd_partition bcm47xx_parts[] = {
-+	{ name: "cfe",	offset: 0, size: 0, mask_flags: MTD_WRITEABLE, },
-+	{ name: "linux", offset: 0, size: 0, },
-+	{ name: "rootfs", offset: 0, size: 0, },
-+	{ name: "nvram", offset: 0, size: 0, },
-+	{ name: NULL, },
-+};
-+
-+static int __init
-+find_cfe_size(struct mtd_info *mtd, size_t size)
-+{
-+	struct trx_header *trx;
-+	unsigned char buf[512];
-+	int off;
-+	size_t len;
-+	int blocksize;
-+
-+	trx = (struct trx_header *) buf;
-+
-+	blocksize = mtd->erasesize;
-+	if (blocksize < 0x10000)
-+		blocksize = 0x10000;
-+
-+	for (off = (128*1024); off < size; off += blocksize) {
-+		memset(buf, 0xe5, sizeof(buf));
-+
-+		/*
-+		 * Read into buffer 
-+		 */
-+		if (mtd->read(mtd, off, sizeof(buf), &len, buf) ||
-+		    len != sizeof(buf))
-+			continue;
-+
-+		/* found a TRX header */
-+		if (le32_to_cpu(trx->magic) == TRX_MAGIC) {
-+			goto found;
-+		}
-+	}
-+
-+	printk(KERN_NOTICE
-+	       "%s: Couldn't find bootloader size\n",
-+	       mtd->name);
-+	return -1;
-+
-+ found:
-+	printk(KERN_NOTICE "bootloader size: %d\n", off);
-+	return off;
-+
-+}
-+
-+/*
-+ * Copied from mtdblock.c
-+ *
-+ * Cache stuff...
-+ * 
-+ * Since typical flash erasable sectors are much larger than what Linux's
-+ * buffer cache can handle, we must implement read-modify-write on flash
-+ * sectors for each block write requests.  To avoid over-erasing flash sectors
-+ * and to speed things up, we locally cache a whole flash sector while it is
-+ * being written to until a different sector is required.
-+ */
-+
-+static void erase_callback(struct erase_info *done)
-+{
-+	wait_queue_head_t *wait_q = (wait_queue_head_t *)done->priv;
-+	wake_up(wait_q);
-+}
-+
-+static int erase_write (struct mtd_info *mtd, unsigned long pos, 
-+			int len, const char *buf)
-+{
-+	struct erase_info erase;
-+	DECLARE_WAITQUEUE(wait, current);
-+	wait_queue_head_t wait_q;
-+	size_t retlen;
-+	int ret;
-+
-+	/*
-+	 * First, let's erase the flash block.
-+	 */
-+
-+	init_waitqueue_head(&wait_q);
-+	erase.mtd = mtd;
-+	erase.callback = erase_callback;
-+	erase.addr = pos;
-+	erase.len = len;
-+	erase.priv = (u_long)&wait_q;
-+
-+	set_current_state(TASK_INTERRUPTIBLE);
-+	add_wait_queue(&wait_q, &wait);
-+
-+	ret = mtd->erase(mtd, &erase);
-+	if (ret) {
-+		set_current_state(TASK_RUNNING);
-+		remove_wait_queue(&wait_q, &wait);
-+		printk (KERN_WARNING "erase of region [0x%lx, 0x%x] "
-+				     "on \"%s\" failed\n",
-+			pos, len, mtd->name);
-+		return ret;
-+	}
-+
-+	schedule();  /* Wait for erase to finish. */
-+	remove_wait_queue(&wait_q, &wait);
-+
-+	/*
-+	 * Next, writhe data to flash.
-+	 */
-+
-+	ret = mtd->write (mtd, pos, len, &retlen, buf);
-+	if (ret)
-+		return ret;
-+	if (retlen != len)
-+		return -EIO;
-+	return 0;
-+}
-+
-+
-+
-+
-+static int __init
-+find_root(struct mtd_info *mtd, size_t size, struct mtd_partition *part)
-+{
-+	struct trx_header trx, *trx2;
-+	unsigned char buf[512], *block;
-+	int off, blocksize;
-+	u32 i, crc = ~0;
-+	size_t len;
-+	struct squashfs_super_block *sb = (struct squashfs_super_block *) buf;
-+
-+	blocksize = mtd->erasesize;
-+	if (blocksize < 0x10000)
-+		blocksize = 0x10000;
-+
-+	for (off = (128*1024); off < size; off += blocksize) {
-+		memset(&trx, 0xe5, sizeof(trx));
-+
-+		/*
-+		 * Read into buffer 
-+		 */
-+		if (mtd->read(mtd, off, sizeof(trx), &len, (char *) &trx) ||
-+		    len != sizeof(trx))
-+			continue;
-+
-+		/* found a TRX header */
-+		if (le32_to_cpu(trx.magic) == TRX_MAGIC) {
-+			part->offset = le32_to_cpu(trx.offsets[2]) ? : 
-+				le32_to_cpu(trx.offsets[1]);
-+			part->size = le32_to_cpu(trx.len); 
-+
-+			part->size -= part->offset;
-+			part->offset += off;
-+
-+			goto found;
-+		}
-+	}
-+
-+	printk(KERN_NOTICE
-+	       "%s: Couldn't find root filesystem\n",
-+	       mtd->name);
-+	return -1;
-+
-+ found:
-+	if (part->size == 0)
-+		return 0;
-+	
-+	if (mtd->read(mtd, part->offset, sizeof(buf), &len, buf) || len != sizeof(buf))
-+		return 0;
-+
-+	/* Move the fs outside of the trx */
-+	part->size = 0;
-+
-+	if (trx.len != part->offset + part->size - off) {
-+		/* Update the trx offsets and length */
-+		trx.len = part->offset + part->size - off;
-+	
-+		/* Update the trx crc32 */
-+		for (i = (u32) &(((struct trx_header *)NULL)->flag_version); i <= trx.len; i += sizeof(buf)) {
-+			if (mtd->read(mtd, off + i, sizeof(buf), &len, buf) || len != sizeof(buf))
-+				return 0;
-+			crc = crc32_le(crc, buf, min(sizeof(buf), trx.len - i));
-+		}
-+		trx.crc32 = crc;
-+
-+		/* read first eraseblock from the trx */
-+		block = kmalloc(mtd->erasesize, GFP_KERNEL);
-+		trx2 = (struct trx_header *) block;
-+		if (mtd->read(mtd, off, mtd->erasesize, &len, block) || len != mtd->erasesize) {
-+			printk("Error accessing the first trx eraseblock\n");
-+			return 0;
-+		}
-+		
-+		printk("Updating TRX offsets and length:\n");
-+		printk("old trx = [0x%08x, 0x%08x, 0x%08x], len=0x%08x crc32=0x%08x\n", trx2->offsets[0], trx2->offsets[1], trx2->offsets[2], trx2->len, trx2->crc32);
-+		printk("new trx = [0x%08x, 0x%08x, 0x%08x], len=0x%08x crc32=0x%08x\n",   trx.offsets[0],   trx.offsets[1],   trx.offsets[2],   trx.len, trx.crc32);
-+
-+		/* Write updated trx header to the flash */
-+		memcpy(block, &trx, sizeof(trx));
-+		if (mtd->unlock)
-+			mtd->unlock(mtd, off, mtd->erasesize);
-+		erase_write(mtd, off, mtd->erasesize, block);
-+		if (mtd->sync)
-+			mtd->sync(mtd);
-+		kfree(block);
-+		printk("Done\n");
-+	}
-+	
-+	return part->size;
-+}
-+
-+struct mtd_partition * __init
-+init_mtd_partitions(struct mtd_info *mtd, size_t size)
-+{
-+	int cfe_size;
-+
-+	if ((cfe_size = find_cfe_size(mtd,size)) < 0)
-+		return NULL;
-+
-+	/* boot loader */
-+	bcm47xx_parts[0].offset = 0;
-+	bcm47xx_parts[0].size   = cfe_size;
-+
-+	/* nvram */
-+	if (cfe_size != 384 * 1024) {
-+		bcm47xx_parts[3].offset = size - ROUNDUP(NVRAM_SPACE, mtd->erasesize);
-+		bcm47xx_parts[3].size   = ROUNDUP(NVRAM_SPACE, mtd->erasesize);
-+	} else {
-+		/* nvram (old 128kb config partition on netgear wgt634u) */
-+		bcm47xx_parts[3].offset = bcm47xx_parts[0].size;
-+		bcm47xx_parts[3].size   = ROUNDUP(NVRAM_SPACE, mtd->erasesize);
-+	}
-+
-+	/* linux (kernel and rootfs) */
-+	if (cfe_size != 384 * 1024) {
-+		bcm47xx_parts[1].offset = bcm47xx_parts[0].size;
-+		bcm47xx_parts[1].size   = bcm47xx_parts[3].offset - 
-+			bcm47xx_parts[1].offset;
-+	} else {
-+		/* do not count the elf loader, which is on one block */
-+		bcm47xx_parts[1].offset = bcm47xx_parts[0].size + 
-+			bcm47xx_parts[3].size + mtd->erasesize;
-+		bcm47xx_parts[1].size   = size - 
-+			bcm47xx_parts[0].size - 
-+			(2*bcm47xx_parts[3].size) - 
-+			mtd->erasesize;
-+	}
-+
-+	/* find and size rootfs */
-+	find_root(mtd,size,&bcm47xx_parts[2]);
-+	bcm47xx_parts[2].size = size - bcm47xx_parts[2].offset - bcm47xx_parts[3].size;
-+
-+	return bcm47xx_parts;
-+}
-+#endif
-+
-+int __init init_bcm47xx_map(void)
-+{
-+#ifdef CONFIG_SSB
-+	struct ssb_mipscore *mcore = &ssb_bcm47xx.mipscore;
-+#endif
-+	size_t size;
-+	int ret = 0;
-+#ifdef CONFIG_MTD_PARTITIONS
-+	struct mtd_partition *parts;
-+	int i;
-+#endif
-+
-+#ifdef CONFIG_SSB
-+	u32 window = mcore->flash_window;
-+	u32 window_size = mcore->flash_window_size;
-+
-+	printk("flash init: 0x%08x 0x%08x\n", window, window_size);
-+	bcm47xx_map.phys = window;
-+	bcm47xx_map.size = window_size;
-+	bcm47xx_map.virt = ioremap_nocache(window, window_size);
-+#else
-+	printk("flash init: 0x%08x 0x%08x\n", WINDOW_ADDR, WINDOW_SIZE);
-+	bcm47xx_map.virt = ioremap_nocache(WINDOW_ADDR, WINDOW_SIZE);
-+#endif
-+
-+	if (!bcm47xx_map.virt) {
-+		printk("Failed to ioremap\n");
-+		return -EIO;
-+	}
-+
-+	simple_map_init(&bcm47xx_map);
-+	
-+	if (!(bcm47xx_mtd = do_map_probe("cfi_probe", &bcm47xx_map))) {
-+		printk("Failed to do_map_probe\n");
-+		iounmap((void *)bcm47xx_map.virt);
-+		return -ENXIO;
-+	}
-+
-+	/* override copy_from routine */
-+ 	/* bcm47xx_map.copy_from = bcm47xx_map_copy_from; */
-+
-+	bcm47xx_mtd->owner = THIS_MODULE;
-+
-+	size = bcm47xx_mtd->size;
-+
-+	printk(KERN_NOTICE "Flash device: 0x%x at 0x%x\n", size, WINDOW_ADDR);
-+
-+#ifdef CONFIG_MTD_PARTITIONS
-+	parts = init_mtd_partitions(bcm47xx_mtd, size);
-+	for (i = 0; parts[i].name; i++);
-+	ret = add_mtd_partitions(bcm47xx_mtd, parts, i);
-+	if (ret) {
-+		printk(KERN_ERR "Flash: add_mtd_partitions failed\n");
-+		goto fail;
-+	}
-+#endif
-+	return 0;
-+
-+ fail:
-+	if (bcm47xx_mtd)
-+		map_destroy(bcm47xx_mtd);
-+	if (bcm47xx_map.virt)
-+		iounmap((void *)bcm47xx_map.virt);
-+	bcm47xx_map.virt = 0;
-+	return ret;
-+}
-+
-+void __exit cleanup_bcm47xx_map(void)
-+{
-+#ifdef CONFIG_MTD_PARTITIONS
-+	del_mtd_partitions(bcm47xx_mtd);
-+#endif
-+	map_destroy(bcm47xx_mtd);
-+	iounmap((void *)bcm47xx_map.virt);
-+}
-+
-+module_init(init_bcm47xx_map);
-+module_exit(cleanup_bcm47xx_map);
-diff -ruN linux-2.6.25.10/drivers/mtd/maps/Kconfig linux-new/drivers/mtd/maps/Kconfig
---- linux-2.6.25.10/drivers/mtd/maps/Kconfig	2008-07-02 22:46:47.000000000 -0500
-+++ linux-new/drivers/mtd/maps/Kconfig	2009-01-09 21:45:52.000000000 -0600
-@@ -337,6 +337,12 @@
- 	  Mapping for the Flaga digital module. If you don't have one, ignore
- 	  this setting.
- 
-+config MTD_BCM47XX
-+	tristate "BCM947xx flash device"
-+	depends on MIPS && MTD_CFI && BCM47XX
-+	help
-+	  Support for the flash chips on the BCM947xx board.
-+
- config MTD_WALNUT
- 	tristate "Flash device mapped on IBM 405GP Walnut"
- 	depends on MTD_JEDECPROBE && WALNUT && !PPC_MERGE
-diff -ruN linux-2.6.25.10/drivers/mtd/maps/Makefile linux-new/drivers/mtd/maps/Makefile
---- linux-2.6.25.10/drivers/mtd/maps/Makefile	2008-07-02 22:46:47.000000000 -0500
-+++ linux-new/drivers/mtd/maps/Makefile	2009-01-09 21:45:52.000000000 -0600
-@@ -31,6 +31,7 @@
- obj-$(CONFIG_MTD_PCMCIA)	+= pcmciamtd.o
- obj-$(CONFIG_MTD_RPXLITE)	+= rpxlite.o
- obj-$(CONFIG_MTD_TQM8XXL)	+= tqm8xxl.o
-+obj-$(CONFIG_MTD_BCM47XX)	+= bcm47xx-flash.o
- obj-$(CONFIG_MTD_SA1100)	+= sa1100-flash.o
- obj-$(CONFIG_MTD_IPAQ)		+= ipaq-flash.o
- obj-$(CONFIG_MTD_SBC_GXX)	+= sbc_gxx.o
-diff -ruN linux-2.6.25.10/drivers/net/tg3.c linux-new/drivers/net/tg3.c
---- linux-2.6.25.10/drivers/net/tg3.c	2008-07-02 22:46:47.000000000 -0500
-+++ linux-new/drivers/net/tg3.c	2009-01-09 21:45:52.000000000 -0600
-@@ -38,6 +38,7 @@
- #include <linux/workqueue.h>
- #include <linux/prefetch.h>
- #include <linux/dma-mapping.h>
-+#include <linux/ssb/ssb_driver_gige.h>
- 
- #include <net/checksum.h>
- #include <net/ip.h>
-@@ -425,8 +426,9 @@
- static inline void tw32_mailbox_flush(struct tg3 *tp, u32 off, u32 val)
- {
- 	tp->write32_mbox(tp, off, val);
--	if (!(tp->tg3_flags & TG3_FLAG_MBOX_WRITE_REORDER) &&
--	    !(tp->tg3_flags2 & TG3_FLG2_ICH_WORKAROUND))
-+	if ((tp->tg3_flags3 & TG3_FLG3_FLUSH_POSTED_WRITES) ||
-+	    (!(tp->tg3_flags & TG3_FLAG_MBOX_WRITE_REORDER) &&
-+	     !(tp->tg3_flags2 & TG3_FLG2_ICH_WORKAROUND)))
- 		tp->read32_mbox(tp, off);
- }
- 
-@@ -706,7 +708,7 @@
- 
- #define PHY_BUSY_LOOPS	5000
- 
--static int tg3_readphy(struct tg3 *tp, int reg, u32 *val)
-+static int __tg3_readphy(struct tg3 *tp, unsigned int phy_addr, int reg, u32 *val)
- {
- 	u32 frame_val;
- 	unsigned int loops;
-@@ -720,7 +722,7 @@
- 
- 	*val = 0x0;
- 
--	frame_val  = ((PHY_ADDR << MI_COM_PHY_ADDR_SHIFT) &
-+	frame_val  = ((phy_addr << MI_COM_PHY_ADDR_SHIFT) &
- 		      MI_COM_PHY_ADDR_MASK);
- 	frame_val |= ((reg << MI_COM_REG_ADDR_SHIFT) &
- 		      MI_COM_REG_ADDR_MASK);
-@@ -755,7 +757,12 @@
- 	return ret;
- }
- 
--static int tg3_writephy(struct tg3 *tp, int reg, u32 val)
-+static int tg3_readphy(struct tg3 *tp, int reg, u32 *val)
-+{
-+	return __tg3_readphy(tp, PHY_ADDR, reg, val);
-+}
-+
-+static int __tg3_writephy(struct tg3 *tp, unsigned int phy_addr, int reg, u32 val)
- {
- 	u32 frame_val;
- 	unsigned int loops;
-@@ -771,7 +778,7 @@
- 		udelay(80);
- 	}
- 
--	frame_val  = ((PHY_ADDR << MI_COM_PHY_ADDR_SHIFT) &
-+	frame_val  = ((phy_addr << MI_COM_PHY_ADDR_SHIFT) &
- 		      MI_COM_PHY_ADDR_MASK);
- 	frame_val |= ((reg << MI_COM_REG_ADDR_SHIFT) &
- 		      MI_COM_REG_ADDR_MASK);
-@@ -804,6 +811,11 @@
- 	return ret;
- }
- 
-+static int tg3_writephy(struct tg3 *tp, int reg, u32 val)
-+{
-+	return __tg3_writephy(tp, PHY_ADDR, reg, val);
-+}
-+
- static void tg3_phydsp_write(struct tg3 *tp, u32 reg, u32 val)
- {
- 	tg3_writephy(tp, MII_TG3_DSP_ADDRESS, reg);
-@@ -2250,6 +2262,14 @@
- 			}
- 		}
- 
-+		if (tp->tg3_flags & TG3_FLG3_ROBOSWITCH) {
-+			current_link_up = 1;
-+			current_speed = SPEED_1000; //FIXME
-+			current_duplex = DUPLEX_FULL;
-+			tp->link_config.active_speed = current_speed;
-+			tp->link_config.active_duplex = current_duplex;
-+		}
-+
- 		if (current_link_up == 1 &&
- 		    tp->link_config.active_duplex == DUPLEX_FULL)
- 			tg3_setup_flow_control(tp, lcl_adv, rmt_adv);
-@@ -5197,6 +5217,11 @@
- 	int i;
- 	u32 val;
- 
-+	if (tp->tg3_flags3 & TG3_FLG3_IS_SSB_CORE) {
-+		/* We don't use firmware. */
-+		return 0;
-+	}
-+
- 	if (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5906) {
- 		/* Wait up to 20ms for init done. */
- 		for (i = 0; i < 200; i++) {
-@@ -5435,6 +5460,14 @@
- 		tw32(0x5000, 0x400);
- 	}
- 
-+	if (tp->tg3_flags3 & TG3_FLG3_IS_SSB_CORE) {
-+		/* BCM4785: In order to avoid repercussions from using potentially
-+		 * defective internal ROM, stop the Rx RISC CPU, which is not
-+		 * required. */
-+		tg3_stop_fw(tp);
-+		tg3_halt_cpu(tp, RX_CPU_BASE);
-+	}
-+
- 	tw32(GRC_MODE, tp->grc_mode);
- 
- 	if (tp->pci_chip_rev_id == CHIPREV_ID_5705_A0) {
-@@ -5704,9 +5737,12 @@
- 		return -ENODEV;
- 	}
- 
--	/* Clear firmware's nvram arbitration. */
--	if (tp->tg3_flags & TG3_FLAG_NVRAM)
--		tw32(NVRAM_SWARB, SWARB_REQ_CLR0);
-+	if (!(tp->tg3_flags3 & TG3_FLG3_IS_SSB_CORE)) {
-+		/* Clear firmware's nvram arbitration. */
-+		if (tp->tg3_flags & TG3_FLAG_NVRAM)
-+			tw32(NVRAM_SWARB, SWARB_REQ_CLR0);
-+	}
-+
- 	return 0;
- }
- 
-@@ -5787,6 +5823,11 @@
- 	struct fw_info info;
- 	int err, i;
- 
-+	if (tp->tg3_flags3 & TG3_FLG3_IS_SSB_CORE) {
-+		/* We don't use firmware. */
-+		return 0;
-+	}
-+
- 	info.text_base = TG3_FW_TEXT_ADDR;
- 	info.text_len = TG3_FW_TEXT_LEN;
- 	info.text_data = &tg3FwText[0];
-@@ -6345,6 +6386,11 @@
- 	unsigned long cpu_base, cpu_scratch_base, cpu_scratch_size;
- 	int err, i;
- 
-+	if (tp->tg3_flags3 & TG3_FLG3_IS_SSB_CORE) {
-+		/* We don't use firmware. */
-+		return 0;
-+	}
-+
- 	if (tp->tg3_flags2 & TG3_FLG2_HW_TSO)
- 		return 0;
- 
-@@ -7306,6 +7352,11 @@
- 
- 	spin_lock(&tp->lock);
- 
-+	if (tp->tg3_flags3 & TG3_FLG3_FLUSH_POSTED_WRITES) {
-+		/* BCM4785: Flush posted writes from GbE to host memory. */
-+		tr32(HOSTCC_MODE);
-+	}
-+
- 	if (!(tp->tg3_flags & TG3_FLAG_TAGGED_STATUS)) {
- 		/* All of this garbage is because when using non-tagged
- 		 * IRQ status the mailbox/status_block protocol the chip
-@@ -8906,6 +8957,11 @@
- 	__le32 *buf;
- 	int i, j, k, err = 0, size;
- 
-+	if (tp->tg3_flags3 & TG3_FLG3_IS_SSB_CORE) {
-+		/* We don't have NVRAM. */
-+		return 0;
-+	}
-+
- 	if (tg3_nvram_read_swab(tp, 0, &magic) != 0)
- 		return -EIO;
- 
-@@ -9689,7 +9745,7 @@
- 			return -EAGAIN;
- 
- 		spin_lock_bh(&tp->lock);
--		err = tg3_readphy(tp, data->reg_num & 0x1f, &mii_regval);
-+		err = __tg3_readphy(tp, data->phy_id & 0x1f, data->reg_num & 0x1f, &mii_regval);
- 		spin_unlock_bh(&tp->lock);
- 
- 		data->val_out = mii_regval;
-@@ -9708,7 +9764,7 @@
- 			return -EAGAIN;
- 
- 		spin_lock_bh(&tp->lock);
--		err = tg3_writephy(tp, data->reg_num & 0x1f, data->val_in);
-+		err = __tg3_writephy(tp, data->phy_id & 0x1f, data->reg_num & 0x1f, data->val_in);
- 		spin_unlock_bh(&tp->lock);
- 
- 		return err;
-@@ -10177,6 +10233,12 @@
- /* Chips other than 5700/5701 use the NVRAM for fetching info. */
- static void __devinit tg3_nvram_init(struct tg3 *tp)
- {
-+	if (tp->tg3_flags3 & TG3_FLG3_IS_SSB_CORE) {
-+		/* No NVRAM and EEPROM on the SSB Broadcom GigE core. */
-+		tp->tg3_flags &= ~(TG3_FLAG_NVRAM | TG3_FLAG_NVRAM_BUFFERED);
-+		return;
-+	}
-+
- 	tw32_f(GRC_EEPROM_ADDR,
- 	     (EEPROM_ADDR_FSM_RESET |
- 	      (EEPROM_DEFAULT_CLOCK_PERIOD <<
-@@ -10317,6 +10379,9 @@
- {
- 	int ret;
- 
-+	if (tp->tg3_flags3 & TG3_FLG3_IS_SSB_CORE)
-+		return -ENODEV;
-+
- 	if (!(tp->tg3_flags & TG3_FLAG_NVRAM))
- 		return tg3_nvram_read_using_eeprom(tp, offset, val);
- 
-@@ -10563,6 +10628,9 @@
- {
- 	int ret;
- 
-+	if (tp->tg3_flags3 & TG3_FLG3_IS_SSB_CORE)
-+		return -ENODEV;
-+
- 	if (tp->tg3_flags & TG3_FLAG_EEPROM_WRITE_PROT) {
- 		tw32_f(GRC_LOCAL_CTRL, tp->grc_local_ctrl &
- 		       ~GRC_LCLCTRL_GPIO_OUTPUT1);
-@@ -11610,7 +11678,6 @@
- 		tp->write32 = tg3_write_flush_reg32;
- 	}
- 
--
- 	if ((tp->tg3_flags & TG3_FLAG_TXD_MBOX_HWBUG) ||
- 	    (tp->tg3_flags & TG3_FLAG_MBOX_WRITE_REORDER)) {
- 		tp->write32_tx_mbox = tg3_write32_tx_mbox;
-@@ -11646,6 +11713,11 @@
- 	      GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5701)))
- 		tp->tg3_flags |= TG3_FLAG_SRAM_USE_CONFIG;
- 
-+	if (tp->tg3_flags3 & TG3_FLG3_FLUSH_POSTED_WRITES) {
-+		tp->write32_tx_mbox = tg3_write_flush_reg32;
-+		tp->write32_rx_mbox = tg3_write_flush_reg32;
-+	}
-+
- 	/* Get eeprom hw config before calling tg3_set_power_state().
- 	 * In particular, the TG3_FLG2_IS_NIC flag must be
- 	 * determined before calling tg3_set_power_state() so that
-@@ -12017,6 +12089,10 @@
- 	}
- 
- 	if (!is_valid_ether_addr(&dev->dev_addr[0])) {
-+		if (tp->tg3_flags3 & TG3_FLG3_IS_SSB_CORE)
-+			ssb_gige_get_macaddr(tp->pdev, &dev->dev_addr[0]);
-+	}
-+	if (!is_valid_ether_addr(&dev->dev_addr[0])) {
- #ifdef CONFIG_SPARC
- 		if (!tg3_get_default_macaddr_sparc(tp))
- 			return 0;
-@@ -12508,6 +12584,7 @@
- 	case PHY_ID_BCM5704:	return "5704";
- 	case PHY_ID_BCM5705:	return "5705";
- 	case PHY_ID_BCM5750:	return "5750";
-+	case PHY_ID_BCM5750_2:	return "5750-2";
- 	case PHY_ID_BCM5752:	return "5752";
- 	case PHY_ID_BCM5714:	return "5714";
- 	case PHY_ID_BCM5780:	return "5780";
-@@ -12695,6 +12772,13 @@
- 		tp->msg_enable = tg3_debug;
- 	else
- 		tp->msg_enable = TG3_DEF_MSG_ENABLE;
-+	if (pdev_is_ssb_gige_core(pdev)) {
-+		tp->tg3_flags3 |= TG3_FLG3_IS_SSB_CORE;
-+		if (ssb_gige_must_flush_posted_writes(pdev))
-+			tp->tg3_flags3 |= TG3_FLG3_FLUSH_POSTED_WRITES;
-+		if (ssb_gige_have_roboswitch(pdev))
-+			tp->tg3_flags3 |= TG3_FLG3_ROBOSWITCH;
-+	}
- 
- 	/* The word/byte swap controls here control register access byte
- 	 * swapping.  DMA data byte swapping is controlled in the GRC_MODE
-diff -ruN linux-2.6.25.10/drivers/net/tg3.h linux-new/drivers/net/tg3.h
---- linux-2.6.25.10/drivers/net/tg3.h	2008-07-02 22:46:47.000000000 -0500
-+++ linux-new/drivers/net/tg3.h	2009-01-09 21:45:52.000000000 -0600
-@@ -2477,6 +2477,9 @@
- #define TG3_FLG3_ENABLE_APE		0x00000002
- #define TG3_FLG3_5761_5784_AX_FIXES	0x00000004
- #define TG3_FLG3_5701_DMA_BUG		0x00000008
-+#define TG3_FLG3_IS_SSB_CORE		0x00000010
-+#define TG3_FLG3_FLUSH_POSTED_WRITES	0x00000020
-+#define TG3_FLG3_ROBOSWITCH		0x00000040
- 
- 	struct timer_list		timer;
- 	u16				timer_counter;
-@@ -2532,6 +2535,7 @@
- #define PHY_ID_BCM5714			0x60008340
- #define PHY_ID_BCM5780			0x60008350
- #define PHY_ID_BCM5755			0xbc050cc0
-+#define PHY_ID_BCM5750_2		0xbc050cd0
- #define PHY_ID_BCM5787			0xbc050ce0
- #define PHY_ID_BCM5756			0xbc050ed0
- #define PHY_ID_BCM5784			0xbc050fa0
-@@ -2568,7 +2572,7 @@
- 	 (X) == PHY_ID_BCM5780 || (X) == PHY_ID_BCM5787 || \
- 	 (X) == PHY_ID_BCM5755 || (X) == PHY_ID_BCM5756 || \
- 	 (X) == PHY_ID_BCM5906 || (X) == PHY_ID_BCM5761 || \
--	 (X) == PHY_ID_BCM8002)
-+	 (X) == PHY_ID_BCM8002 || (X) == PHY_ID_BCM5750_2)
- 
- 	struct tg3_hw_stats		*hw_stats;
- 	dma_addr_t			stats_mapping;
-diff -ruN linux-2.6.25.10/drivers/ssb/driver_gige.c linux-new/drivers/ssb/driver_gige.c
---- linux-2.6.25.10/drivers/ssb/driver_gige.c	1969-12-31 18:00:00.000000000 -0600
-+++ linux-new/drivers/ssb/driver_gige.c	2009-01-09 21:45:52.000000000 -0600
-@@ -0,0 +1,294 @@
-+/*
-+ * Sonics Silicon Backplane
-+ * Broadcom Gigabit Ethernet core driver
-+ *
-+ * Copyright 2008, Broadcom Corporation
-+ * Copyright 2008, Michael Buesch <mb@bu3sch.de>
-+ *
-+ * Licensed under the GNU/GPL. See COPYING for details.
-+ */
-+
-+#include <linux/ssb/ssb.h>
-+#include <linux/ssb/ssb_driver_gige.h>
-+#include <linux/pci.h>
-+#include <linux/pci_regs.h>
-+
-+
-+/*
-+MODULE_DESCRIPTION("SSB Broadcom Gigabit Ethernet driver");
-+MODULE_AUTHOR("Michael Buesch");
-+MODULE_LICENSE("GPL");
-+*/
-+
-+static const struct ssb_device_id ssb_gige_tbl[] = {
-+	SSB_DEVICE(SSB_VENDOR_BROADCOM, SSB_DEV_ETHERNET_GBIT, SSB_ANY_REV),
-+	SSB_DEVTABLE_END
-+};
-+/* MODULE_DEVICE_TABLE(ssb, ssb_gige_tbl); */
-+
-+
-+static inline u8 gige_read8(struct ssb_gige *dev, u16 offset)
-+{
-+	return ssb_read8(dev->dev, offset);
-+}
-+
-+static inline u16 gige_read16(struct ssb_gige *dev, u16 offset)
-+{
-+	return ssb_read16(dev->dev, offset);
-+}
-+
-+static inline u32 gige_read32(struct ssb_gige *dev, u16 offset)
-+{
-+	return ssb_read32(dev->dev, offset);
-+}
-+
-+static inline void gige_write8(struct ssb_gige *dev,
-+			       u16 offset, u8 value)
-+{
-+	ssb_write8(dev->dev, offset, value);
-+}
-+
-+static inline void gige_write16(struct ssb_gige *dev,
-+				u16 offset, u16 value)
-+{
-+	ssb_write16(dev->dev, offset, value);
-+}
-+
-+static inline void gige_write32(struct ssb_gige *dev,
-+				u16 offset, u32 value)
-+{
-+	ssb_write32(dev->dev, offset, value);
-+}
-+
-+static inline
-+u8 gige_pcicfg_read8(struct ssb_gige *dev, unsigned int offset)
-+{
-+	BUG_ON(offset >= 256);
-+	return gige_read8(dev, SSB_GIGE_PCICFG + offset);
-+}
-+
-+static inline
-+u16 gige_pcicfg_read16(struct ssb_gige *dev, unsigned int offset)
-+{
-+	BUG_ON(offset >= 256);
-+	return gige_read16(dev, SSB_GIGE_PCICFG + offset);
-+}
-+
-+static inline
-+u32 gige_pcicfg_read32(struct ssb_gige *dev, unsigned int offset)
-+{
-+	BUG_ON(offset >= 256);
-+	return gige_read32(dev, SSB_GIGE_PCICFG + offset);
-+}
-+
-+static inline
-+void gige_pcicfg_write8(struct ssb_gige *dev,
-+			unsigned int offset, u8 value)
-+{
-+	BUG_ON(offset >= 256);
-+	gige_write8(dev, SSB_GIGE_PCICFG + offset, value);
-+}
-+
-+static inline
-+void gige_pcicfg_write16(struct ssb_gige *dev,
-+			 unsigned int offset, u16 value)
-+{
-+	BUG_ON(offset >= 256);
-+	gige_write16(dev, SSB_GIGE_PCICFG + offset, value);
-+}
-+
-+static inline
-+void gige_pcicfg_write32(struct ssb_gige *dev,
-+			 unsigned int offset, u32 value)
-+{
-+	BUG_ON(offset >= 256);
-+	gige_write32(dev, SSB_GIGE_PCICFG + offset, value);
-+}
-+
-+static int ssb_gige_pci_read_config(struct pci_bus *bus, unsigned int devfn,
-+				    int reg, int size, u32 *val)
-+{
-+	struct ssb_gige *dev = container_of(bus->ops, struct ssb_gige, pci_ops);
-+	unsigned long flags;
-+
-+	if ((PCI_SLOT(devfn) > 0) || (PCI_FUNC(devfn) > 0))
-+		return PCIBIOS_DEVICE_NOT_FOUND;
-+	if (reg >= 256)
-+		return PCIBIOS_DEVICE_NOT_FOUND;
-+
-+	spin_lock_irqsave(&dev->lock, flags);
-+	switch (size) {
-+	case 1:
-+		*val = gige_pcicfg_read8(dev, reg);
-+		break;
-+	case 2:
-+		*val = gige_pcicfg_read16(dev, reg);
-+		break;
-+	case 4:
-+		*val = gige_pcicfg_read32(dev, reg);
-+		break;
-+	default:
-+		WARN_ON(1);
-+	}
-+	spin_unlock_irqrestore(&dev->lock, flags);
-+
-+	return PCIBIOS_SUCCESSFUL;
-+}
-+
-+static int ssb_gige_pci_write_config(struct pci_bus *bus, unsigned int devfn,
-+				     int reg, int size, u32 val)
-+{
-+	struct ssb_gige *dev = container_of(bus->ops, struct ssb_gige, pci_ops);
-+	unsigned long flags;
-+
-+	if ((PCI_SLOT(devfn) > 0) || (PCI_FUNC(devfn) > 0))
-+		return PCIBIOS_DEVICE_NOT_FOUND;
-+	if (reg >= 256)
-+		return PCIBIOS_DEVICE_NOT_FOUND;
-+
-+	spin_lock_irqsave(&dev->lock, flags);
-+	switch (size) {
-+	case 1:
-+		gige_pcicfg_write8(dev, reg, val);
-+		break;
-+	case 2:
-+		gige_pcicfg_write16(dev, reg, val);
-+		break;
-+	case 4:
-+		gige_pcicfg_write32(dev, reg, val);
-+		break;
-+	default:
-+		WARN_ON(1);
-+	}
-+	spin_unlock_irqrestore(&dev->lock, flags);
-+
-+	return PCIBIOS_SUCCESSFUL;
-+}
-+
-+static int ssb_gige_probe(struct ssb_device *sdev, const struct ssb_device_id *id)
-+{
-+	struct ssb_gige *dev;
-+	u32 base, tmslow, tmshigh;
-+
-+	dev = kzalloc(sizeof(*dev), GFP_KERNEL);
-+	if (!dev)
-+		return -ENOMEM;
-+	dev->dev = sdev;
-+
-+	spin_lock_init(&dev->lock);
-+	dev->pci_controller.pci_ops = &dev->pci_ops;
-+	dev->pci_controller.io_resource = &dev->io_resource;
-+	dev->pci_controller.mem_resource = &dev->mem_resource;
-+	dev->pci_controller.io_map_base = 0x800;
-+	dev->pci_ops.read = ssb_gige_pci_read_config;
-+	dev->pci_ops.write = ssb_gige_pci_write_config;
-+
-+	dev->io_resource.name = SSB_GIGE_IO_RES_NAME;
-+	dev->io_resource.start = 0x800;
-+	dev->io_resource.end = 0x8FF;
-+	dev->io_resource.flags = IORESOURCE_IO | IORESOURCE_PCI_FIXED;
-+
-+	if (!ssb_device_is_enabled(sdev))
-+		ssb_device_enable(sdev, 0);
-+
-+	/* Setup BAR0. This is a 64k MMIO region. */
-+	base = ssb_admatch_base(ssb_read32(sdev, SSB_ADMATCH1));
-+	gige_pcicfg_write32(dev, PCI_BASE_ADDRESS_0, base);
-+	gige_pcicfg_write32(dev, PCI_BASE_ADDRESS_1, 0);
-+
-+	dev->mem_resource.name = SSB_GIGE_MEM_RES_NAME;
-+	dev->mem_resource.start = base;
-+	dev->mem_resource.end = base + 0x10000 - 1;
-+	dev->mem_resource.flags = IORESOURCE_MEM | IORESOURCE_PCI_FIXED;
-+
-+	/* Enable the memory region. */
-+	gige_pcicfg_write16(dev, PCI_COMMAND,
-+			    gige_pcicfg_read16(dev, PCI_COMMAND)
-+			    | PCI_COMMAND_MEMORY);
-+
-+	/* Write flushing is controlled by the Flush Status Control register.
-+	 * We want to flush every register write with a timeout and we want
-+	 * to disable the IRQ mask while flushing to avoid concurrency.
-+	 * Note that automatic write flushing does _not_ work from
-+	 * an IRQ handler. The driver must flush manually by reading a register.
-+	 */
-+	gige_write32(dev, SSB_GIGE_SHIM_FLUSHSTAT, 0x00000068);
-+
-+	/* Check if we have an RGMII or GMII PHY-bus.
-+	 * On RGMII do not bypass the DLLs */
-+	tmslow = ssb_read32(sdev, SSB_TMSLOW);
-+	tmshigh = ssb_read32(sdev, SSB_TMSHIGH);
-+	if (tmshigh & SSB_GIGE_TMSHIGH_RGMII) {
-+		tmslow &= ~SSB_GIGE_TMSLOW_TXBYPASS;
-+		tmslow &= ~SSB_GIGE_TMSLOW_RXBYPASS;
-+		dev->has_rgmii = 1;
-+	} else {
-+		tmslow |= SSB_GIGE_TMSLOW_TXBYPASS;
-+		tmslow |= SSB_GIGE_TMSLOW_RXBYPASS;
-+		dev->has_rgmii = 0;
-+	}
-+	tmslow |= SSB_GIGE_TMSLOW_DLLEN;
-+	ssb_write32(sdev, SSB_TMSLOW, tmslow);
-+
-+	ssb_set_drvdata(sdev, dev);
-+	register_pci_controller(&dev->pci_controller);
-+
-+	return 0;
-+}
-+
-+bool pdev_is_ssb_gige_core(struct pci_dev *pdev)
-+{
-+	if (!pdev->resource[0].name)
-+		return 0;
-+	return (strcmp(pdev->resource[0].name, SSB_GIGE_MEM_RES_NAME) == 0);
-+}
-+EXPORT_SYMBOL(pdev_is_ssb_gige_core);
-+
-+int ssb_gige_pcibios_plat_dev_init(struct ssb_device *sdev,
-+				   struct pci_dev *pdev)
-+{
-+	struct ssb_gige *dev = ssb_get_drvdata(sdev);
-+	struct resource *res;
-+
-+	if (pdev->bus->ops != &dev->pci_ops) {
-+		/* The PCI device is not on this SSB GigE bridge device. */
-+		return -ENODEV;
-+	}
-+
-+	/* Fixup the PCI resources. */
-+	res = &(pdev->resource[0]);
-+	res->flags = IORESOURCE_MEM | IORESOURCE_PCI_FIXED;
-+	res->name = dev->mem_resource.name;
-+	res->start = dev->mem_resource.start;
-+	res->end = dev->mem_resource.end;
-+
-+	/* Fixup interrupt lines. */
-+	pdev->irq = ssb_mips_irq(sdev) + 2;
-+	pci_write_config_byte(pdev, PCI_INTERRUPT_LINE, pdev->irq);
-+
-+	return 0;
-+}
-+
-+int ssb_gige_map_irq(struct ssb_device *sdev,
-+		     const struct pci_dev *pdev)
-+{
-+	struct ssb_gige *dev = ssb_get_drvdata(sdev);
-+
-+	if (pdev->bus->ops != &dev->pci_ops) {
-+		/* The PCI device is not on this SSB GigE bridge device. */
-+		return -ENODEV;
-+	}
-+
-+	return ssb_mips_irq(sdev) + 2;
-+}
-+
-+static struct ssb_driver ssb_gige_driver = {
-+	.name		= "BCM-GigE",
-+	.id_table	= ssb_gige_tbl,
-+	.probe		= ssb_gige_probe,
-+};
-+
-+int ssb_gige_init(void)
-+{
-+	return ssb_driver_register(&ssb_gige_driver);
-+}
-diff -ruN linux-2.6.25.10/drivers/ssb/driver_mipscore.c linux-new/drivers/ssb/driver_mipscore.c
---- linux-2.6.25.10/drivers/ssb/driver_mipscore.c	2008-07-02 22:46:47.000000000 -0500
-+++ linux-new/drivers/ssb/driver_mipscore.c	2009-01-09 21:45:52.000000000 -0600
-@@ -210,6 +210,7 @@
- 			/* fallthrough */
- 		case SSB_DEV_PCI:
- 		case SSB_DEV_ETHERNET:
-+		case SSB_DEV_ETHERNET_GBIT:
- 		case SSB_DEV_80211:
- 		case SSB_DEV_USB20_HOST:
- 			/* These devices get their own IRQ line if available, the rest goes on IRQ0 */
-diff -ruN linux-2.6.25.10/drivers/ssb/driver_pcicore.c linux-new/drivers/ssb/driver_pcicore.c
---- linux-2.6.25.10/drivers/ssb/driver_pcicore.c	2008-07-02 22:46:47.000000000 -0500
-+++ linux-new/drivers/ssb/driver_pcicore.c	2009-01-09 21:45:52.000000000 -0600
-@@ -60,78 +60,6 @@
- /* Core to access the external PCI config space. Can only have one. */
- static struct ssb_pcicore *extpci_core;
- 
--static u32 ssb_pcicore_pcibus_iobase = 0x100;
--static u32 ssb_pcicore_pcibus_membase = SSB_PCI_DMA;
--
--int pcibios_plat_dev_init(struct pci_dev *d)
--{
--	struct resource *res;
--	int pos, size;
--	u32 *base;
--
--	ssb_printk(KERN_INFO "PCI: Fixing up device %s\n",
--		   pci_name(d));
--
--	/* Fix up resource bases */
--	for (pos = 0; pos < 6; pos++) {
--		res = &d->resource[pos];
--		if (res->flags & IORESOURCE_IO)
--			base = &ssb_pcicore_pcibus_iobase;
--		else
--			base = &ssb_pcicore_pcibus_membase;
--		res->flags |= IORESOURCE_PCI_FIXED;
--		if (res->end) {
--			size = res->end - res->start + 1;
--			if (*base & (size - 1))
--				*base = (*base + size) & ~(size - 1);
--			res->start = *base;
--			res->end = res->start + size - 1;
--			*base += size;
--			pci_write_config_dword(d, PCI_BASE_ADDRESS_0 + (pos << 2), res->start);
--		}
--		/* Fix up PCI bridge BAR0 only */
--		if (d->bus->number == 0 && PCI_SLOT(d->devfn) == 0)
--			break;
--	}
--	/* Fix up interrupt lines */
--	d->irq = ssb_mips_irq(extpci_core->dev) + 2;
--	pci_write_config_byte(d, PCI_INTERRUPT_LINE, d->irq);
--
--	return 0;
--}
--
--static void __init ssb_fixup_pcibridge(struct pci_dev *dev)
--{
--	u8 lat;
--
--	if (dev->bus->number != 0 || PCI_SLOT(dev->devfn) != 0)
--		return;
--
--	ssb_printk(KERN_INFO "PCI: Fixing up bridge %s\n", pci_name(dev));
--
--	/* Enable PCI bridge bus mastering and memory space */
--	pci_set_master(dev);
--	if (pcibios_enable_device(dev, ~0) < 0) {
--		ssb_printk(KERN_ERR "PCI: SSB bridge enable failed\n");
--		return;
--	}
--
--	/* Enable PCI bridge BAR1 prefetch and burst */
--	pci_write_config_dword(dev, SSB_BAR1_CONTROL, 3);
--
--	/* Make sure our latency is high enough to handle the devices behind us */
--	lat = 168;
--	ssb_printk(KERN_INFO "PCI: Fixing latency timer of device %s to %u\n",
--		   pci_name(dev), lat);
--	pci_write_config_byte(dev, PCI_LATENCY_TIMER, lat);
--}
--DECLARE_PCI_FIXUP_EARLY(PCI_ANY_ID, PCI_ANY_ID, ssb_fixup_pcibridge);
--
--int __init pcibios_map_irq(const struct pci_dev *dev, u8 slot, u8 pin)
--{
--	return ssb_mips_irq(extpci_core->dev) + 2;
--}
--
- static u32 get_cfgspace_addr(struct ssb_pcicore *pc,
- 			     unsigned int bus, unsigned int dev,
- 			     unsigned int func, unsigned int off)
-@@ -320,6 +248,95 @@
- 	.mem_offset	= 0x24000000,
- };
- 
-+static u32 ssb_pcicore_pcibus_iobase = 0x100;
-+static u32 ssb_pcicore_pcibus_membase = SSB_PCI_DMA;
-+
-+/* This function is called when doing a pci_enable_device().
-+ * We must first check if the device is a device on the PCI-core bridge. */
-+int ssb_pcicore_plat_dev_init(struct pci_dev *d)
-+{
-+	struct resource *res;
-+	int pos, size;
-+	u32 *base;
-+
-+	if (d->bus->ops != &ssb_pcicore_pciops) {
-+		/* This is not a device on the PCI-core bridge. */
-+		return -ENODEV;
-+	}
-+
-+	ssb_printk(KERN_INFO "PCI: Fixing up device %s\n",
-+		   pci_name(d));
-+
-+	/* Fix up resource bases */
-+	for (pos = 0; pos < 6; pos++) {
-+		res = &d->resource[pos];
-+		if (res->flags & IORESOURCE_IO)
-+			base = &ssb_pcicore_pcibus_iobase;
-+		else
-+			base = &ssb_pcicore_pcibus_membase;
-+		res->flags |= IORESOURCE_PCI_FIXED;
-+		if (res->end) {
-+			size = res->end - res->start + 1;
-+			if (*base & (size - 1))
-+				*base = (*base + size) & ~(size - 1);
-+			res->start = *base;
-+			res->end = res->start + size - 1;
-+			*base += size;
-+			pci_write_config_dword(d, PCI_BASE_ADDRESS_0 + (pos << 2), res->start);
-+		}
-+		/* Fix up PCI bridge BAR0 only */
-+		if (d->bus->number == 0 && PCI_SLOT(d->devfn) == 0)
-+			break;
-+	}
-+	/* Fix up interrupt lines */
-+	d->irq = ssb_mips_irq(extpci_core->dev) + 2;
-+	pci_write_config_byte(d, PCI_INTERRUPT_LINE, d->irq);
-+
-+	return 0;
-+}
-+
-+/* Early PCI fixup for a device on the PCI-core bridge. */
-+static void ssb_pcicore_fixup_pcibridge(struct pci_dev *dev)
-+{
-+	u8 lat;
-+
-+	if (dev->bus->ops != &ssb_pcicore_pciops) {
-+		/* This is not a device on the PCI-core bridge. */
-+		return;
-+	}
-+	if (dev->bus->number != 0 || PCI_SLOT(dev->devfn) != 0)
-+		return;
-+
-+	ssb_printk(KERN_INFO "PCI: Fixing up bridge %s\n", pci_name(dev));
-+
-+	/* Enable PCI bridge bus mastering and memory space */
-+	pci_set_master(dev);
-+	if (pcibios_enable_device(dev, ~0) < 0) {
-+		ssb_printk(KERN_ERR "PCI: SSB bridge enable failed\n");
-+		return;
-+	}
-+
-+	/* Enable PCI bridge BAR1 prefetch and burst */
-+	pci_write_config_dword(dev, SSB_BAR1_CONTROL, 3);
-+
-+	/* Make sure our latency is high enough to handle the devices behind us */
-+	lat = 168;
-+	ssb_printk(KERN_INFO "PCI: Fixing latency timer of device %s to %u\n",
-+		   pci_name(dev), lat);
-+	pci_write_config_byte(dev, PCI_LATENCY_TIMER, lat);
-+}
-+DECLARE_PCI_FIXUP_EARLY(PCI_ANY_ID, PCI_ANY_ID, ssb_pcicore_fixup_pcibridge);
-+
-+/* PCI device IRQ mapping. */
-+int ssb_pcicore_pcibios_map_irq(const struct pci_dev *dev, u8 slot, u8 pin)
-+{
-+	if (dev->bus->ops != &ssb_pcicore_pciops) {
-+		/* This is not a device on the PCI-core bridge. */
-+		return -ENODEV;
-+	}
-+	return ssb_mips_irq(extpci_core->dev) + 2;
-+}
-+
- static void ssb_pcicore_init_hostmode(struct ssb_pcicore *pc)
- {
- 	u32 val;
-diff -ruN linux-2.6.25.10/drivers/ssb/embedded.c linux-new/drivers/ssb/embedded.c
---- linux-2.6.25.10/drivers/ssb/embedded.c	2008-07-02 22:46:47.000000000 -0500
-+++ linux-new/drivers/ssb/embedded.c	2009-01-09 21:45:52.000000000 -0600
-@@ -10,6 +10,9 @@
- 
- #include <linux/ssb/ssb.h>
- #include <linux/ssb/ssb_embedded.h>
-+#include <linux/ssb/ssb_driver_pci.h>
-+#include <linux/ssb/ssb_driver_gige.h>
-+#include <linux/pci.h>
- 
- #include "ssb_private.h"
- 
-@@ -130,3 +133,90 @@
- 	return res;
- }
- EXPORT_SYMBOL(ssb_gpio_polarity);
-+
-+#ifdef CONFIG_SSB_DRIVER_GIGE
-+static int gige_pci_init_callback(struct ssb_bus *bus, unsigned long data)
-+{
-+	struct pci_dev *pdev = (struct pci_dev *)data;
-+	struct ssb_device *dev;
-+	unsigned int i;
-+	int res;
-+
-+	for (i = 0; i < bus->nr_devices; i++) {
-+		dev = &(bus->devices[i]);
-+		if (dev->id.coreid != SSB_DEV_ETHERNET_GBIT)
-+			continue;
-+		if (!dev->dev ||
-+		    !dev->dev->driver ||
-+		    !device_is_registered(dev->dev))
-+			continue;
-+		res = ssb_gige_pcibios_plat_dev_init(dev, pdev);
-+		if (res >= 0)
-+			return res;
-+	}
-+
-+	return -ENODEV;
-+}
-+#endif /* CONFIG_SSB_DRIVER_GIGE */
-+
-+int ssb_pcibios_plat_dev_init(struct pci_dev *dev)
-+{
-+	int err;
-+
-+	err = ssb_pcicore_plat_dev_init(dev);
-+	if (!err)
-+		return 0;
-+#ifdef CONFIG_SSB_DRIVER_GIGE
-+	err = ssb_for_each_bus_call((unsigned long)dev, gige_pci_init_callback);
-+	if (err >= 0)
-+		return err;
-+#endif
-+	/* This is not a PCI device on any SSB device. */
-+
-+	return -ENODEV;
-+}
-+
-+#ifdef CONFIG_SSB_DRIVER_GIGE
-+static int gige_map_irq_callback(struct ssb_bus *bus, unsigned long data)
-+{
-+	const struct pci_dev *pdev = (const struct pci_dev *)data;
-+	struct ssb_device *dev;
-+	unsigned int i;
-+	int res;
-+
-+	for (i = 0; i < bus->nr_devices; i++) {
-+		dev = &(bus->devices[i]);
-+		if (dev->id.coreid != SSB_DEV_ETHERNET_GBIT)
-+			continue;
-+		if (!dev->dev ||
-+		    !dev->dev->driver ||
-+		    !device_is_registered(dev->dev))
-+			continue;
-+		res = ssb_gige_map_irq(dev, pdev);
-+		if (res >= 0)
-+			return res;
-+	}
-+
-+	return -ENODEV;
-+}
-+#endif /* CONFIG_SSB_DRIVER_GIGE */
-+
-+int ssb_pcibios_map_irq(const struct pci_dev *dev, u8 slot, u8 pin)
-+{
-+	int res;
-+
-+	/* Check if this PCI device is a device on a SSB bus or device
-+	 * and return the IRQ number for it. */
-+
-+	res = ssb_pcicore_pcibios_map_irq(dev, slot, pin);
-+	if (res >= 0)
-+		return res;
-+#ifdef CONFIG_SSB_DRIVER_GIGE
-+	res = ssb_for_each_bus_call((unsigned long)dev, gige_map_irq_callback);
-+	if (res >= 0)
-+		return res;
-+#endif
-+	/* This is not a PCI device on any SSB device. */
-+
-+	return -ENODEV;
-+}
-diff -ruN linux-2.6.25.10/drivers/ssb/Kconfig linux-new/drivers/ssb/Kconfig
---- linux-2.6.25.10/drivers/ssb/Kconfig	2008-07-02 22:46:47.000000000 -0500
-+++ linux-new/drivers/ssb/Kconfig	2009-01-09 21:45:52.000000000 -0600
-@@ -125,4 +125,13 @@
- 
- 	  If unsure, say N
- 
-+config SSB_DRIVER_GIGE
-+	bool "SSB Broadcom Gigabit Ethernet driver"
-+	depends on SSB_PCIHOST_POSSIBLE && SSB_EMBEDDED && MIPS
-+	help
-+	  Driver for the Sonics Silicon Backplane attached
-+	  Broadcom Gigabit Ethernet.
-+
-+	  If unsure, say N
-+
- endmenu
-diff -ruN linux-2.6.25.10/drivers/ssb/main.c linux-new/drivers/ssb/main.c
---- linux-2.6.25.10/drivers/ssb/main.c	2008-07-02 22:46:47.000000000 -0500
-+++ linux-new/drivers/ssb/main.c	2009-01-09 21:45:52.000000000 -0600
-@@ -14,6 +14,7 @@
- #include <linux/io.h>
- #include <linux/ssb/ssb.h>
- #include <linux/ssb/ssb_regs.h>
-+#include <linux/ssb/ssb_driver_gige.h>
- #include <linux/dma-mapping.h>
- #include <linux/pci.h>
- 
-@@ -68,6 +69,25 @@
- }
- #endif /* CONFIG_SSB_PCIHOST */
- 
-+int ssb_for_each_bus_call(unsigned long data,
-+			  int (*func)(struct ssb_bus *bus, unsigned long data))
-+{
-+	struct ssb_bus *bus;
-+	int res;
-+
-+	ssb_buses_lock();
-+	list_for_each_entry(bus, &buses, list) {
-+		res = func(bus, data);
-+		if (res >= 0) {
-+			ssb_buses_unlock();
-+			return res;
-+		}
-+	}
-+	ssb_buses_unlock();
-+
-+	return -ENODEV;
-+}
-+
- static struct ssb_device *ssb_device_get(struct ssb_device *dev)
- {
- 	if (dev)
-@@ -1161,7 +1181,14 @@
- 	err = b43_pci_ssb_bridge_init();
- 	if (err) {
- 		ssb_printk(KERN_ERR "Broadcom 43xx PCI-SSB-bridge "
--			   "initialization failed");
-+			   "initialization failed\n");
-+		/* don't fail SSB init because of this */
-+		err = 0;
-+	}
-+	err = ssb_gige_init();
-+	if (err) {
-+		ssb_printk(KERN_ERR "SSB Broadcom Gigabit Ethernet "
-+			   "driver initialization failed\n");
- 		/* don't fail SSB init because of this */
- 		err = 0;
- 	}
-@@ -1175,6 +1202,7 @@
- 
- static void __exit ssb_modexit(void)
- {
-+	ssb_gige_exit();
- 	b43_pci_ssb_bridge_exit();
- 	bus_unregister(&ssb_bustype);
- }
-diff -ruN linux-2.6.25.10/drivers/ssb/Makefile linux-new/drivers/ssb/Makefile
---- linux-2.6.25.10/drivers/ssb/Makefile	2008-07-02 22:46:47.000000000 -0500
-+++ linux-new/drivers/ssb/Makefile	2009-01-09 21:45:52.000000000 -0600
-@@ -11,6 +11,7 @@
- ssb-$(CONFIG_SSB_DRIVER_MIPS)		+= driver_mipscore.o
- ssb-$(CONFIG_SSB_DRIVER_EXTIF)		+= driver_extif.o
- ssb-$(CONFIG_SSB_DRIVER_PCICORE)	+= driver_pcicore.o
-+ssb-$(CONFIG_SSB_DRIVER_GIGE)		+= driver_gige.o
- 
- # b43 pci-ssb-bridge driver
- # Not strictly a part of SSB, but kept here for convenience
-diff -ruN linux-2.6.25.10/drivers/ssb/ssb_private.h linux-new/drivers/ssb/ssb_private.h
---- linux-2.6.25.10/drivers/ssb/ssb_private.h	2008-07-02 22:46:47.000000000 -0500
-+++ linux-new/drivers/ssb/ssb_private.h	2009-01-09 21:45:52.000000000 -0600
-@@ -118,6 +118,8 @@
- extern int ssb_devices_freeze(struct ssb_bus *bus);
- extern int ssb_devices_thaw(struct ssb_bus *bus);
- extern struct ssb_bus *ssb_pci_dev_to_bus(struct pci_dev *pdev);
-+int ssb_for_each_bus_call(unsigned long data,
-+			  int (*func)(struct ssb_bus *bus, unsigned long data));
- 
- /* b43_pci_bridge.c */
- #ifdef CONFIG_SSB_B43_PCI_BRIDGE
-diff -ruN linux-2.6.25.10/include/linux/ssb/ssb_driver_gige.h linux-new/include/linux/ssb/ssb_driver_gige.h
---- linux-2.6.25.10/include/linux/ssb/ssb_driver_gige.h	1969-12-31 18:00:00.000000000 -0600
-+++ linux-new/include/linux/ssb/ssb_driver_gige.h	2009-01-09 21:45:52.000000000 -0600
-@@ -0,0 +1,174 @@
-+#ifndef LINUX_SSB_DRIVER_GIGE_H_
-+#define LINUX_SSB_DRIVER_GIGE_H_
-+
-+#include <linux/ssb/ssb.h>
-+#include <linux/pci.h>
-+#include <linux/spinlock.h>
-+
-+
-+#ifdef CONFIG_SSB_DRIVER_GIGE
-+
-+
-+#define SSB_GIGE_PCIIO			0x0000 /* PCI I/O Registers (1024 bytes) */
-+#define SSB_GIGE_RESERVED		0x0400 /* Reserved (1024 bytes) */
-+#define SSB_GIGE_PCICFG			0x0800 /* PCI config space (256 bytes) */
-+#define SSB_GIGE_SHIM_FLUSHSTAT		0x0C00 /* PCI to OCP: Flush status control (32bit) */
-+#define SSB_GIGE_SHIM_FLUSHRDA		0x0C04 /* PCI to OCP: Flush read address (32bit) */
-+#define SSB_GIGE_SHIM_FLUSHTO		0x0C08 /* PCI to OCP: Flush timeout counter (32bit) */
-+#define SSB_GIGE_SHIM_BARRIER		0x0C0C /* PCI to OCP: Barrier register (32bit) */
-+#define SSB_GIGE_SHIM_MAOCPSI		0x0C10 /* PCI to OCP: MaocpSI Control (32bit) */
-+#define SSB_GIGE_SHIM_SIOCPMA		0x0C14 /* PCI to OCP: SiocpMa Control (32bit) */
-+
-+/* TM Status High flags */
-+#define SSB_GIGE_TMSHIGH_RGMII		0x00010000 /* Have an RGMII PHY-bus */
-+/* TM Status Low flags */
-+#define SSB_GIGE_TMSLOW_TXBYPASS	0x00080000 /* TX bypass (no delay) */
-+#define SSB_GIGE_TMSLOW_RXBYPASS	0x00100000 /* RX bypass (no delay) */
-+#define SSB_GIGE_TMSLOW_DLLEN		0x01000000 /* Enable DLL controls */
-+
-+/* Boardflags (low) */
-+#define SSB_GIGE_BFL_ROBOSWITCH		0x0010
-+
-+
-+#define SSB_GIGE_MEM_RES_NAME		"SSB Broadcom 47xx GigE memory"
-+#define SSB_GIGE_IO_RES_NAME		"SSB Broadcom 47xx GigE I/O"
-+
-+struct ssb_gige {
-+	struct ssb_device *dev;
-+
-+	spinlock_t lock;
-+
-+	/* True, if the device has an RGMII bus.
-+	 * False, if the device has a GMII bus. */
-+	bool has_rgmii;
-+
-+	/* The PCI controller device. */
-+	struct pci_controller pci_controller;
-+	struct pci_ops pci_ops;
-+	struct resource mem_resource;
-+	struct resource io_resource;
-+};
-+
-+/* Check whether a PCI device is a SSB Gigabit Ethernet core. */
-+extern bool pdev_is_ssb_gige_core(struct pci_dev *pdev);
-+
-+/* Convert a pci_dev pointer to a ssb_gige pointer. */
-+static inline struct ssb_gige * pdev_to_ssb_gige(struct pci_dev *pdev)
-+{
-+	if (!pdev_is_ssb_gige_core(pdev))
-+		return NULL;
-+	return container_of(pdev->bus->ops, struct ssb_gige, pci_ops);
-+}
-+
-+/* Returns whether the PHY is connected by an RGMII bus. */
-+static inline bool ssb_gige_is_rgmii(struct pci_dev *pdev)
-+{
-+	struct ssb_gige *dev = pdev_to_ssb_gige(pdev);
-+	return (dev ? dev->has_rgmii : 0);
-+}
-+
-+/* Returns whether we have a Roboswitch. */
-+static inline bool ssb_gige_have_roboswitch(struct pci_dev *pdev)
-+{
-+	struct ssb_gige *dev = pdev_to_ssb_gige(pdev);
-+	if (dev)
-+		return !!(dev->dev->bus->sprom.boardflags_lo &
-+			  SSB_GIGE_BFL_ROBOSWITCH);
-+	return 0;
-+}
-+
-+/* Returns whether we can only do one DMA at once. */
-+static inline bool ssb_gige_one_dma_at_once(struct pci_dev *pdev)
-+{
-+	struct ssb_gige *dev = pdev_to_ssb_gige(pdev);
-+	if (dev)
-+		return ((dev->dev->bus->chip_id == 0x4785) &&
-+			(dev->dev->bus->chip_rev < 2));
-+	return 0;
-+}
-+
-+/* Returns whether we must flush posted writes. */
-+static inline bool ssb_gige_must_flush_posted_writes(struct pci_dev *pdev)
-+{
-+	struct ssb_gige *dev = pdev_to_ssb_gige(pdev);
-+	if (dev)
-+		return (dev->dev->bus->chip_id == 0x4785);
-+	return 0;
-+}
-+
-+extern char * nvram_get(const char *name);
-+/* Get the device MAC address */
-+static inline void ssb_gige_get_macaddr(struct pci_dev *pdev, u8 *macaddr)
-+{
-+#ifdef CONFIG_BCM947XX
-+	char *res = nvram_get("et0macaddr");
-+	if (res)
-+		memcpy(macaddr, res, 6);
-+#endif
-+}
-+
-+extern int ssb_gige_pcibios_plat_dev_init(struct ssb_device *sdev,
-+					  struct pci_dev *pdev);
-+extern int ssb_gige_map_irq(struct ssb_device *sdev,
-+			    const struct pci_dev *pdev);
-+
-+/* The GigE driver is not a standalone module, because we don't have support
-+ * for unregistering the driver. So we could not unload the module anyway. */
-+extern int ssb_gige_init(void);
-+static inline void ssb_gige_exit(void)
-+{
-+	/* Currently we can not unregister the GigE driver,
-+	 * because we can not unregister the PCI bridge. */
-+	BUG();
-+}
-+
-+
-+#else /* CONFIG_SSB_DRIVER_GIGE */
-+/* Gigabit Ethernet driver disabled */
-+
-+
-+static inline int ssb_gige_pcibios_plat_dev_init(struct ssb_device *sdev,
-+						 struct pci_dev *pdev)
-+{
-+	return -ENOSYS;
-+}
-+static inline int ssb_gige_map_irq(struct ssb_device *sdev,
-+				   const struct pci_dev *pdev)
-+{
-+	return -ENOSYS;
-+}
-+static inline int ssb_gige_init(void)
-+{
-+	return 0;
-+}
-+static inline void ssb_gige_exit(void)
-+{
-+}
-+
-+static inline bool pdev_is_ssb_gige_core(struct pci_dev *pdev)
-+{
-+	return 0;
-+}
-+static inline struct ssb_gige * pdev_to_ssb_gige(struct pci_dev *pdev)
-+{
-+	return NULL;
-+}
-+static inline bool ssb_gige_is_rgmii(struct pci_dev *pdev)
-+{
-+	return 0;
-+}
-+static inline bool ssb_gige_have_roboswitch(struct pci_dev *pdev)
-+{
-+	return 0;
-+}
-+static inline bool ssb_gige_one_dma_at_once(struct pci_dev *pdev)
-+{
-+	return 0;
-+}
-+static inline bool ssb_gige_must_flush_posted_writes(struct pci_dev *pdev)
-+{
-+	return 0;
-+}
-+
-+#endif /* CONFIG_SSB_DRIVER_GIGE */
-+#endif /* LINUX_SSB_DRIVER_GIGE_H_ */
-diff -ruN linux-2.6.25.10/include/linux/ssb/ssb_driver_pci.h linux-new/include/linux/ssb/ssb_driver_pci.h
---- linux-2.6.25.10/include/linux/ssb/ssb_driver_pci.h	2008-07-02 22:46:47.000000000 -0500
-+++ linux-new/include/linux/ssb/ssb_driver_pci.h	2009-01-09 21:45:52.000000000 -0600
-@@ -1,6 +1,11 @@
- #ifndef LINUX_SSB_PCICORE_H_
- #define LINUX_SSB_PCICORE_H_
- 
-+#include <linux/types.h>
-+
-+struct pci_dev;
-+
-+
- #ifdef CONFIG_SSB_DRIVER_PCICORE
- 
- /* PCI core registers. */
-@@ -88,6 +93,9 @@
- extern int ssb_pcicore_dev_irqvecs_enable(struct ssb_pcicore *pc,
- 					  struct ssb_device *dev);
- 
-+int ssb_pcicore_plat_dev_init(struct pci_dev *d);
-+int ssb_pcicore_pcibios_map_irq(const struct pci_dev *dev, u8 slot, u8 pin);
-+
- 
- #else /* CONFIG_SSB_DRIVER_PCICORE */
- 
-@@ -107,5 +115,16 @@
- 	return 0;
- }
- 
-+static inline
-+int ssb_pcicore_plat_dev_init(struct pci_dev *d)
-+{
-+	return -ENODEV;
-+}
-+static inline
-+int ssb_pcicore_pcibios_map_irq(const struct pci_dev *dev, u8 slot, u8 pin)
-+{
-+	return -ENODEV;
-+}
-+
- #endif /* CONFIG_SSB_DRIVER_PCICORE */
- #endif /* LINUX_SSB_PCICORE_H_ */
-diff -ruN linux-2.6.25.10/include/linux/ssb/ssb.h linux-new/include/linux/ssb/ssb.h
---- linux-2.6.25.10/include/linux/ssb/ssb.h	2008-07-02 22:46:47.000000000 -0500
-+++ linux-new/include/linux/ssb/ssb.h	2009-01-09 21:45:52.000000000 -0600
-@@ -416,5 +416,12 @@
- extern u32 ssb_admatch_base(u32 adm);
- extern u32 ssb_admatch_size(u32 adm);
- 
-+/* PCI device mapping and fixup routines.
-+ * Called from the architecture pcibios init code.
-+ * These are only available on SSB_EMBEDDED configurations. */
-+#ifdef CONFIG_SSB_EMBEDDED
-+int ssb_pcibios_plat_dev_init(struct pci_dev *dev);
-+int ssb_pcibios_map_irq(const struct pci_dev *dev, u8 slot, u8 pin);
-+#endif /* CONFIG_SSB_EMBEDDED */
- 
- #endif /* LINUX_SSB_H_ */
--- a/sources/patches/linux-ppcqemu.patch	Sun Feb 01 16:45:51 2009 -0600
+++ b/sources/patches/linux-ppcqemu.patch	Sun Feb 01 17:36:28 2009 -0600
@@ -41,7 +41,7 @@
 +source "arch/powerpc/platforms/qemu/Kconfig"
  source "arch/powerpc/platforms/maple/Kconfig"
  source "arch/powerpc/platforms/pasemi/Kconfig"
- source "arch/powerpc/platforms/celleb/Kconfig"
+ source "arch/powerpc/platforms/ps3/Kconfig"
 Index: kernel/arch/powerpc/platforms/qemu/Kconfig
 ===================================================================
 --- /dev/null	1970-01-01 00:00:00.000000000 +0000
@@ -300,7 +300,7 @@
 +
 +	/* polling */
 +	i8259_init(pic, int_ack);
-+	ppc_md.get_irq = i8259_irq;
++	//ppc_md.get_irq = i8259_irq;
 +
 +	/* set default host */
 +	irq_set_default_host(i8259_get_host());
@@ -359,8 +359,8 @@
 +		return 0;
 +
 +#if defined(CONFIG_BLK_DEV_IDE) || defined(CONFIG_BLK_DEV_IDE_MODULE)
-+	ppc_ide_md.default_irq = qemu_ide_default_irq;
-+	ppc_ide_md.default_io_base = qemu_ide_default_io_base;
++//	ppc_ide_md.default_irq = qemu_ide_default_irq;
++//	ppc_ide_md.default_io_base = qemu_ide_default_io_base;
 +#endif
 +
 +	return 1;
--- a/sources/targets/hw-wrt610n/miniconfig-linux	Sun Feb 01 16:45:51 2009 -0600
+++ b/sources/targets/hw-wrt610n/miniconfig-linux	Sun Feb 01 17:36:28 2009 -0600
@@ -1,10 +1,10 @@
 CONFIG_BCM47XX=y
+CONFIG_UNEVICTABLE_LRU=y
 CONFIG_NO_HZ=y
 CONFIG_HIGH_RES_TIMERS=y
 CONFIG_HZ_100=y
 CONFIG_SECCOMP=y
 CONFIG_EXPERIMENTAL=y
-CONFIG_LOCALVERSION_AUTO=y
 CONFIG_SWAP=y
 CONFIG_SYSVIPC=y
 CONFIG_GROUP_SCHED=y
@@ -26,17 +26,11 @@
 CONFIG_EVENTFD=y
 CONFIG_SHMEM=y
 CONFIG_VM_EVENT_COUNTERS=y
-CONFIG_SLAB=y
-CONFIG_PROC_PAGE_MONITOR=y
 CONFIG_BLOCK=y
-CONFIG_IOSCHED_AS=y
-CONFIG_IOSCHED_DEADLINE=y
-CONFIG_IOSCHED_CFQ=y
 CONFIG_PCI=y
 CONFIG_PCI_LEGACY=y
 CONFIG_BINFMT_ELF=y
 CONFIG_PM=y
-CONFIG_SUSPEND=y
 CONFIG_NET=y
 CONFIG_PACKET=y
 CONFIG_PACKET_MMAP=y
@@ -59,48 +53,33 @@
 CONFIG_MTD_PARTITIONS=y
 CONFIG_MTD_CFI=y
 CONFIG_MTD_JEDECPROBE=y
-CONFIG_MTD_BCM47XX=y
 CONFIG_BLK_DEV=y
 CONFIG_BLK_DEV_LOOP=y
-CONFIG_MISC_DEVICES=y
 CONFIG_NETDEVICES=y
 CONFIG_NET_ETHERNET=y
-CONFIG_AX88796=y
 CONFIG_NET_PCI=y
 CONFIG_PCNET32=y
-CONFIG_NE2K_PCI=y
-CONFIG_8139CP=y
-CONFIG_NETDEV_1000=y
-CONFIG_NETDEV_10000=y
+CONFIG_INPUT=y
 CONFIG_SERIO=y
-CONFIG_VT=y
-CONFIG_VT_CONSOLE=y
 CONFIG_SERIAL_8250=y
 CONFIG_SERIAL_8250_CONSOLE=y
 CONFIG_SERIAL_8250_PCI=y
 CONFIG_UNIX98_PTYS=y
 CONFIG_LEGACY_PTYS=y
+CONFIG_LEGACY_PTY_COUNT=8
 CONFIG_HW_RANDOM=y
-CONFIG_RTC=y
-CONFIG_HWMON=y
 CONFIG_SSB_PCIHOST=y
 CONFIG_SSB_DRIVER_PCICORE=y
-CONFIG_VGA_CONSOLE=y
 CONFIG_HID_SUPPORT=y
 CONFIG_HID=y
 CONFIG_USB_SUPPORT=y
-CONFIG_EXT2_FS=y
-CONFIG_EXT3_FS=y
-CONFIG_EXT3_FS_XATTR=y
 CONFIG_DNOTIFY=y
 CONFIG_INOTIFY=y
 CONFIG_INOTIFY_USER=y
 CONFIG_PROC_FS=y
 CONFIG_PROC_KCORE=y
 CONFIG_PROC_SYSCTL=y
+CONFIG_PROC_PAGE_MONITOR=y
 CONFIG_SYSFS=y
 CONFIG_TMPFS=y
-CONFIG_NETWORK_FILESYSTEMS=y
-CONFIG_ENABLE_WARN_DEPRECATED=y
-CONFIG_ENABLE_MUST_CHECK=y
 CONFIG_CRYPTO_HW=y
--- a/sources/targets/i586/miniconfig-linux	Sun Feb 01 16:45:51 2009 -0600
+++ b/sources/targets/i586/miniconfig-linux	Sun Feb 01 17:36:28 2009 -0600
@@ -2,15 +2,11 @@
 CONFIG_SYSVIPC=y
 CONFIG_IKCONFIG=y
 CONFIG_IKCONFIG_PROC=y
+CONFIG_BLK_DEV_INITRD=y
 CONFIG_KALLSYMS_EXTRA_PASS=y
-CONFIG_IOSCHED_AS=y
-CONFIG_IOSCHED_DEADLINE=y
-CONFIG_IOSCHED_CFQ=y
-CONFIG_DEFAULT_AS=y
 CONFIG_M586=y
-CONFIG_REGPARM=y
+CONFIG_UNEVICTABLE_LRU=y
 CONFIG_COMPAT_VDSO=y
-CONFIG_ACPI=y
 CONFIG_PCI=y
 CONFIG_BINFMT_ELF=y
 CONFIG_NET=y
@@ -21,16 +17,11 @@
 CONFIG_PREVENT_FIRMWARE_BUILD=y
 CONFIG_BLK_DEV=y
 CONFIG_BLK_DEV_LOOP=y
-CONFIG_BLK_DEV_INITRD=y
 CONFIG_IDE=y
-CONFIG_BLK_DEV_IDE=y
-CONFIG_BLK_DEV_IDEDISK=y
+CONFIG_IDE_GD=y
+CONFIG_IDE_GD_ATA=y
 CONFIG_IDE_GENERIC=y
-CONFIG_BLK_DEV_IDEPCI=y
-CONFIG_IDEPCI_SHARE_IRQ=y
 CONFIG_BLK_DEV_GENERIC=y
-CONFIG_BLK_DEV_IDEDMA_PCI=y
-CONFIG_IDEDMA_PCI_AUTO=y
 CONFIG_BLK_DEV_PIIX=y
 CONFIG_NETDEVICES=y
 CONFIG_NET_ETHERNET=y
@@ -38,11 +29,10 @@
 CONFIG_NE2K_PCI=y
 CONFIG_SERIAL_8250=y
 CONFIG_SERIAL_8250_CONSOLE=y
+CONFIG_LEGACY_PTYS=y
+CONFIG_LEGACY_PTY_COUNT=8
 CONFIG_RTC=y
 CONFIG_EXT2_FS=y
 CONFIG_EXT3_FS=y
 CONFIG_TMPFS=y
-CONFIG_ENABLE_MUST_CHECK=y
 CONFIG_MAGIC_SYSRQ=y
-CONFIG_SQUASHFS=y
-CONFIG_EXT3_FS=y
--- a/sources/targets/i686/miniconfig-linux	Sun Feb 01 16:45:51 2009 -0600
+++ b/sources/targets/i686/miniconfig-linux	Sun Feb 01 17:36:28 2009 -0600
@@ -2,15 +2,11 @@
 CONFIG_SYSVIPC=y
 CONFIG_IKCONFIG=y
 CONFIG_IKCONFIG_PROC=y
+CONFIG_BLK_DEV_INITRD=y
 CONFIG_KALLSYMS_EXTRA_PASS=y
-CONFIG_IOSCHED_AS=y
-CONFIG_IOSCHED_DEADLINE=y
-CONFIG_IOSCHED_CFQ=y
-CONFIG_DEFAULT_AS=y
 CONFIG_MPENTIUMII=y
-CONFIG_REGPARM=y
+CONFIG_UNEVICTABLE_LRU=y
 CONFIG_COMPAT_VDSO=y
-CONFIG_ACPI=y
 CONFIG_PCI=y
 CONFIG_BINFMT_ELF=y
 CONFIG_NET=y
@@ -21,16 +17,11 @@
 CONFIG_PREVENT_FIRMWARE_BUILD=y
 CONFIG_BLK_DEV=y
 CONFIG_BLK_DEV_LOOP=y
-CONFIG_BLK_DEV_INITRD=y
 CONFIG_IDE=y
-CONFIG_BLK_DEV_IDE=y
-CONFIG_BLK_DEV_IDEDISK=y
+CONFIG_IDE_GD=y
+CONFIG_IDE_GD_ATA=y
 CONFIG_IDE_GENERIC=y
-CONFIG_BLK_DEV_IDEPCI=y
-CONFIG_IDEPCI_SHARE_IRQ=y
 CONFIG_BLK_DEV_GENERIC=y
-CONFIG_BLK_DEV_IDEDMA_PCI=y
-CONFIG_IDEDMA_PCI_AUTO=y
 CONFIG_BLK_DEV_PIIX=y
 CONFIG_NETDEVICES=y
 CONFIG_NET_ETHERNET=y
@@ -38,10 +29,10 @@
 CONFIG_NE2K_PCI=y
 CONFIG_SERIAL_8250=y
 CONFIG_SERIAL_8250_CONSOLE=y
+CONFIG_LEGACY_PTYS=y
+CONFIG_LEGACY_PTY_COUNT=8
 CONFIG_RTC=y
 CONFIG_EXT2_FS=y
 CONFIG_EXT3_FS=y
 CONFIG_TMPFS=y
-CONFIG_ENABLE_MUST_CHECK=y
 CONFIG_MAGIC_SYSRQ=y
-CONFIG_SQUASHFS=y
--- a/sources/targets/mips/miniconfig-linux	Sun Feb 01 16:45:51 2009 -0600
+++ b/sources/targets/mips/miniconfig-linux	Sun Feb 01 17:36:28 2009 -0600
@@ -1,13 +1,14 @@
 CONFIG_MIPS_MALTA=y
-CONFIG_SWAP=y
 CONFIG_CPU_MIPS32_R2=y
-CONFIG_MIPS_MT_SMP=y
-CONFIG_MIPS_MT_FPAFF=y
+CONFIG_UNEVICTABLE_LRU=y
 CONFIG_NO_HZ=y
 CONFIG_HIGH_RES_TIMERS=y
 CONFIG_HZ_100=y
 CONFIG_EXPERIMENTAL=y
+CONFIG_SWAP=y
 CONFIG_SYSVIPC=y
+CONFIG_CC_OPTIMIZE_FOR_SIZE=y
+CONFIG_SYSCTL_SYSCALL=y
 CONFIG_HOTPLUG=y
 CONFIG_PRINTK=y
 CONFIG_BUG=y
@@ -20,9 +21,8 @@
 CONFIG_TIMERFD=y
 CONFIG_EVENTFD=y
 CONFIG_SHMEM=y
-CONFIG_VM_EVENT_COUNTERS=y
-CONFIG_SLAB=y
-CONFIG_PROC_PAGE_MONITOR=y
+CONFIG_AIO=y
+CONFIG_PCI_QUIRKS=y
 CONFIG_BLOCK=y
 CONFIG_PCI=y
 CONFIG_BINFMT_ELF=y
@@ -32,38 +32,32 @@
 CONFIG_PACKET_MMAP=y
 CONFIG_UNIX=y
 CONFIG_INET=y
-CONFIG_CONNECTOR=y
-CONFIG_PROC_EVENTS=y
 CONFIG_BLK_DEV=y
 CONFIG_BLK_DEV_LOOP=y
 CONFIG_IDE=y
-CONFIG_BLK_DEV_IDE=y
-CONFIG_BLK_DEV_IDEDISK=y
-CONFIG_IDE_GENERIC=y
-CONFIG_IDEPCI_PCIBUS_ORDER=y
+CONFIG_IDE_GD=y
+CONFIG_IDE_GD_ATA=y
 CONFIG_BLK_DEV_GENERIC=y
+CONFIG_BLK_DEV_PIIX=y
 CONFIG_NETDEVICES=y
 CONFIG_NET_ETHERNET=y
-CONFIG_AX88796=y
 CONFIG_NET_PCI=y
 CONFIG_PCNET32=y
-CONFIG_NE2K_PCI=y
 CONFIG_8139CP=y
-CONFIG_SERIO=y
-CONFIG_SERIO_SERPORT=y
 CONFIG_SERIAL_8250=y
 CONFIG_SERIAL_8250_CONSOLE=y
 CONFIG_SERIAL_8250_PCI=y
 CONFIG_UNIX98_PTYS=y
-CONFIG_RTC=y
+CONFIG_LEGACY_PTYS=y
+CONFIG_LEGACY_PTY_COUNT=8
+CONFIG_HW_RANDOM=y
 CONFIG_EXT2_FS=y
 CONFIG_EXT3_FS=y
 CONFIG_DNOTIFY=y
 CONFIG_INOTIFY=y
 CONFIG_INOTIFY_USER=y
 CONFIG_PROC_FS=y
-CONFIG_PROC_KCORE=y
 CONFIG_PROC_SYSCTL=y
+CONFIG_PROC_PAGE_MONITOR=y
 CONFIG_SYSFS=y
 CONFIG_TMPFS=y
-CONFIG_EXT3_FS=y
--- a/sources/targets/mipsel/miniconfig-linux	Sun Feb 01 16:45:51 2009 -0600
+++ b/sources/targets/mipsel/miniconfig-linux	Sun Feb 01 17:36:28 2009 -0600
@@ -1,14 +1,15 @@
+CONFIG_MIPS_MALTA=y
 CONFIG_CPU_LITTLE_ENDIAN=y
-CONFIG_SWAP=y
-CONFIG_MIPS_MALTA=y
 CONFIG_CPU_MIPS32_R2=y
-CONFIG_MIPS_MT_SMP=y
-CONFIG_MIPS_MT_FPAFF=y
+CONFIG_UNEVICTABLE_LRU=y
 CONFIG_NO_HZ=y
 CONFIG_HIGH_RES_TIMERS=y
 CONFIG_HZ_100=y
 CONFIG_EXPERIMENTAL=y
+CONFIG_SWAP=y
 CONFIG_SYSVIPC=y
+CONFIG_CC_OPTIMIZE_FOR_SIZE=y
+CONFIG_SYSCTL_SYSCALL=y
 CONFIG_HOTPLUG=y
 CONFIG_PRINTK=y
 CONFIG_BUG=y
@@ -21,9 +22,8 @@
 CONFIG_TIMERFD=y
 CONFIG_EVENTFD=y
 CONFIG_SHMEM=y
-CONFIG_VM_EVENT_COUNTERS=y
-CONFIG_SLAB=y
-CONFIG_PROC_PAGE_MONITOR=y
+CONFIG_AIO=y
+CONFIG_PCI_QUIRKS=y
 CONFIG_BLOCK=y
 CONFIG_PCI=y
 CONFIG_BINFMT_ELF=y
@@ -33,38 +33,32 @@
 CONFIG_PACKET_MMAP=y
 CONFIG_UNIX=y
 CONFIG_INET=y
-CONFIG_CONNECTOR=y
-CONFIG_PROC_EVENTS=y
 CONFIG_BLK_DEV=y
 CONFIG_BLK_DEV_LOOP=y
 CONFIG_IDE=y
-CONFIG_BLK_DEV_IDE=y
-CONFIG_BLK_DEV_IDEDISK=y
-CONFIG_IDE_GENERIC=y
-CONFIG_IDEPCI_PCIBUS_ORDER=y
+CONFIG_IDE_GD=y
+CONFIG_IDE_GD_ATA=y
 CONFIG_BLK_DEV_GENERIC=y
+CONFIG_BLK_DEV_PIIX=y
 CONFIG_NETDEVICES=y
 CONFIG_NET_ETHERNET=y
-CONFIG_AX88796=y
 CONFIG_NET_PCI=y
 CONFIG_PCNET32=y
-CONFIG_NE2K_PCI=y
 CONFIG_8139CP=y
-CONFIG_SERIO=y
-CONFIG_SERIO_SERPORT=y
 CONFIG_SERIAL_8250=y
 CONFIG_SERIAL_8250_CONSOLE=y
 CONFIG_SERIAL_8250_PCI=y
 CONFIG_UNIX98_PTYS=y
-CONFIG_RTC=y
+CONFIG_LEGACY_PTYS=y
+CONFIG_LEGACY_PTY_COUNT=8
+CONFIG_HW_RANDOM=y
 CONFIG_EXT2_FS=y
 CONFIG_EXT3_FS=y
 CONFIG_DNOTIFY=y
 CONFIG_INOTIFY=y
 CONFIG_INOTIFY_USER=y
 CONFIG_PROC_FS=y
-CONFIG_PROC_KCORE=y
 CONFIG_PROC_SYSCTL=y
+CONFIG_PROC_PAGE_MONITOR=y
 CONFIG_SYSFS=y
 CONFIG_TMPFS=y
-CONFIG_EXT3_FS=y
--- a/sources/targets/powerpc/details	Sun Feb 01 16:45:51 2009 -0600
+++ b/sources/targets/powerpc/details	Sun Feb 01 17:36:28 2009 -0600
@@ -11,5 +11,5 @@
 
 emulator_command()
 {
-  echo qemu-system-ppc -M prep $(qemu_defaults "$@") -L .
+  echo qemu-system-ppc -M g3beige $(qemu_defaults "$@")
 }
--- a/sources/targets/powerpc/miniconfig-linux	Sun Feb 01 16:45:51 2009 -0600
+++ b/sources/targets/powerpc/miniconfig-linux	Sun Feb 01 17:36:28 2009 -0600
@@ -1,35 +1,112 @@
+CONFIG_ALTIVEC=y
+CONFIG_EXPERIMENTAL=y
 CONFIG_SWAP=y
-CONFIG_IKCONFIG=y
-CONFIG_IKCONFIG_PROC=y
-CONFIG_LSF=y
-CONFIG_PPC_QEMU=y
+CONFIG_SYSVIPC=y
+CONFIG_SYSFS_DEPRECATED_V2=y
+CONFIG_BLK_DEV_INITRD=y
+CONFIG_COMPAT_BRK=y
+CONFIG_SLAB=y
+CONFIG_PPC_PMAC=y
+CONFIG_PPC601_SYNC_FIX=y
+CONFIG_HIGHMEM=y
+CONFIG_NO_HZ=y
 CONFIG_BINFMT_ELF=y
+CONFIG_UNEVICTABLE_LRU=y
+CONFIG_PROC_DEVICETREE=y
 CONFIG_PM=y
-CONFIG_ISA=y
+CONFIG_SECCOMP=y
+CONFIG_PCCARD=y
+CONFIG_PCMCIA=y
+CONFIG_PCMCIA_LOAD_CIS=y
+CONFIG_PCMCIA_IOCTL=y
+CONFIG_YENTA=y
+CONFIG_ADVANCED_OPTIONS=y
 CONFIG_NET=y
 CONFIG_PACKET=y
+CONFIG_PACKET_MMAP=y
 CONFIG_UNIX=y
 CONFIG_INET=y
+CONFIG_INET_LRO=y
+CONFIG_PREVENT_FIRMWARE_BUILD=y
+CONFIG_FIRMWARE_IN_KERNEL=y
+CONFIG_CONNECTOR=y
+CONFIG_PROC_EVENTS=y
 CONFIG_BLK_DEV=y
 CONFIG_BLK_DEV_LOOP=y
 CONFIG_IDE=y
-CONFIG_BLK_DEV_IDE=y
-CONFIG_BLK_DEV_IDEDISK=y
-CONFIG_IDE_GENERIC=y
+CONFIG_IDE_GD=y
+CONFIG_IDE_GD_ATA=y
 CONFIG_BLK_DEV_GENERIC=y
+CONFIG_BLK_DEV_CMD64X=y
+CONFIG_BLK_DEV_IDE_PMAC=y
+CONFIG_IEEE1394=y
+CONFIG_IEEE1394_OHCI1394=y
+CONFIG_IEEE1394_ETH1394=y
+CONFIG_IEEE1394_RAWIO=y
+CONFIG_IEEE1394_VIDEO1394=y
+CONFIG_IEEE1394_DV1394=y
+CONFIG_MACINTOSH_DRIVERS=y
+CONFIG_ADB=y
+CONFIG_ADB_CUDA=y
+CONFIG_ADB_PMU=y
 CONFIG_NETDEVICES=y
 CONFIG_NET_ETHERNET=y
-CONFIG_MII=y
-CONFIG_NET_ISA=y
-CONFIG_NE2000=y
+CONFIG_MACE=y
+CONFIG_BMAC=y
+CONFIG_HAPPYMEAL=y
+CONFIG_SUNGEM=y
+CONFIG_CASSINI=y
+CONFIG_NET_PCI=y
+CONFIG_PCNET32=y
+CONFIG_NE2K_PCI=y
+CONFIG_8139CP=y
+CONFIG_8139TOO=y
+CONFIG_8139TOO_PIO=y
+CONFIG_ATL2=y
+CONFIG_INPUT_FF_MEMLESS=y
+CONFIG_SERIO=y
 CONFIG_SERIAL_8250=y
-CONFIG_SERIAL_8250_CONSOLE=y
+CONFIG_SERIAL_PMACZILOG=y
+CONFIG_SERIAL_PMACZILOG_TTYS=y
+CONFIG_SERIAL_PMACZILOG_CONSOLE=y
+CONFIG_LEGACY_PTYS=y
+CONFIG_LEGACY_PTY_COUNT=8
+CONFIG_HW_RANDOM=y
+CONFIG_I2C=y
+CONFIG_I2C_POWERMAC=y
+CONFIG_SSB=y
+CONFIG_SSB_PCIHOST=y
+CONFIG_SSB_PCMCIAHOST=y
+CONFIG_SSB_DRIVER_PCICORE=y
+CONFIG_MFD_WM8400=y
+CONFIG_MFD_WM8350_I2C=y
 CONFIG_RTC_CLASS=y
 CONFIG_RTC_HCTOSYS=y
 CONFIG_RTC_INTF_SYSFS=y
 CONFIG_RTC_INTF_PROC=y
 CONFIG_RTC_INTF_DEV=y
-CONFIG_RTC_DRV_CMOS=y
+CONFIG_RTC_DRV_TEST=y
+CONFIG_RTC_DRV_DS1307=y
+CONFIG_RTC_DRV_DS1672=y
+CONFIG_RTC_DRV_RS5C372=y
+CONFIG_RTC_DRV_ISL1208=y
+CONFIG_RTC_DRV_X1205=y
+CONFIG_RTC_DRV_PCF8563=y
+CONFIG_RTC_DRV_RX8581=y
+CONFIG_RTC_DRV_DS1286=y
+CONFIG_RTC_DRV_DS1553=y
+CONFIG_RTC_DRV_DS1742=y
+CONFIG_RTC_DRV_M48T86=y
+CONFIG_RTC_DRV_M48T35=y
+CONFIG_RTC_DRV_BQ4802=y
+CONFIG_RTC_DRV_V3020=y
+CONFIG_RTC_DRV_WM8350=y
 CONFIG_EXT2_FS=y
 CONFIG_EXT3_FS=y
-CONFIG_EXT3_FS=y
+CONFIG_DNOTIFY=y
+CONFIG_INOTIFY=y
+CONFIG_INOTIFY_USER=y
+CONFIG_PROC_KCORE=y
+CONFIG_TMPFS=y
+CONFIG_LIBCRC32C=y
+CONFIG_BOOTX_TEXT=y
--- a/sources/targets/x86_64/miniconfig-linux	Sun Feb 01 16:45:51 2009 -0600
+++ b/sources/targets/x86_64/miniconfig-linux	Sun Feb 01 17:36:28 2009 -0600
@@ -2,11 +2,10 @@
 CONFIG_SYSVIPC=y
 CONFIG_IKCONFIG=y
 CONFIG_IKCONFIG_PROC=y
+CONFIG_BLK_DEV_INITRD=y
 CONFIG_KALLSYMS_EXTRA_PASS=y
-CONFIG_REORDER=y
 CONFIG_PM=y
 CONFIG_ACPI=y
-CONFIG_ACPI_SLEEP=y
 CONFIG_PCI=y
 CONFIG_HT_IRQ=y
 CONFIG_BINFMT_ELF=y
@@ -17,19 +16,20 @@
 CONFIG_INET=y
 CONFIG_BLK_DEV=y
 CONFIG_BLK_DEV_LOOP=y
-CONFIG_BLK_DEV_INITRD=y
 CONFIG_IDE=y
-CONFIG_BLK_DEV_IDE=y
-CONFIG_BLK_DEV_IDEDISK=y
+CONFIG_IDE_GD=y
+CONFIG_IDE_GD_ATA=y
 CONFIG_IDE_GENERIC=y
+CONFIG_IDEPCI_PCIBUS_ORDER=y
+CONFIG_BLK_DEV_PIIX=y
 CONFIG_NETDEVICES=y
 CONFIG_NET_ETHERNET=y
 CONFIG_NET_PCI=y
 CONFIG_NE2K_PCI=y
+CONFIG_8139TOO=y
 CONFIG_SERIO_SERPORT=y
 CONFIG_SERIAL_8250=y
 CONFIG_SERIAL_8250_CONSOLE=y
 CONFIG_EXT2_FS=y
+CONFIG_EXT3_FS=y
 CONFIG_TMPFS=y
-CONFIG_SQUASHFS=y
-CONFIG_EXT3_FS=y