diff options
Diffstat (limited to 'packages')
5 files changed, 126 insertions, 24 deletions
diff --git a/packages/linux/nas100d-kernel/2.6.15/00-memory-h-page-shift.patch b/packages/linux/nas100d-kernel/2.6.15/00-memory-h-page-shift.patch index 4ec8f0475f..30d34952d5 100644 --- a/packages/linux/nas100d-kernel/2.6.15/00-memory-h-page-shift.patch +++ b/packages/linux/nas100d-kernel/2.6.15/00-memory-h-page-shift.patch @@ -1,3 +1,26 @@ +http://www.arm.linux.org.uk/developer/patches/viewpatch.php?id=3218/1 + +PAGE_SHIFT is undeclared in include/asm-arm/arch-ixp4xx/memory.h, identified by the following kernel compilation error: + +CC [M] sound/core/memory.o +In file included from include/asm/memory.h:27, +from include/asm/io.h:28, +from sound/core/memory.c:24: +include/asm/arch/memory.h: In function `__arch_adjust_zones': +include/asm/arch/memory.h:28: error: `PAGE_SHIFT' undeclared (first use +in this function) + +This patch replaces my previous attempt at fixing this problem (Patch 3214/1) and is based on the following feedback: + +Russell King wrote: +> The error you see came up on SA1100. The best solution was to move +> the __arch_adjust_zones() function out of line. I suggest ixp4xx +> does the same. + +I have moved the function out of line into arch/arm/mach-ixp4xx/common-pci.c as suggested. + +Signed-off-by: Rod Whitby <rod@whitby.id.au> + --- linux-2.6.15-rc7/include/asm-arm/arch-ixp4xx/memory.h~ 2005-12-30 05:18:27.000000000 +1030 +++ linux-2.6.15-rc7/include/asm-arm/arch-ixp4xx/memory.h 2005-12-30 05:36:04.000000000 +1030 @@ -16,31 +16,10 @@ diff --git a/packages/linux/nas100d-kernel/2.6.15/10-mtdpart-redboot-fis-byteswap.patch b/packages/linux/nas100d-kernel/2.6.15/10-mtdpart-redboot-fis-byteswap.patch index edee083e3c..3fa0535abf 100644 --- a/packages/linux/nas100d-kernel/2.6.15/10-mtdpart-redboot-fis-byteswap.patch +++ b/packages/linux/nas100d-kernel/2.6.15/10-mtdpart-redboot-fis-byteswap.patch @@ -1,12 +1,38 @@ -On IXP4XX systems the FIS directory is big endian even with a little -endian kernel. This patch recognises the FIS directory on such a -system and byte swaps it to obtain a valid table based on the 'size' -field of the FIS directory (the size field is know to always match the -erase block size on such systems, and probably all systems.) +drivers/mtd/redboot.c: recognise a foreign byte sex partition table +The RedBoot boot loader writes flash partition tables containing native +byte sex 32 bit values. When booting an opposite byte sex kernel (e.g. an +LE kernel from BE RedBoot) the current MTD driver fails to handle the +partition table and therefore is unable to generate the correct partition +map for the flash. + +The patch recognises that the FIS directory (the partition table) is +byte-reversed by examining the partition table size, which is known to be +one erase block (this is an assumption made elsewhere in redboot.c). If +the size matches the erase block after byte swapping the value then +byte-reversal is assumed, if not no further action is taken. The patched +code is fail safe; should redboot.c be changed to support a partition table +with a modified size field the test will fail and the partition table will +be assumed to have the host byte sex. + +If byte-reversal is detected the patch byte swaps the remainder of the 32 +bit fields in the copy of the table; this copy is then used to set up the +MTD partition map. + +Signed-off-by: John Bowler <jbowler@acm.org> +Signed-off-by: Andrew Morton <akpm@osdl.org> +Modified slightly and +Signed-off-by: David Woodhouse <dwmw2@infradead.org> + +Index: drivers/mtd/redboot.c +=================================================================== +RCS file: /home/cvs/mtd/drivers/mtd/redboot.c,v +retrieving revision 1.18 +retrieving revision 1.19 +diff -u -p -r1.18 -r1.19 --- linux-2.6.15/drivers/mtd/redboot.c 1970-01-01 00:00:00.000000000 +0000 +++ linux-2.6.15/drivers/mtd/redboot.c 1970-01-01 00:00:00.000000000 +0000 -@@ -89,8 +89,34 @@ +@@ -89,8 +89,32 @@ static int parse_redboot_partitions(stru i = numslots; break; } @@ -14,10 +40,10 @@ erase block size on such systems, and probably all systems.) + if (!memcmp(buf[i].name, "FIS directory", 14)) { + /* This is apparently the FIS directory entry for the + * FIS directory itself. The FIS directory size is -+ * one erase block, if the buf[i].size field is ++ * one erase block; if the buf[i].size field is + * swab32(erasesize) then we know we are looking at + * a byte swapped FIS directory - swap all the entries! -+ * (NOTE: this is 'size' not 'data_length', size is ++ * (NOTE: this is 'size' not 'data_length'; size is + * the full size of the entry.) + */ + if (swab32(buf[i].size) == master->erasesize) { @@ -26,15 +52,13 @@ erase block size on such systems, and probably all systems.) + /* The unsigned long fields were written with the + * wrong byte sex, name and pad have no byte sex. + */ -+# define do_swab32(x) (x) = swab32(x) -+ do_swab32(buf[j].flash_base); -+ do_swab32(buf[j].mem_base); -+ do_swab32(buf[j].size); -+ do_swab32(buf[j].entry_point); -+ do_swab32(buf[j].data_length); -+ do_swab32(buf[j].desc_cksum); -+ do_swab32(buf[j].file_cksum); -+# undef do_swab32 ++ swab32s(&buf[j].flash_base); ++ swab32s(&buf[j].mem_base); ++ swab32s(&buf[j].size); ++ swab32s(&buf[j].entry_point); ++ swab32s(&buf[j].data_length); ++ swab32s(&buf[j].desc_cksum); ++ swab32s(&buf[j].file_cksum); + } + } break; @@ -42,3 +66,5 @@ erase block size on such systems, and probably all systems.) } if (i == numslots) { /* Didn't find it */ + + diff --git a/packages/linux/nas100d-kernel/2.6.15/50-nas100d-arch.patch b/packages/linux/nas100d-kernel/2.6.15/50-nas100d-arch.patch index 028e50455a..cb3eac2433 100644 --- a/packages/linux/nas100d-kernel/2.6.15/50-nas100d-arch.patch +++ b/packages/linux/nas100d-kernel/2.6.15/50-nas100d-arch.patch @@ -1,3 +1,40 @@ +http://www.arm.linux.org.uk/developer/patches/viewpatch.php?id=3215/1 + +Iomega NAS 100d (MACH_NAS100D) machine support + +This patch adds support for a new arm/ixp4xx machine - the Iomega NAS +100d network attached storage product. The NAS100D is a consumer +device containing a 266MHz Intel IXP420 processor, 16MB of flash, 64MB +of RAM, a 160Gb internal IDE hard disk, and 802.11b/g wireless on an +Atheros mini-PCI card. + +Work on porting the latest 2.6.x kernel to this device is being done by +the NSLU2-Linux project (the same team who maintains the port to the +Linksys NSLU2 device). In particular, the majority of this patch was +authored by Alessandro Zummo, based on the work done for MACH_NSLU2 +support by the NSLU2-Linux core team of developers. + +MACH_NAS100D (as implemented by this patch) can be enabled in jumbo +ixp4xx kernels without any affect on the other machines supported by +that kernel. + +This patch applies cleanly against 2.6.15-rc7 and should be trivial to +apply to later kernel versions. It does not depend upon any other +patches. + +Modified files (and number of lines inserted): +arch/arm/mach-ixp4xx/Kconfig | 8 +arch/arm/mach-ixp4xx/Makefile | 1 +include/asm-arm/arch-ixp4xx/hardware.h | 1 +include/asm-arm/arch-ixp4xx/irqs.h | 9 +include/asm-arm/arch-ixp4xx/nas100d.h | 75 +arch/arm/mach-ixp4xx/nas100d-pci.c | 77 +arch/arm/mach-ixp4xx/nas100d-power.c | 69 +arch/arm/mach-ixp4xx/nas100d-setup.c | 133 + +Signed-off-by: Rod Whitby <rod@whitby.id.au> +Signed-off-by: Alessandro Zummo <a.zummo@towertech.it> + --- linux-2.6.15-rc7/arch/arm/mach-ixp4xx/Kconfig 2005-12-27 22:29:00.000000000 +0100 +++ linux-2.6.15-rc7/arch/arm/mach-ixp4xx/Kconfig 2005-12-27 22:29:52.000000000 +0100 @@ -71,6 +71,14 @@ config ARCH_PRPMC1100 diff --git a/packages/linux/nslu2-kernel/2.6.15/00-memory-h-page-shift.patch b/packages/linux/nslu2-kernel/2.6.15/00-memory-h-page-shift.patch index 4ec8f0475f..30d34952d5 100644 --- a/packages/linux/nslu2-kernel/2.6.15/00-memory-h-page-shift.patch +++ b/packages/linux/nslu2-kernel/2.6.15/00-memory-h-page-shift.patch @@ -1,3 +1,26 @@ +http://www.arm.linux.org.uk/developer/patches/viewpatch.php?id=3218/1 + +PAGE_SHIFT is undeclared in include/asm-arm/arch-ixp4xx/memory.h, identified by the following kernel compilation error: + +CC [M] sound/core/memory.o +In file included from include/asm/memory.h:27, +from include/asm/io.h:28, +from sound/core/memory.c:24: +include/asm/arch/memory.h: In function `__arch_adjust_zones': +include/asm/arch/memory.h:28: error: `PAGE_SHIFT' undeclared (first use +in this function) + +This patch replaces my previous attempt at fixing this problem (Patch 3214/1) and is based on the following feedback: + +Russell King wrote: +> The error you see came up on SA1100. The best solution was to move +> the __arch_adjust_zones() function out of line. I suggest ixp4xx +> does the same. + +I have moved the function out of line into arch/arm/mach-ixp4xx/common-pci.c as suggested. + +Signed-off-by: Rod Whitby <rod@whitby.id.au> + --- linux-2.6.15-rc7/include/asm-arm/arch-ixp4xx/memory.h~ 2005-12-30 05:18:27.000000000 +1030 +++ linux-2.6.15-rc7/include/asm-arm/arch-ixp4xx/memory.h 2005-12-30 05:36:04.000000000 +1030 @@ -16,31 +16,10 @@ diff --git a/packages/linux/nslu2-kernel/2.6.15/10-mtdpart-redboot-fis-byteswap.patch b/packages/linux/nslu2-kernel/2.6.15/10-mtdpart-redboot-fis-byteswap.patch index 077aa00816..3fa0535abf 100644 --- a/packages/linux/nslu2-kernel/2.6.15/10-mtdpart-redboot-fis-byteswap.patch +++ b/packages/linux/nslu2-kernel/2.6.15/10-mtdpart-redboot-fis-byteswap.patch @@ -32,13 +32,6 @@ retrieving revision 1.19 diff -u -p -r1.18 -r1.19 --- linux-2.6.15/drivers/mtd/redboot.c 1970-01-01 00:00:00.000000000 +0000 +++ linux-2.6.15/drivers/mtd/redboot.c 1970-01-01 00:00:00.000000000 +0000 -@@ -1,5 +1,5 @@ - /* -- * $Id: redboot.c,v 1.18 2005/11/07 11:14:21 gleixner Exp $ -+ * $Id: redboot.c,v 1.19 2005/12/01 10:03:51 dwmw2 Exp $ - * - * Parse RedBoot-style Flash Image System (FIS) tables and - * produce a Linux partition array to match. @@ -89,8 +89,32 @@ static int parse_redboot_partitions(stru i = numslots; break; |