r2594 - in trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches: . series

Sven Luther luther@costa.debian.org
Fri, 04 Mar 2005 10:48:10 +0100


Author: luther
Date: 2005-03-04 10:48:09 +0100 (Fri, 04 Mar 2005)
New Revision: 2594

Added:
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/007-pci_ide_no_reserve.dpatch
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/035-do_brk_security_fixes.dpatch
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/036-rlimit_memlock_check.dpatch
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/modular-ide.dpatch
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/modular-vesafb.dpatch
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/smbfs-overflow-fixes.dpatch
Removed:
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/007-pci_ide_no_reserve-2.dpatch
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/035-do_brk_security_fixes-2.dpatch
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/036-rlimit_memlock_check-2.dpatch
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/modular-ide-2.dpatch
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/modular-vesafb-2.dpatch
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/powerpc-pegasos-via82cxxx.dpatch
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/powerpc-pegasos.dpatch
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-1
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-2
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-3
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-4
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-5
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-6
   trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/smbfs-overflow-fixes-2.dpatch
Log:
Further cleanup.


Deleted: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/007-pci_ide_no_reserve-2.dpatch
===================================================================
--- trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/007-pci_ide_no_reserve-2.dpatch	2005-03-04 09:44:49 UTC (rev 2593)
+++ trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/007-pci_ide_no_reserve-2.dpatch	2005-03-04 09:48:09 UTC (rev 2594)
@@ -1,69 +0,0 @@
-#! /bin/sh -e
-## <PATCHNAME>.dpatch by <PATCH_AUTHOR@EMAI>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: Description: [ide] fix return codes in the generic PCI IDE driver
-## DP: Patch author: bzolnier@trik.(none)
-## DP: Upstream status: backported
-
-. $(dirname $0)/DPATCH
-
-@DPATCH@
-# This is a BitKeeper generated diff -Nru style patch.
-#
-# ChangeSet
-#   2004/12/30 19:07:00+01:00 bzolnier@trik.(none) 
-#   [ide] fix return codes in the generic PCI IDE driver
-#   
-#   From: Alan Cox <alan@redhat.com>
-#   
-#   This patch updates ide/pci/generic.c to fix the incorrect returns
-#   causing PCI devices to be left reserved wrongly by the driver.
-#   
-#   From: Francois Romieu <romieu@fr.zoreil.com>
-#   
-#   Use -ENODEV instead of -EAGAIN.
-#   
-#   Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
-# 
-# drivers/ide/pci/generic.c
-#   2004/12/30 19:06:50+01:00 bzolnier@trik.(none) +8 -6
-#   [ide] fix return codes in the generic PCI IDE driver
-# 
-diff -Nru a/drivers/ide/pci/generic.c b/drivers/ide/pci/generic.c
---- a/drivers/ide/pci/generic.c	2005-01-04 18:06:08 -08:00
-+++ b/drivers/ide/pci/generic.c	2005-01-04 18:06:08 -08:00
-@@ -96,25 +96,27 @@
- {
- 	ide_pci_device_t *d = &generic_chipsets[id->driver_data];
- 	u16 command;
-+	int ret = -ENODEV;
- 
- 	if (dev->vendor == PCI_VENDOR_ID_UMC &&
- 	    dev->device == PCI_DEVICE_ID_UMC_UM8886A &&
- 	    (!(PCI_FUNC(dev->devfn) & 1)))
--		return 1; /* UM8886A/BF pair */
-+		goto out; /* UM8886A/BF pair */
- 
- 	if (dev->vendor == PCI_VENDOR_ID_OPTI &&
- 	    dev->device == PCI_DEVICE_ID_OPTI_82C558 &&
- 	    (!(PCI_FUNC(dev->devfn) & 1)))
--		return 1;
-+		goto out;
- 
- 	pci_read_config_word(dev, PCI_COMMAND, &command);
--	if(!(command & PCI_COMMAND_IO))
--	{
-+	if (!(command & PCI_COMMAND_IO)) {
- 		printk(KERN_INFO "Skipping disabled %s IDE controller.\n", d->name);
--		return 1; 
-+		goto out;
- 	}
-+	ret = 0;
- 	ide_setup_pci_device(dev, d);
--	return 0;
-+out:
-+	return ret;
- }
- 
- static struct pci_device_id generic_pci_tbl[] = {

Copied: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/007-pci_ide_no_reserve.dpatch (from rev 2592, trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/007-pci_ide_no_reserve-2.dpatch)

Deleted: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/035-do_brk_security_fixes-2.dpatch
===================================================================
--- trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/035-do_brk_security_fixes-2.dpatch	2005-03-04 09:44:49 UTC (rev 2593)
+++ trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/035-do_brk_security_fixes-2.dpatch	2005-03-04 09:48:09 UTC (rev 2594)
@@ -1,334 +0,0 @@
-#! /bin/sh -e
-## <PATCHNAME>.dpatch by <PATCH_AUTHOR@EMAI>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: Description: [PATCH] do_brk() needs mmap_sem write-locked
-## DP: Patch author: marcelo.tosatti@cyclades.com
-## DP: Upstream status: backported
-
-. $(dirname $0)/DPATCH
-
-@DPATCH@
-# This is a BitKeeper generated diff -Nru style patch.
-#
-# ChangeSet
-#   2005/01/12 08:12:09-08:00 marcelo.tosatti@cyclades.com 
-#   [PATCH] do_brk() needs mmap_sem write-locked
-#   
-#   It seems to be general consensus that its safer to require all do_brk() callers
-#   to grab mmap_sem, and have do_brk to warn otherwise. This is what the following
-#   patch does.
-#   
-#   Similar version has been changed to in v2.4.
-#   
-#   Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-# 
-# arch/mips/kernel/irixelf.c
-#   2005/01/11 17:35:36-08:00 marcelo.tosatti@cyclades.com +10 -1
-#   do_brk() needs mmap_sem write-locked
-# 
-# arch/sparc64/kernel/binfmt_aout32.c
-#   2005/01/11 17:37:28-08:00 marcelo.tosatti@cyclades.com +12 -0
-#   do_brk() needs mmap_sem write-locked
-# 
-# arch/x86_64/ia32/ia32_aout.c
-#   2005/01/11 17:34:26-08:00 marcelo.tosatti@cyclades.com +11 -1
-#   do_brk() needs mmap_sem write-locked
-# 
-# fs/binfmt_aout.c
-#   2005/01/11 17:31:51-08:00 marcelo.tosatti@cyclades.com +14 -3
-#   do_brk() needs mmap_sem write-locked
-# 
-# fs/binfmt_elf.c
-#   2005/01/11 18:07:01-08:00 marcelo.tosatti@cyclades.com +11 -1
-#   do_brk() needs mmap_sem write-locked
-# 
-# mm/mmap.c
-#   2005/01/11 17:43:11-08:00 marcelo.tosatti@cyclades.com +6 -0
-#   do_brk() needs mmap_sem write-locked
-# 
-diff -Nru a/arch/mips/kernel/irixelf.c b/arch/mips/kernel/irixelf.c
---- a/arch/mips/kernel/irixelf.c	2005-01-12 20:26:27 -08:00
-+++ b/arch/mips/kernel/irixelf.c	2005-01-12 20:26:27 -08:00
-@@ -127,7 +127,9 @@
- 	end = PAGE_ALIGN(end);
- 	if (end <= start)
- 		return;
-+	down_write(&current->mm->mmap_sem);
- 	do_brk(start, end - start);
-+	up_write(&current->mm->mmap_sem);
- }
- 
- 
-@@ -375,7 +377,9 @@
- 
- 	/* Map the last of the bss segment */
- 	if (last_bss > len) {
-+		down_write(&current->mm->mmap_sem);
- 		do_brk(len, (last_bss - len));
-+		up_write(&current->mm->mmap_sem);
- 	}
- 	kfree(elf_phdata);
- 
-@@ -562,7 +566,9 @@
- 	unsigned long v;
- 	struct prda *pp;
- 
-+	down_write(&current->mm->mmap_sem);
- 	v =  do_brk (PRDA_ADDRESS, PAGE_SIZE);
-+	up_write(&current->mm->mmap_sem);
- 
- 	if (v < 0)
- 		return;
-@@ -852,8 +858,11 @@
- 
- 	len = (elf_phdata->p_filesz + elf_phdata->p_vaddr+ 0xfff) & 0xfffff000;
- 	bss = elf_phdata->p_memsz + elf_phdata->p_vaddr;
--	if (bss > len)
-+	if (bss > len) {
-+	  down_write(&current->mm->mmap_sem);
- 	  do_brk(len, bss-len);
-+	  up_write(&current->mm->mmap_sem);
-+	}
- 	kfree(elf_phdata);
- 	return 0;
- }
-diff -Nru a/arch/sparc64/kernel/binfmt_aout32.c b/arch/sparc64/kernel/binfmt_aout32.c
---- a/arch/sparc64/kernel/binfmt_aout32.c	2005-01-12 20:26:27 -08:00
-+++ b/arch/sparc64/kernel/binfmt_aout32.c	2005-01-12 20:26:27 -08:00
-@@ -49,7 +49,9 @@
- 	end = PAGE_ALIGN(end);
- 	if (end <= start)
- 		return;
-+	down_write(&current->mm->mmap_sem);
- 	do_brk(start, end - start);
-+	up_write(&current->mm->mmap_sem);
- }
- 
- /*
-@@ -246,10 +248,14 @@
- 	if (N_MAGIC(ex) == NMAGIC) {
- 		loff_t pos = fd_offset;
- 		/* Fuck me plenty... */
-+		down_write(&current->mm->mmap_sem);	
- 		error = do_brk(N_TXTADDR(ex), ex.a_text);
-+		up_write(&current->mm->mmap_sem);
- 		bprm->file->f_op->read(bprm->file, (char __user *)N_TXTADDR(ex),
- 			  ex.a_text, &pos);
-+		down_write(&current->mm->mmap_sem);
- 		error = do_brk(N_DATADDR(ex), ex.a_data);
-+		up_write(&current->mm->mmap_sem);
- 		bprm->file->f_op->read(bprm->file, (char __user *)N_DATADDR(ex),
- 			  ex.a_data, &pos);
- 		goto beyond_if;
-@@ -257,8 +263,10 @@
- 
- 	if (N_MAGIC(ex) == OMAGIC) {
- 		loff_t pos = fd_offset;
-+		down_write(&current->mm->mmap_sem);
- 		do_brk(N_TXTADDR(ex) & PAGE_MASK,
- 			ex.a_text+ex.a_data + PAGE_SIZE - 1);
-+		up_write(&current->mm->mmap_sem);
- 		bprm->file->f_op->read(bprm->file, (char __user *)N_TXTADDR(ex),
- 			  ex.a_text+ex.a_data, &pos);
- 	} else {
-@@ -272,7 +280,9 @@
- 
- 		if (!bprm->file->f_op->mmap) {
- 			loff_t pos = fd_offset;
-+			down_write(&current->mm->mmap_sem);
- 			do_brk(0, ex.a_text+ex.a_data);
-+			up_write(&current->mm->mmap_sem);
- 			bprm->file->f_op->read(bprm->file,
- 				  (char __user *)N_TXTADDR(ex),
- 				  ex.a_text+ex.a_data, &pos);
-@@ -389,7 +399,9 @@
- 	len = PAGE_ALIGN(ex.a_text + ex.a_data);
- 	bss = ex.a_text + ex.a_data + ex.a_bss;
- 	if (bss > len) {
-+		down_write(&current->mm->mmap_sem);
- 		error = do_brk(start_addr + len, bss - len);
-+		up_write(&current->mm->mmap_sem);
- 		retval = error;
- 		if (error != start_addr + len)
- 			goto out;
-diff -Nru a/arch/x86_64/ia32/ia32_aout.c b/arch/x86_64/ia32/ia32_aout.c
---- a/arch/x86_64/ia32/ia32_aout.c	2005-01-12 20:26:27 -08:00
-+++ b/arch/x86_64/ia32/ia32_aout.c	2005-01-12 20:26:27 -08:00
-@@ -115,7 +115,9 @@
- 	end = PAGE_ALIGN(end);
- 	if (end <= start)
- 		return;
-+	down_write(&current->mm->mmap_sem);
- 	do_brk(start, end - start);
-+	up_write(&current->mm->mmap_sem);
- }
- 
- #if CORE_DUMP
-@@ -325,7 +327,10 @@
- 		pos = 32;
- 		map_size = ex.a_text+ex.a_data;
- 
-+		down_write(&current->mm->mmap_sem);
- 		error = do_brk(text_addr & PAGE_MASK, map_size);
-+		up_write(&current->mm->mmap_sem);
-+
- 		if (error != (text_addr & PAGE_MASK)) {
- 			send_sig(SIGKILL, current, 0);
- 			return error;
-@@ -361,7 +366,9 @@
- 
- 		if (!bprm->file->f_op->mmap||((fd_offset & ~PAGE_MASK) != 0)) {
- 			loff_t pos = fd_offset;
-+			down_write(&current->mm->mmap_sem);
- 			do_brk(N_TXTADDR(ex), ex.a_text+ex.a_data);
-+			up_write(&current->mm->mmap_sem);
- 			bprm->file->f_op->read(bprm->file,(char *)N_TXTADDR(ex),
- 					ex.a_text+ex.a_data, &pos);
- 			flush_icache_range((unsigned long) N_TXTADDR(ex),
-@@ -469,8 +476,9 @@
- 			error_time = jiffies;
- 		}
- #endif
--
-+		down_write(&current->mm->mmap_sem);
- 		do_brk(start_addr, ex.a_text + ex.a_data + ex.a_bss);
-+		up_write(&current->mm->mmap_sem);
- 		
- 		file->f_op->read(file, (char *)start_addr,
- 			ex.a_text + ex.a_data, &pos);
-@@ -494,7 +502,9 @@
- 	len = PAGE_ALIGN(ex.a_text + ex.a_data);
- 	bss = ex.a_text + ex.a_data + ex.a_bss;
- 	if (bss > len) {
-+		down_write(&current->mm->mmap_sem);
- 		error = do_brk(start_addr + len, bss - len);
-+		up_write(&current->mm->mmap_sem);
- 		retval = error;
- 		if (error != start_addr + len)
- 			goto out;
-diff -Nru a/fs/binfmt_aout.c b/fs/binfmt_aout.c
---- a/fs/binfmt_aout.c	2005-01-12 20:26:27 -08:00
-+++ b/fs/binfmt_aout.c	2005-01-12 20:26:27 -08:00
-@@ -50,7 +50,10 @@
- 	start = PAGE_ALIGN(start);
- 	end = PAGE_ALIGN(end);
- 	if (end > start) {
--		unsigned long addr = do_brk(start, end - start);
-+		unsigned long addr;
-+		down_write(&current->mm->mmap_sem);
-+		addr = do_brk(start, end - start);
-+		up_write(&current->mm->mmap_sem);
- 		if (BAD_ADDR(addr))
- 			return addr;
- 	}
-@@ -323,10 +326,14 @@
- 		loff_t pos = fd_offset;
- 		/* Fuck me plenty... */
- 		/* <AOL></AOL> */
-+		down_write(&current->mm->mmap_sem);	
- 		error = do_brk(N_TXTADDR(ex), ex.a_text);
-+		up_write(&current->mm->mmap_sem);
- 		bprm->file->f_op->read(bprm->file, (char *) N_TXTADDR(ex),
- 			  ex.a_text, &pos);
-+		down_write(&current->mm->mmap_sem);
- 		error = do_brk(N_DATADDR(ex), ex.a_data);
-+		up_write(&current->mm->mmap_sem);
- 		bprm->file->f_op->read(bprm->file, (char *) N_DATADDR(ex),
- 			  ex.a_data, &pos);
- 		goto beyond_if;
-@@ -346,8 +353,9 @@
- 		pos = 32;
- 		map_size = ex.a_text+ex.a_data;
- #endif
--
-+		down_write(&current->mm->mmap_sem);
- 		error = do_brk(text_addr & PAGE_MASK, map_size);
-+		up_write(&current->mm->mmap_sem);
- 		if (error != (text_addr & PAGE_MASK)) {
- 			send_sig(SIGKILL, current, 0);
- 			return error;
-@@ -382,7 +390,9 @@
- 
- 		if (!bprm->file->f_op->mmap||((fd_offset & ~PAGE_MASK) != 0)) {
- 			loff_t pos = fd_offset;
-+			down_write(&current->mm->mmap_sem);
- 			do_brk(N_TXTADDR(ex), ex.a_text+ex.a_data);
-+			up_write(&current->mm->mmap_sem);
- 			bprm->file->f_op->read(bprm->file,
- 					(char __user *)N_TXTADDR(ex),
- 					ex.a_text+ex.a_data, &pos);
-@@ -487,8 +497,9 @@
- 			       file->f_dentry->d_name.name);
- 			error_time = jiffies;
- 		}
--
-+		down_write(&current->mm->mmap_sem);
- 		do_brk(start_addr, ex.a_text + ex.a_data + ex.a_bss);
-+		up_write(&current->mm->mmap_sem);
- 		
- 		file->f_op->read(file, (char __user *)start_addr,
- 			ex.a_text + ex.a_data, &pos);
-diff -Nru a/fs/binfmt_elf.c b/fs/binfmt_elf.c
---- a/fs/binfmt_elf.c	2005-01-12 20:26:27 -08:00
-+++ b/fs/binfmt_elf.c	2005-01-12 20:26:27 -08:00
-@@ -88,7 +88,10 @@
- 	start = ELF_PAGEALIGN(start);
- 	end = ELF_PAGEALIGN(end);
- 	if (end > start) {
--		unsigned long addr = do_brk(start, end - start);
-+		unsigned long addr;
-+		down_write(&current->mm->mmap_sem);
-+		addr = do_brk(start, end - start);
-+		up_write(&current->mm->mmap_sem);
- 		if (BAD_ADDR(addr))
- 			return addr;
- 	}
-@@ -409,7 +412,9 @@
- 
- 	/* Map the last of the bss segment */
- 	if (last_bss > elf_bss) {
-+		down_write(&current->mm->mmap_sem);
- 		error = do_brk(elf_bss, last_bss - elf_bss);
-+		up_write(&current->mm->mmap_sem);
- 		if (BAD_ADDR(error))
- 			goto out_close;
- 	}
-@@ -449,7 +454,9 @@
- 		goto out;
- 	}
- 
-+	down_write(&current->mm->mmap_sem);	
- 	do_brk(0, text_data);
-+	up_write(&current->mm->mmap_sem);
- 	if (!interpreter->f_op || !interpreter->f_op->read)
- 		goto out;
- 	if (interpreter->f_op->read(interpreter, addr, text_data, &offset) < 0)
-@@ -457,8 +464,11 @@
- 	flush_icache_range((unsigned long)addr,
- 	                   (unsigned long)addr + text_data);
- 
-+
-+	down_write(&current->mm->mmap_sem);	
- 	do_brk(ELF_PAGESTART(text_data + ELF_MIN_ALIGN - 1),
- 		interp_ex->a_bss);
-+	up_write(&current->mm->mmap_sem);
- 	elf_entry = interp_ex->a_entry;
- 
- out:
-diff -Nru a/mm/mmap.c b/mm/mmap.c
---- a/mm/mmap.c	2005-01-12 20:26:27 -08:00
-+++ b/mm/mmap.c	2005-01-12 20:26:27 -08:00
-@@ -1903,6 +1903,12 @@
- 	}
- 
- 	/*
-+	 * mm->mmap_sem is required to protect against another thread
-+	 * changing the mappings in case we sleep.
-+	 */
-+	WARN_ON(down_read_trylock(&mm->mmap_sem));
-+
-+	/*
- 	 * Clear old maps.  this also does some error checking for us
- 	 */
-  munmap_back:

Copied: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/035-do_brk_security_fixes.dpatch (from rev 2592, trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/035-do_brk_security_fixes-2.dpatch)

Deleted: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/036-rlimit_memlock_check-2.dpatch
===================================================================
--- trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/036-rlimit_memlock_check-2.dpatch	2005-03-04 09:44:49 UTC (rev 2593)
+++ trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/036-rlimit_memlock_check-2.dpatch	2005-03-04 09:48:09 UTC (rev 2594)
@@ -1,39 +0,0 @@
-#! /bin/sh -e
-## <PATCHNAME>.dpatch by <PATCH_AUTHOR@EMAI>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: Description: [PATCH] acct_stack_growth nitpicks
-## DP: Patch author: chrisw@osdl.org
-## DP: Upstream status: backported
-
-. $(dirname $0)/DPATCH
-
-@DPATCH@
-# This is a BitKeeper generated diff -Nru style patch.
-#
-# ChangeSet
-#   2005/01/11 07:40:07-08:00 chrisw@osdl.org 
-#   [PATCH] acct_stack_growth nitpicks
-#   
-#   - allow CAP_IPC_LOCK to override mlock rlimit during stack expansion as
-#     in all other cases
-#   
-#   Signed-off-by: Chris Wright <chrisw@osdl.org>
-#   Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-# 
-# mm/mmap.c
-#   2005/01/10 19:34:05-08:00 chrisw@osdl.org +1 -1
-#   acct_stack_growth nitpicks
-# 
-diff -Nru a/mm/mmap.c b/mm/mmap.c
---- a/mm/mmap.c	2005-01-15 13:03:38 -08:00
-+++ b/mm/mmap.c	2005-01-15 13:03:38 -08:00
-@@ -1359,7 +1359,7 @@
- 		unsigned long limit;
- 		locked = mm->locked_vm + grow;
- 		limit = rlim[RLIMIT_MEMLOCK].rlim_cur >> PAGE_SHIFT;
--		if (locked > limit)
-+		if (locked > limit && !capable(CAP_IPC_LOCK))
- 			return -ENOMEM;
- 	}
- 

Copied: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/036-rlimit_memlock_check.dpatch (from rev 2592, trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/036-rlimit_memlock_check-2.dpatch)

Deleted: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/modular-ide-2.dpatch
===================================================================
--- trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/modular-ide-2.dpatch	2005-03-04 09:44:49 UTC (rev 2593)
+++ trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/modular-ide-2.dpatch	2005-03-04 09:48:09 UTC (rev 2594)
@@ -1,128 +0,0 @@
-#! /bin/sh -e 
-## <PATCHNAME>.dpatch by <PATCH_AUTHOR@EMAI>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: Description: fix IDE modularisation
-## DP: Patch author: Herbert Xu
-## DP: Upstream status: rejected
-
-. $(dirname $0)/DPATCH
-
-@DPATCH@
---- 1.3/drivers/ide/ide-generic.c	2004-02-22 18:36:17 +01:00
-+++ edited/drivers/ide/ide-generic.c	2004-06-16 15:44:16 +02:00
-@@ -11,9 +11,14 @@
- #include <linux/init.h>
- #include <linux/module.h>
- #include <linux/ide.h>
-+#include <linux/config.h>
- 
- static int __init ide_generic_init(void)
- {
-+#ifdef CONFIG_BLK_DEV_IDEPCI
-+	ide_scan_pcibus();
-+#endif
-+
- 	if (ide_hwifs[0].io_ports[IDE_DATA_OFFSET])
- 		ide_get_lock(NULL, NULL); /* for atari only */
- 
---- 1.150/drivers/ide/ide.c	2004-06-15 18:31:12 +02:00
-+++ edited/drivers/ide/ide.c	2004-06-16 15:44:16 +02:00
-@@ -175,10 +175,11 @@
- static int initializing;	/* set while initializing built-in drivers */
- 
- DECLARE_MUTEX(ide_cfg_sem);
-+EXPORT_SYMBOL(ide_cfg_sem);
- spinlock_t ide_lock __cacheline_aligned_in_smp = SPIN_LOCK_UNLOCKED;
- 
- #ifdef CONFIG_BLK_DEV_IDEPCI
--static int ide_scan_direction; /* THIS was formerly 2.2.x pci=reverse */
-+int ide_scan_direction;		/* THIS was formerly 2.2.x pci=reverse */
- #endif
- 
- #ifdef CONFIG_IDEDMA_AUTO
-@@ -1364,6 +1365,8 @@
- 
- EXPORT_SYMBOL(system_bus_clock);
- 
-+EXPORT_SYMBOL(ide_add_generic_settings);
-+
- /*
-  *	Locking is badly broken here - since way back.  That sucker is
-  * root-only, but that's not an excuse...  The real question is what
-@@ -2011,9 +2014,9 @@
-  */
- static void __init probe_for_hwifs (void)
- {
--#ifdef CONFIG_BLK_DEV_IDEPCI
--	ide_scan_pcibus(ide_scan_direction);
--#endif /* CONFIG_BLK_DEV_IDEPCI */
-+#if defined(CONFIG_BLK_DEV_IDEPCI) && !defined(MODULE)
-+	ide_scan_pcibus();
-+#endif /* CONFIG_BLK_DEV_IDEPCI && !MODULE */
- 
- #ifdef CONFIG_ETRAX_IDE
- 	{
---- 1.25/drivers/ide/setup-pci.c	2004-06-01 21:04:38 +02:00
-+++ edited/drivers/ide/setup-pci.c	2004-06-16 15:44:18 +02:00
-@@ -821,7 +821,7 @@
-  *	boot up the pci layer takes over the job.
-  */
-  
--static int __init ide_scan_pcidev(struct pci_dev *dev)
-+static int ide_scan_pcidev(struct pci_dev *dev)
- {
- 	struct list_head *l;
- 	struct pci_driver *d;
-@@ -847,21 +847,23 @@
- 
- /**
-  *	ide_scan_pcibus		-	perform the initial IDE driver scan
-- *	@scan_direction: set for reverse order scanning
-  *
-  *	Perform the initial bus rather than driver ordered scan of the
-  *	PCI drivers. After this all IDE pci handling becomes standard
-  *	module ordering not traditionally ordered.
-  */
-  	
--void __init ide_scan_pcibus (int scan_direction)
-+void ide_scan_pcibus(void)
- {
- 	struct pci_dev *dev = NULL;
- 	struct pci_driver *d;
- 	struct list_head *l, *n;
- 
-+	if (!pre_init)
-+		return;
-+
- 	pre_init = 0;
--	if (!scan_direction) {
-+	if (!ide_scan_direction) {
- 		while ((dev = pci_find_device(PCI_ANY_ID, PCI_ANY_ID, dev)) != NULL) {
- 			ide_scan_pcidev(dev);
- 		}
-@@ -883,3 +885,5 @@
- 		pci_register_driver(d);
- 	}
- }
-+
-+EXPORT_SYMBOL_GPL(ide_scan_pcibus);
---- 1.124/include/linux/ide.h	2004-06-05 21:58:33 +02:00
-+++ edited/include/linux/ide.h	2004-06-16 15:44:18 +02:00
-@@ -1224,6 +1224,7 @@
- extern	ide_hwif_t	ide_hwifs[];		/* master data repository */
- #endif
- extern int noautodma;
-+extern int ide_scan_direction;
- 
- extern int ide_end_request (ide_drive_t *drive, int uptodate, int nrsecs);
- 
-@@ -1524,7 +1525,7 @@
- 
- extern int ideprobe_init(void);
- 
--extern void ide_scan_pcibus(int scan_direction) __init;
-+extern void ide_scan_pcibus(void);
- extern int ide_pci_register_driver(struct pci_driver *driver);
- extern void ide_pci_unregister_driver(struct pci_driver *driver);
- extern void ide_pci_setup_ports(struct pci_dev *dev, struct ide_pci_device_s *d, int autodma, int pciirq, ata_index_t *index);

Copied: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/modular-ide.dpatch (from rev 2592, trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/modular-ide-2.dpatch)

Deleted: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/modular-vesafb-2.dpatch
===================================================================
--- trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/modular-vesafb-2.dpatch	2005-03-04 09:44:49 UTC (rev 2593)
+++ trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/modular-vesafb-2.dpatch	2005-03-04 09:48:09 UTC (rev 2594)
@@ -1,210 +0,0 @@
-#! /bin/sh -e
-## <PATCHNAME>.dpatch by <PATCH_AUTHOR@EMAI>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: Description: modularised VESA FB
-## DP: Patch author: initial author unknown, fixed up by Andres Salomon
-## DP: Upstream status: not submitted
-
-. $(dirname $0)/DPATCH
-
-@DPATCH@
-
-* modified files
-
---- orig/drivers/video/Kconfig
-+++ mod/drivers/video/Kconfig
-@@ -329,7 +329,7 @@
- 	  cards. Say Y if you have one of those.
- 
- config FB_VESA
--	bool "VESA VGA graphics support"
-+	tristate "VESA VGA graphics support"
- 	depends on FB && (X86 || X86_64)
- 	help
- 	  This is the frame buffer device driver for generic VESA 2.0
-
-
---- orig/drivers/video/vesafb.c
-+++ mod/drivers/video/vesafb.c
-@@ -28,6 +28,12 @@
- #define dac_reg	(0x3c8)
- #define dac_val	(0x3c9)
- 
-+struct vesafb_info
-+{
-+	u32 pseudo_palette[256];
-+	int mtrr_hdl;
-+};
-+
- /* --------------------------------------------------------------------- */
- 
- static struct fb_var_screeninfo vesafb_defined __initdata = {
-@@ -47,17 +53,34 @@
- 	.accel	= FB_ACCEL_NONE,
- };
- 
--static int             inverse   = 0;
--static int             mtrr      = 1;
-+static int             mtrr __initdata = 1;
- static int	       vram_remap __initdata = 0; /* Set amount of memory to be used */
- static int	       vram_total __initdata = 0; /* Set total amount of memory */
- static int             pmi_setpal = 0;	/* pmi for palette changes ??? */
-+static int             redraw __initdata = 0;
- static int             ypan       = 0;  /* 0..nothing, 1..ypan, 2..ywrap */
-+static int             ywrap __initdata = 0;
- static unsigned short  *pmi_base  = NULL;
- static void            (*pmi_start)(void);
- static void            (*pmi_pal)(void);
- static int             depth;
- 
-+module_param(redraw, bool, 0);
-+module_param(ypan, bool, 0);
-+module_param(ywrap, bool, 0);
-+module_param_named(vgapal, pmi_setpal, invbool, 0);
-+MODULE_PARM_DESC(vgapal, "Use VGA for setting palette (default)");
-+module_param_named(pmipal, pmi_setpal, bool, 0);
-+MODULE_PARM_DESC(pmipal, "Use PMI for setting palette");
-+module_param(mtrr, bool, 0);
-+MODULE_PARM_DESC(mtrr, "Enable MTRR support (default)");
-+module_param_named(nomtrr, mtrr, invbool, 0);
-+MODULE_PARM_DESC(nomtrr, "Disable MTRR support");
-+module_param(vram_remap, int, 0);
-+MODULE_PARM_DESC(vram_remap, "Set total amount of memory to be used");
-+module_param(vram_total, int, 0);
-+MODULE_PARM_DESC(vram_total, "Total amount of memory");
-+
- /* --------------------------------------------------------------------- */
- 
- static int vesafb_pan_display(struct fb_var_screeninfo *var,
-@@ -185,6 +208,7 @@
- 	.fb_cursor	= soft_cursor,
- };
- 
-+#ifndef MODULE
- int __init vesafb_setup(char *options)
- {
- 	char *this_opt;
-@@ -195,9 +219,7 @@
- 	while ((this_opt = strsep(&options, ",")) != NULL) {
- 		if (!*this_opt) continue;
- 		
--		if (! strcmp(this_opt, "inverse"))
--			inverse=1;
--		else if (! strcmp(this_opt, "redraw"))
-+		if (! strcmp(this_opt, "redraw"))
- 			ypan=0;
- 		else if (! strcmp(this_opt, "ypan"))
- 			ypan=1;
-@@ -218,11 +240,13 @@
- 	}
- 	return 0;
- }
-+#endif
- 
- static int __init vesafb_probe(struct device *device)
- {
- 	struct platform_device *dev = to_platform_device(device);
- 	struct fb_info *info;
-+	struct vesafb_info *vfb_info;
- 	int i, err;
- 	unsigned int size_vmode;
- 	unsigned int size_remap;
-@@ -280,13 +304,14 @@
- 		   spaces our resource handlers simply don't know about */
- 	}
- 
--	info = framebuffer_alloc(sizeof(u32) * 256, &dev->dev);
-+	info = framebuffer_alloc(sizeof(struct vesafb_info), &dev->dev);
- 	if (!info) {
- 		release_mem_region(vesafb_fix.smem_start, vesafb_fix.smem_len);
- 		return -ENOMEM;
- 	}
--	info->pseudo_palette = info->par;
--	info->par = NULL;
-+	vfb_info = (struct vesafb_info *) info->par;
-+	vfb_info->mtrr_hdl = -1;
-+	info->pseudo_palette = vfb_info->pseudo_palette;
- 
-         info->screen_base = ioremap(vesafb_fix.smem_start, vesafb_fix.smem_len);
- 	if (!info->screen_base) {
-@@ -395,7 +420,7 @@
-                 	temp_size &= (temp_size - 1);
-                         
-                 /* Try and find a power of two to add */
--		while (temp_size && mtrr_add(vesafb_fix.smem_start, temp_size, MTRR_TYPE_WRCOMB, 1)==-EINVAL) {
-+		while (temp_size && (vfb_info->mtrr_hdl = mtrr_add(vesafb_fix.smem_start, temp_size, MTRR_TYPE_WRCOMB, 1)) == -EINVAL) {
- 			temp_size >>= 1;
- 		}
- 	}
-@@ -417,6 +442,7 @@
- 	}
- 	printk(KERN_INFO "fb%d: %s frame buffer device\n",
- 	       info->node, info->fix.id);
-+	dev_set_drvdata(device, info);
- 	return 0;
- err:
- 	framebuffer_release(info);
-@@ -424,10 +450,24 @@
- 	return err;
- }
- 
-+static void __exit vesafb_remove(struct device *device)
-+{
-+	struct fb_info *info = dev_get_drvdata(device);
-+	struct vesafb_info *vfb_info = (struct vesafb_info *) info->par;
-+
-+	unregister_framebuffer(info);
-+	if (vfb_info->mtrr_hdl >= 0)
-+		mtrr_del(vfb_info->mtrr_hdl, 0, 0);
-+	iounmap(info->screen_base);
-+	framebuffer_release(info);
-+	release_mem_region(vesafb_fix.smem_start, vesafb_fix.smem_len);
-+}
-+
- static struct device_driver vesafb_driver = {
- 	.name	= "vesafb",
- 	.bus	= &platform_bus_type,
- 	.probe	= vesafb_probe,
-+	.remove = vesafb_remove,
- };
- 
- static struct platform_device vesafb_device = {
-@@ -437,11 +477,18 @@
- int __init vesafb_init(void)
- {
- 	int ret;
-+#ifndef MODULE
- 	char *option = NULL;
- 
- 	/* ignore error return of fb_get_options */
- 	fb_get_options("vesafb", &option);
- 	vesafb_setup(option);
-+#else
-+	if (redraw)
-+		ypan = 0;
-+	if (ywrap)
-+		ypan = 2;
-+#endif
- 	ret = driver_register(&vesafb_driver);
- 
- 	if (!ret) {
-@@ -451,7 +498,15 @@
- 	}
- 	return ret;
- }
-+
-+static void __exit vesafb_exit(void)
-+{
-+	platform_device_unregister(&vesafb_device);
-+	driver_unregister(&vesafb_driver);
-+}
-+
- module_init(vesafb_init);
-+module_exit(vesafb_exit);
- 
- /*
-  * Overrides for Emacs so that we follow Linus's tabbing style.
-
-
-

Copied: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/modular-vesafb.dpatch (from rev 2592, trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/modular-vesafb-2.dpatch)

Deleted: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/powerpc-pegasos-via82cxxx.dpatch
===================================================================
--- trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/powerpc-pegasos-via82cxxx.dpatch	2005-03-04 09:44:49 UTC (rev 2593)
+++ trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/powerpc-pegasos-via82cxxx.dpatch	2005-03-04 09:48:09 UTC (rev 2594)
@@ -1,37 +0,0 @@
-#! /bin/sh -e 
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: Description: Hacky workaround for the via-ide dual interrupt on pegasos hardware.
-## DP: Patch author: Sven Luther <luther@debian.org>
-## DP: Upstream status: hack moved from the kernel-patch-powerpc package.
-
-. $(dirname $0)/DPATCH
-
-@DPATCH@
---- kernel-source-2.6.8/drivers/ide/pci/via82cxxx.c.orig	2004-11-24 22:47:24.000000000 +0100
-+++ kernel-source-2.6.8/drivers/ide/pci/via82cxxx.c	2004-12-26 12:10:06.900614568 +0100
-@@ -36,6 +36,10 @@
- #include <linux/ide.h>
- #include <asm/io.h>
- 
-+#ifdef CONFIG_PPC_MULTIPLATFORM
-+#include <asm/processor.h>
-+#endif
-+
- #include "ide-timing.h"
- 
- #define DISPLAY_VIA_TIMINGS
-@@ -584,6 +588,13 @@
- 	hwif->tuneproc = &via82cxxx_tune_drive;
- 	hwif->speedproc = &via_set_drive;
- 
-+
-+#ifdef CONFIG_PPC_MULTIPLATFORM
-+	if(_machine == _MACH_chrp && _chrp_type == _CHRP_Pegasos) {
-+		hwif->irq = hwif->channel ? 15 : 14;
-+	}
-+#endif
-+
- 	for (i = 0; i < 2; i++) {
- 		hwif->drives[i].io_32bit = 1;
- 		hwif->drives[i].unmask = (via_config->flags & VIA_NO_UNMASK) ? 0 : 1;

Deleted: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/powerpc-pegasos.dpatch
===================================================================
--- trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/powerpc-pegasos.dpatch	2005-03-04 09:44:49 UTC (rev 2593)
+++ trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/powerpc-pegasos.dpatch	2005-03-04 09:48:09 UTC (rev 2594)
@@ -1,312 +0,0 @@
-#! /bin/sh -e 
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: Description: Add Pegasos 1 and 2 support.
-## DP: Patch author: Sven Luther <luther@debian.org>
-## DP: Upstream status: submitted and approved.
-
-. $(dirname $0)/DPATCH
-
-@DPATCH@
-diff -urN kernel-source-2.6.8.orig/arch/ppc/kernel/ppc_ksyms.c kernel-source-2.6.8/arch/ppc/kernel/ppc_ksyms.c
---- kernel-source-2.6.8.orig/arch/ppc/kernel/ppc_ksyms.c	2004-08-14 07:37:41.000000000 +0200
-+++ kernel-source-2.6.8/arch/ppc/kernel/ppc_ksyms.c	2004-12-26 11:50:48.234758552 +0100
-@@ -96,6 +96,9 @@
- EXPORT_SYMBOL(_prep_type);
- EXPORT_SYMBOL(ucSystemType);
- #endif
-+#if defined(CONFIG_PPC_MULTIPLATFORM)
-+EXPORT_SYMBOL(_chrp_type);
-+#endif
- 
- #if !defined(__INLINE_BITOPS)
- EXPORT_SYMBOL(set_bit);
-diff -urN kernel-source-2.6.8.orig/arch/ppc/platforms/chrp_pci.c kernel-source-2.6.8/arch/ppc/platforms/chrp_pci.c
---- kernel-source-2.6.8.orig/arch/ppc/platforms/chrp_pci.c	2004-12-26 12:03:07.438382520 +0100
-+++ kernel-source-2.6.8/arch/ppc/platforms/chrp_pci.c	2004-12-26 12:02:26.819557520 +0100
-@@ -97,8 +97,9 @@
- rtas_read_config(struct pci_bus *bus, unsigned int devfn, int offset,
- 		 int len, u32 *val)
- {
-+	struct pci_controller *hose = bus->sysdata;
- 	unsigned long addr = (offset & 0xff) | ((devfn & 0xff) << 8)
--		| ((bus->number & 0xff) << 16);
-+		| (((bus->number - hose->first_busno) & 0xff) << 16) | (pci_domain_nr(bus) << 24);
-         unsigned long ret = ~0UL;
- 	int rval;
- 
-@@ -111,8 +112,9 @@
- rtas_write_config(struct pci_bus *bus, unsigned int devfn, int offset,
- 		  int len, u32 val)
- {
-+	struct pci_controller *hose = bus->sysdata;
- 	unsigned long addr = (offset & 0xff) | ((devfn & 0xff) << 8)
--		| ((bus->number & 0xff) << 16);
-+		| (((bus->number - hose->first_busno) & 0xff) << 16) | (pci_domain_nr(bus) << 24);
- 	int rval;
- 
- 	rval = call_rtas("write-pci-config", 3, 1, NULL, addr, len, val);
-@@ -186,6 +188,26 @@
- 	iounmap(reg);
- }
- 
-+/* Marvell Discovery II based Pegasos 2 */
-+//#define PEGASOS_USE_PCI_DOMAINS
-+
-+static void __init
-+setup_peg2(struct pci_controller *hose, struct device_node *dev)
-+{
-+	struct device_node *root = find_path_device("/");
-+	struct device_node *rtas;
-+
-+	rtas = of_find_node_by_name (root, "rtas");
-+	if (rtas) {
-+		hose->ops = &rtas_pci_ops;
-+	} else {
-+		printk ("RTAS supporting Pegasos OF not found, please upgrade your firmware\n");
-+	}
-+#ifndef PEGASOS_USE_PCI_DOMAINS
-+	pci_assign_all_busses = 1;
-+#endif
-+}
-+
- void __init
- chrp_find_bridges(void)
- {
-@@ -195,7 +217,7 @@
- 	struct pci_controller *hose;
- 	unsigned int *dma;
- 	char *model, *machine;
--	int is_longtrail = 0, is_mot = 0;
-+	int is_longtrail = 0, is_mot = 0, is_pegasos = 0;
- 	struct device_node *root = find_path_device("/");
- 
- 	/*
-@@ -207,6 +229,8 @@
- 	if (machine != NULL) {
- 		is_longtrail = strncmp(machine, "IBM,LongTrail", 13) == 0;
- 		is_mot = strncmp(machine, "MOT", 3) == 0;
-+		if (strncmp(machine, "Pegasos2", 8) == 0) is_pegasos = 2;
-+		else if (strncmp(machine, "Pegasos", 7) == 0) is_pegasos = 1;
- 	}
- 	for (dev = root->child; dev != NULL; dev = dev->sibling) {
- 		if (dev->type == NULL || strcmp(dev->type, "pci") != 0)
-@@ -257,6 +281,10 @@
- 			hose->cfg_data = (unsigned char *)
- 				ioremap(GG2_PCI_CONFIG_BASE, 0x80000);
- 			gg2_pci_config_base = (unsigned long) hose->cfg_data;
-+		} else if (is_pegasos == 1) {
-+			setup_indirect_pci(hose, 0xfec00cf8, 0xfee00cfc);
-+		} else if (is_pegasos == 2) {
-+			setup_peg2(hose, dev);
- 		} else {
- 			printk("No methods for %s (model %s), using RTAS\n",
- 			       dev->full_name, model);
-@@ -274,6 +302,9 @@
- 			printk("pci_dram_offset = %lx\n", pci_dram_offset);
- 		}
- 	}
--
--	ppc_md.pcibios_fixup = chrp_pcibios_fixup;
-+	
-+	if (is_pegasos)
-+		ppc_md.pcibios_fixup = NULL;
-+	else
-+		ppc_md.pcibios_fixup = chrp_pcibios_fixup;
- }
-diff -urN kernel-source-2.6.8.orig/arch/ppc/platforms/chrp_setup.c kernel-source-2.6.8/arch/ppc/platforms/chrp_setup.c
---- kernel-source-2.6.8.orig/arch/ppc/platforms/chrp_setup.c	2004-12-26 12:03:07.440382216 +0100
-+++ kernel-source-2.6.8/arch/ppc/platforms/chrp_setup.c	2004-12-26 12:01:39.050819472 +0100
-@@ -68,6 +68,8 @@
- extern unsigned long pmac_find_end_of_memory(void);
- extern int of_show_percpuinfo(struct seq_file *, int);
- 
-+int _chrp_type;
-+
- /*
-  * XXX this should be in xmon.h, but putting it there means xmon.h
-  * has to include <linux/interrupt.h> (to get irqreturn_t), which
-@@ -214,6 +216,36 @@
- 	}
- }
- 
-+void pegasos_set_l2cr(void)
-+{
-+	struct device_node *root = find_path_device("/");
-+	char *machine;
-+	struct device_node *np;
-+
-+	/* On Pegasos, enable the l2 cache if needed, as the OF forgets it */
-+	if (root == NULL)
-+		return;
-+	machine = get_property(root, "model", NULL);
-+	if (machine == NULL)
-+		return;
-+	if (_chrp_type == _CHRP_Pegasos) {
-+		/* Enable L2 cache if needed */
-+		np = find_type_devices("cpu");
-+		if (np != NULL) {
-+			unsigned int *l2cr = (unsigned int *)
-+				get_property (np, "l2cr", NULL);
-+			if (l2cr == NULL) {
-+				printk ("Pegasos l2cr : no cpu l2cr property found\n");
-+				return;
-+			}
-+			if (!((*l2cr) & 0x80000000)) {
-+				printk ("Pegasos l2cr : L2 cache was not active, activating\n");
-+				_set_L2CR(0);
-+				_set_L2CR((*l2cr) | 0x80000000);
-+			}
-+		}
-+	}
-+}
- 
- void __init
- chrp_setup_arch(void)
-@@ -236,6 +268,9 @@
- 	/* Lookup PCI host bridges */
- 	chrp_find_bridges();
- 
-+	/* On pegasos, enable the L2 cache if not already done by OF */
-+	pegasos_set_l2cr();
-+
- #ifndef CONFIG_PPC64BRIDGE
- 	/*
- 	 *  Temporary fixes for PCI devices.
-@@ -400,16 +435,19 @@
- 	if (np == NULL)
- 		printk(KERN_ERR "Cannot find PCI interrupt acknowledge address\n");
- 
--	chrp_find_openpic();
--
--	prom_get_irq_senses(init_senses, NUM_8259_INTERRUPTS, NR_IRQS);
--	OpenPIC_InitSenses = init_senses;
--	OpenPIC_NumInitSenses = NR_IRQS - NUM_8259_INTERRUPTS;
--
--	openpic_init(NUM_8259_INTERRUPTS);
--	/* We have a cascade on OpenPIC IRQ 0, Linux IRQ 16 */
--	openpic_hookup_cascade(NUM_8259_INTERRUPTS, "82c59 cascade",
-+	/* Pegasos doesn't have openpic */
-+	if (_chrp_type != _CHRP_Pegasos) {
-+		chrp_find_openpic();
-+
-+		prom_get_irq_senses(init_senses, NUM_8259_INTERRUPTS, NR_IRQS);
-+		OpenPIC_InitSenses = init_senses;
-+		OpenPIC_NumInitSenses = NR_IRQS - NUM_8259_INTERRUPTS;
-+
-+		openpic_init(NUM_8259_INTERRUPTS);
-+		/* We have a cascade on OpenPIC IRQ 0, Linux IRQ 16 */
-+		openpic_hookup_cascade(NUM_8259_INTERRUPTS, "82c59 cascade",
- 			       i8259_irq);
-+	}
- 
- 	for (i = 0; i < NUM_8259_INTERRUPTS; i++)
- 		irq_desc[i].handler = &i8259_pic;
-@@ -450,6 +488,8 @@
- chrp_init(unsigned long r3, unsigned long r4, unsigned long r5,
- 	  unsigned long r6, unsigned long r7)
- {
-+	struct device_node *root = find_path_device ("/");
-+	char *machine;
- #ifdef CONFIG_BLK_DEV_INITRD
- 	/* take care of initrd if we have one */
- 	if ( r6 )
-@@ -464,12 +504,27 @@
- 	DMA_MODE_WRITE = 0x48;
- 	isa_io_base = CHRP_ISA_IO_BASE;		/* default value */
- 
-+	machine = get_property(root, "model", NULL);
-+	if (strncmp(machine, "Pegasos", 7) == 0) {
-+		_chrp_type = _CHRP_Pegasos;
-+	} else if (strncmp(machine, "IBM", 3) == 0) {
-+		_chrp_type = _CHRP_IBM;
-+	} else if (strncmp(machine, "MOT", 3) == 0) {
-+		_chrp_type = _CHRP_Motorola;
-+	} else {
-+		/* Let's assume it is an IBM chrp if all else fails */
-+		_chrp_type = _CHRP_IBM;
-+	}
-+	
- 	ppc_md.setup_arch     = chrp_setup_arch;
- 	ppc_md.show_percpuinfo = of_show_percpuinfo;
- 	ppc_md.show_cpuinfo   = chrp_show_cpuinfo;
- 	ppc_md.irq_canonicalize = chrp_irq_canonicalize;
- 	ppc_md.init_IRQ       = chrp_init_IRQ;
--	ppc_md.get_irq        = openpic_get_irq;
-+	if (_chrp_type == _CHRP_Pegasos)
-+		ppc_md.get_irq        = i8259_irq;
-+	else
-+		ppc_md.get_irq        = openpic_get_irq;
- 
- 	ppc_md.init           = chrp_init2;
- 
-diff -urN kernel-source-2.6.8.orig/arch/ppc/platforms/chrp_time.c kernel-source-2.6.8/arch/ppc/platforms/chrp_time.c
---- kernel-source-2.6.8.orig/arch/ppc/platforms/chrp_time.c	2004-12-26 12:03:07.552365192 +0100
-+++ kernel-source-2.6.8/arch/ppc/platforms/chrp_time.c	2004-11-24 22:47:24.000000000 +0100
-@@ -41,6 +41,8 @@
- 	int base;
- 
- 	rtcs = find_compatible_devices("rtc", "pnpPNP,b00");
-+	if (rtcs == NULL)
-+		rtcs = find_compatible_devices("rtc", "ds1385-rtc");
- 	if (rtcs == NULL || rtcs->addrs == NULL)
- 		return 0;
- 	base = rtcs->addrs[0].address;
-diff -urN kernel-source-2.6.8.orig/arch/ppc/syslib/prom_init.c kernel-source-2.6.8/arch/ppc/syslib/prom_init.c
---- kernel-source-2.6.8.orig/arch/ppc/syslib/prom_init.c	2004-12-26 12:03:07.672346952 +0100
-+++ kernel-source-2.6.8/arch/ppc/syslib/prom_init.c	2004-12-26 11:58:49.597580280 +0100
-@@ -794,6 +794,9 @@
- 	char *p, *d;
-  	unsigned long phys;
- 	void *result[3];
-+	char model[32];
-+	phandle node;
-+	int rc;
- 
-  	/* Default */
-  	phys = (unsigned long) &_stext;
-@@ -850,11 +853,20 @@
- 
- 	klimit = (char *) (mem - offset);
- 
--	/* If we are already running at 0xc0000000, we assume we were
--	 * loaded by an OF bootloader which did set a BAT for us.
--	 * This breaks OF translate so we force phys to be 0.
--	 */
--	if (offset == 0) {
-+	node = call_prom("finddevice", 1, 1, "/");
-+	rc = call_prom("getprop", 4, 1, node, "model", model, sizeof(model));
-+	if (rc > 0 && !strncmp (model, "Pegasos", 7)
-+		&& strncmp (model, "Pegasos2", 8)) {
-+		/* Pegasos 1 has a broken translate method in the OF,
-+		 * and furthermore the BATs are mapped 1:1 so the phys
-+		 * address calculated above is correct, so let's use
-+		 * it directly.
-+		 */
-+	} else if (offset == 0) {
-+		/* If we are already running at 0xc0000000, we assume we were
-+	 	 * loaded by an OF bootloader which did set a BAT for us.
-+	 	 * This breaks OF translate so we force phys to be 0.
-+	 	 */
- 		prom_print("(already at 0xc0000000) phys=0\n");
- 		phys = 0;
- 	} else if ((int) call_prom("getprop", 4, 1, prom_chosen, "mmu",
-diff -urN kernel-source-2.6.8.orig/include/asm-ppc/processor.h kernel-source-2.6.8/include/asm-ppc/processor.h
---- kernel-source-2.6.8.orig/include/asm-ppc/processor.h	2004-08-14 07:36:11.000000000 +0200
-+++ kernel-source-2.6.8/include/asm-ppc/processor.h	2004-12-26 13:50:25.909586120 +0100
-@@ -34,6 +34,7 @@
- /* these are arbitrary */
- #define _CHRP_Motorola	0x04	/* motorola chrp, the cobra */
- #define _CHRP_IBM	0x05	/* IBM chrp, the longtrail and longtrail 2 */
-+#define _CHRP_Pegasos	0x06	/* Genesi/bplan's Pegasos and Pegasos2 */
- 
- #define _GLOBAL(n)\
- 	.stabs __stringify(n:F-1),N_FUN,0,0,n;\
-@@ -54,6 +55,7 @@
- 
- /* what kind of prep workstation we are */
- extern int _prep_type;
-+extern int _chrp_type;
- 
- /*
-  * This is used to identify the board type from a given PReP board

Deleted: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-1
===================================================================
--- trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-1	2005-03-04 09:44:49 UTC (rev 2593)
+++ trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-1	2005-03-04 09:48:09 UTC (rev 2594)
@@ -1,77 +0,0 @@
-X drivers/net/acenic_firmware.h
-X drivers/net/dgrs_firmware.c
-X drivers/net/tg3.c
-X drivers/net/tokenring/smctr_firmware.h
-X drivers/scsi/qla2xxx/ql2100_fw.c
-X drivers/scsi/qla2xxx/ql2200_fw.c
-X drivers/scsi/qla2xxx/ql2300_fw.c
-X drivers/scsi/qla2xxx/ql2322_fw.c
-X drivers/scsi/qla2xxx/ql6312_fw.c
-X drivers/scsi/qla2xxx/ql6322_fw.c
-X drivers/usb/media/dabfirmware.h
-X drivers/usb/misc/emi62_fw_m.h
-X drivers/usb/misc/emi62_fw_s.h
-X drivers/usb/serial/keyspan_mpr_fw.h
-X drivers/usb/serial/keyspan_usa18x_fw.h
-X drivers/usb/serial/keyspan_usa19_fw.h
-X drivers/usb/serial/keyspan_usa19qi_fw.h
-X drivers/usb/serial/keyspan_usa19qw_fw.h
-X drivers/usb/serial/keyspan_usa19w_fw.h
-X drivers/usb/serial/keyspan_usa28_fw.h
-X drivers/usb/serial/keyspan_usa28x_fw.h
-X drivers/usb/serial/keyspan_usa28xa_fw.h
-X drivers/usb/serial/keyspan_usa28xb_fw.h
-X drivers/usb/serial/keyspan_usa49w_fw.h
-X drivers/usb/serial/keyspan_usa49wlc_fw.h
-+ doc-post_halloween.dpatch
-+ drivers-ide-dma-blacklist-toshiba.dpatch
-+ drivers-input-psaux-hacks.dpatch
-+ drivers-net-8139too-locking.dpatch
-+ drivers-net-tg3-readd.dpatch
-+ drivers-scsi_changer.dpatch
-+ fs-asfs.dpatch
-+ modular-ide.dpatch
-+ modular-ide-pnp.dpatch
-+ modular-vesafb.dpatch
-+ remove-references-to-removed-drivers.dpatch
-+ x86-i486_emu.dpatch
-+ marvell-pegasos.dpatch
-+ powerpc-g4-l2-flush-errata.dpatch
-+ alsa-module-load-fix.dpatch
-+ sparc64-hme-lockup.dpatch
-+ smbfs-overflow-fixes.dpatch
-+ tty-locking-fixes9.dpatch
-+ sparc32-initrd-memcpy.dpatch
-+ drm-locking-fixes.dpatch
-+ powerpc-pegasos-2.dpatch
-+ powerpc-pegasos-via82cxxx.dpatch
-+ powerpc-serial.dpatch
-+ 001-acpi_ibm_exit.dpatch
-+ 002-pio_err_handling.dpatch
-+ 003-libata_alpha_build_fix.dpatch
-+ 004-sparc64_no_i_sock.dpatch
-+ 005-sparc64_no_i_sock-2.dpatch
-+ 006-zatm_cast_fix_fix.dpatch
-+ 007-pci_ide_no_reserve.dpatch
-+ 008-sock_without_ipv6.dpatch
-+ 009-ipt_ecn_corrupt_chksum.dpatch
-+ 010-sparc64_macro_pmd_offset.dpatch
-+ 011-parport_pc_module_parm_mixing.dpatch
-+ 012-conntrack_standalone_proc_removal.dpatch
-+ 013-conntrack_standalone_sysctl.dpatch
-+ 014-acpi_video_dev_slab_corruption.dpatch
-+ 015-vmscan_total_scanned.dpatch
-+ 016-cs461x_gameport.dpatch
-+ 017-conntrack_sctp_sysctl.dpatch
-+ 018-ipt_recent_proc_remove.dpatch
-+ 019-conntrack_tcp_RST_handling.dpatch
-+ 020-clear_cyrix_mii_ecx_reg.dpatch
-+ 021-sunrpc_check_before_kill.dpatch
-+ 022-sunrpc_xdr_flush_pages.dpatch
-+ 023-nfs_dentry_refcount.dpatch
-+ 024-nfs_incorrect_df_output.dpatch
-+ 025-track_dummy_capability.dpatch
-+ 026-nfs_o_direct_error.dpatch
-+ 027-track_dummy_capability-2.dpatch
-+ ia64-generic-no-smp.dpatch
-+ ia64-generic-no-smp-1-to-2.dpatch

Deleted: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-2
===================================================================
--- trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-2	2005-03-04 09:44:49 UTC (rev 2593)
+++ trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-2	2005-03-04 09:48:09 UTC (rev 2594)
@@ -1,4 +0,0 @@
-+ 028-do_brk_security_fixes.dpatch
-+ 029-random_poolsize_overflow.dpatch
-+ 030-moxa_user_copy_checking.dpatch
-+ 031-sg_scsi_ioctl_int_overflows.dpatch

Deleted: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-3
===================================================================
--- trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-3	2005-03-04 09:44:49 UTC (rev 2593)
+++ trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-3	2005-03-04 09:48:09 UTC (rev 2594)
@@ -1,4 +0,0 @@
-- 028-do_brk_security_fixes.dpatch
-+ 032-do_brk_security_fixes.dpatch
-+ ia64-bte_error-missing-include.dpatch
-+ ia64-irq-affinity-upfix.dpatch

Deleted: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-4
===================================================================
--- trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-4	2005-03-04 09:44:49 UTC (rev 2593)
+++ trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-4	2005-03-04 09:48:09 UTC (rev 2594)
@@ -1,33 +0,0 @@
-- smbfs-overflow-fixes.dpatch
-+ smbfs-overflow-fixes-2.dpatch
-- 007-pci_ide_no_reserve.dpatch
-- modular-ide.dpatch
-+ modular-ide-2.dpatch
-+ drivers-ide-__devinit.dpatch
-+ 007-pci_ide_no_reserve-2.dpatch
-- alsa-module-load-fix.dpatch
-- drivers-input-psaux-hacks.dpatch
-+ fix-mxser-compile.dpatch
-+ fix-alpha-ext3-oops.dpatch
-+ alsa-emu10k1-ioctl-fix.dpatch
-- modular-vesafb.dpatch
-+ modular-vesafb-2.dpatch
-+ alpha-io-typo.dpatch
-+ 033-rlimit_memlock_check.dpatch
-+ 034-stack_resize_exploit.dpatch
-+ 035-do_brk_security_fixes-2.dpatch
-+ cmsg-compat-signedness-fix-fix.dpatch
-+ 036-rlimit_memlock_check-2.dpatch
-+ 037-sctp_err_lookup_oops.dpatch
-+ 038-ftdi_sio_debug_output.dpatch
-+ 039-serial_console_resume.dpatch
-+ 040-sk_forward_alloc_underflow.dpatch
-+ 041-ide_hwif_supress_busy.dpatch
-+ 042-gx_get_cpuspeed_return_value.dpatch
-+ 043-dothan_p4_get_frequency.dpatch
-+ 044-elevator_noop_add_request.dpatch
-+ 045-pci_psycho_brainfart.dpatch
-+ 046-ipv6_sit_lock.dpatch
-+ 047-do_tcp_sendpages_tso_assertion.dpatch
-+ 048-matroxfb_mtrr_ifdef.dpatch
-+ 050-cfq_requeue_request_accounting.dpatch

Deleted: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-5
===================================================================
--- trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-5	2005-03-04 09:44:49 UTC (rev 2593)
+++ trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-5	2005-03-04 09:48:09 UTC (rev 2594)
@@ -1,43 +0,0 @@
-+ scsi-ioctl.dpatch
-+ ia64-ptrace-fixes.dpatch
-+ ia64-unwind-fix.dpatch
-+ amd64-ia32-vsyscall-fix.dpatch
-+ powerpc-fix-power3-ftbfs.dpatch
-+ amd64-parse-noexec-fix.dpatch
-+ amd64-int3-fix.dpatch
-+ fbdev-radeon-noaccel.dpatch
-+ 051-md_sync_page_io_max_vecs.dpatch
-+ 052-vfat_valid_longname_proper_return.dpatch
-+ 053-ipmi_unhandled_message_counting.dpatch
-+ 054-ext3_journal_abort_before_panic.dpatch
-+ 055-uml_new_thread_race.dpatch
-+ 056-x86_64_acpi_do_suspend_lowlevel_arg.dpatch
-+ 058-ia64_binfmt_elf_bug_out.dpatch
-+ 060-alsa_cs4231_lib_ifdef_typo.dpatch
-+ 061-alsa_es18xx_ifdef_typo.dpatch
-+ 062-alsa_sscape_user_copy_check.dpatch
-+ 063-alsa_opl4_build_fix.dpatch
-+ 064-alsa_usbaudio_disconnect.dpatch
-+ 065-alsa_vx_kcalloc.dpatch
-+ 066-ibmvscsi_probe_delay_loop_fix.dpatch
-+ 067-scsi_gdth_pci_map_sg.dpatch
-+ 068-scsi_sd_read_capacity_LBD_bail.dpatch
-+ 069-alsa_sscape_upload_firmware_len.dpatch
-+ 070-alsa_rme9652_hdsp_get_autosync.dpatch
-+ 071-alsa_creation_order_fixes.dpatch
-+ 072-sctp_do_bind_random_port.dpatch
-+ 073-usb_gadget_serial_free_ports.dpatch
-+ 074-usb_makefile_fixes.dpatch
-+ 075-acpiphp_ibm_module_parm_perm.dpatch
-+ 076-i2c_ali1563_devinit_fixes.dpatch
-+ 077-ext3_journal_abort_handle_silence.dpatch
-+ 078-jbd_journal_revoke_graceful_double_delete.dpatch
-+ 079-i386_timer_resume_slowdown.dpatch
-+ 080-kernel_sched_might_sleep_ignore_if_oopsed.dpatch
-+ 081-ia64_early_sn_setup_nested_loop.dpatch
-+ 082-ide_it8172_init_return_failure.dpatch
-+ 083-x86_64_switch_mm_context_race.dpatch
-+ 084-smp_nmi_watchdog_race.dpatch
-+ 085-ia64_irq_reg_typo.dpatch
-+ 086-i386_cpufreq_powernow_k8_acpi_error.dpatch
-+ 087-ext3_graceful_corruption_fixes.dpatch

Deleted: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-6
===================================================================
--- trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-6	2005-03-04 09:44:49 UTC (rev 2593)
+++ trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/series/2.6.10-6	2005-03-04 09:48:09 UTC (rev 2594)
@@ -1,13 +0,0 @@
-+ atyfb-sparc.dpatch
-+ skb-reset-ip_summed.dpatch
-+ sparc64-nis-killer.dpatch
-+ sparc32-hypersparc-srmmu.dpatch
-+ setsid-race.dpatch
-+ setsid-race-2.dpatch
-+ ipv4-fragment-queues.dpatch
-+ ipv4-fragment-queues-2.dpatch
-+ nls-table-overflow.dpatch
-+ amd64-noexec32-backport.dpatch 
-+ outs.dpatch
-- 083-x86_64_switch_mm_context_race.dpatch
-+ sparc64-sb1500-clock-2.6.dpatch

Deleted: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/smbfs-overflow-fixes-2.dpatch
===================================================================
--- trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/smbfs-overflow-fixes-2.dpatch	2005-03-04 09:44:49 UTC (rev 2593)
+++ trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/smbfs-overflow-fixes-2.dpatch	2005-03-04 09:48:09 UTC (rev 2594)
@@ -1,133 +0,0 @@
-#! /bin/sh -e
-## <PATCHNAME>.dpatch by <PATCH_AUTHOR@EMAI>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: Description: SMBfs overflow fixes
-## DP: Patch author: unknown, stolen from -ac tree (probably Stefan Esser,  Juan Quintela, and Urban Widmark)
-## DP: Upstream status: unknown
-
-. $(dirname $0)/DPATCH
-
-@DPATCH@
-diff -u --new-file --recursive --exclude-from /usr/src/exclude linux.vanilla-2.6.10/fs/smbfs/proc.c linux-2.6.10/fs/smbfs/proc.c
---- linux.vanilla-2.6.10/fs/smbfs/proc.c	2004-12-25 21:15:41.000000000 +0000
-+++ linux-2.6.10/fs/smbfs/proc.c	2004-12-26 23:03:13.000000000 +0000
-@@ -1427,9 +1427,9 @@
- 	 * So we must first calculate the amount of padding used by the server.
- 	 */
- 	data_off -= hdrlen;
--	if (data_off > SMB_READX_MAX_PAD) {
--		PARANOIA("offset is larger than max pad!\n");
--		PARANOIA("%d > %d\n", data_off, SMB_READX_MAX_PAD);
-+	if (data_off > SMB_READX_MAX_PAD || data_off < 0) {
-+		PARANOIA("offset is larger than SMB_READX_MAX_PAD or negative!\n");
-+		PARANOIA("%d > %d || %d < 0\n", data_off, SMB_READX_MAX_PAD, data_off);
- 		req->rq_rlen = req->rq_bufsize + 1;
- 		return;
- 	}
-diff -u --new-file --recursive --exclude-from /usr/src/exclude linux.vanilla-2.6.10/fs/smbfs/request.c linux-2.6.10/fs/smbfs/request.c
---- linux.vanilla-2.6.10/fs/smbfs/request.c	2004-12-25 21:15:41.000000000 +0000
-+++ linux-2.6.10/fs/smbfs/request.c	2004-12-26 23:06:24.000000000 +0000
-@@ -588,8 +588,18 @@
- 	data_count  = WVAL(inbuf, smb_drcnt);
- 
- 	/* Modify offset for the split header/buffer we use */
--	data_offset -= hdrlen;
--	parm_offset -= hdrlen;
-+	if (data_count || data_offset) {
-+		if (unlikely(data_offset < hdrlen))
-+			goto out_bad_data;
-+		else
-+			data_offset -= hdrlen;
-+	}
-+	if (parm_count || parm_offset) {
-+		if (unlikely(parm_offset < hdrlen))
-+			goto out_bad_parm;
-+		else
-+			parm_offset -= hdrlen;
-+	}
- 
- 	if (parm_count == parm_tot && data_count == data_tot) {
- 		/*
-@@ -600,18 +610,22 @@
- 		 * response that fits.
- 		 */
- 		VERBOSE("single trans2 response  "
--			"dcnt=%d, pcnt=%d, doff=%d, poff=%d\n",
-+			"dcnt=%u, pcnt=%u, doff=%u, poff=%u\n",
- 			data_count, parm_count,
- 			data_offset, parm_offset);
- 		req->rq_ldata = data_count;
- 		req->rq_lparm = parm_count;
- 		req->rq_data = req->rq_buffer + data_offset;
- 		req->rq_parm = req->rq_buffer + parm_offset;
-+		if (unlikely(parm_offset + parm_count > req->rq_rlen))
-+			goto out_bad_parm;
-+		if (unlikely(data_offset + data_count > req->rq_rlen))
-+			goto out_bad_data;
- 		return 0;
- 	}
- 
- 	VERBOSE("multi trans2 response  "
--		"frag=%d, dcnt=%d, pcnt=%d, doff=%d, poff=%d\n",
-+		"frag=%d, dcnt=%u, pcnt=%u, doff=%u, poff=%u\n",
- 		req->rq_fragment,
- 		data_count, parm_count,
- 		data_offset, parm_offset);
-@@ -638,13 +652,15 @@
- 
- 		req->rq_parm = req->rq_trans2buffer;
- 		req->rq_data = req->rq_trans2buffer + parm_tot;
--	} else if (req->rq_total_data < data_tot ||
--		   req->rq_total_parm < parm_tot)
-+	} else if (unlikely(req->rq_total_data < data_tot ||
-+			    req->rq_total_parm < parm_tot))
- 		goto out_data_grew;
- 
--	if (parm_disp + parm_count > req->rq_total_parm)
-+	if (unlikely(parm_disp + parm_count > req->rq_total_parm ||
-+		     parm_offset + parm_count > req->rq_rlen))
- 		goto out_bad_parm;
--	if (data_disp + data_count > req->rq_total_data)
-+	if (unlikely(data_disp + data_count > req->rq_total_data ||
-+		     data_offset + data_count > req->rq_rlen))
- 		goto out_bad_data;
- 
- 	inbuf = req->rq_buffer;
-@@ -666,10 +682,9 @@
- 	return 1;
- 
- out_too_long:
--	printk(KERN_ERR "smb_trans2: data/param too long, data=%d, parm=%d\n",
-+	printk(KERN_ERR "smb_trans2: data/param too long, data=%u, parm=%u\n",
- 		data_tot, parm_tot);
--	req->rq_errno = -EIO;
--	goto out;
-+	goto out_EIO;
- out_no_mem:
- 	printk(KERN_ERR "smb_trans2: couldn't allocate data area of %d bytes\n",
- 	       req->rq_trans2bufsize);
-@@ -677,16 +692,15 @@
- 	goto out;
- out_data_grew:
- 	printk(KERN_ERR "smb_trans2: data/params grew!\n");
--	req->rq_errno = -EIO;
--	goto out;
-+	goto out_EIO;
- out_bad_parm:
--	printk(KERN_ERR "smb_trans2: invalid parms, disp=%d, cnt=%d, tot=%d\n",
--	       parm_disp, parm_count, parm_tot);
--	req->rq_errno = -EIO;
--	goto out;
-+	printk(KERN_ERR "smb_trans2: invalid parms, disp=%u, cnt=%u, tot=%u, ofs=%u\n",
-+	       parm_disp, parm_count, parm_tot, parm_offset);
-+	goto out_EIO;
- out_bad_data:
--	printk(KERN_ERR "smb_trans2: invalid data, disp=%d, cnt=%d, tot=%d\n",
--	       data_disp, data_count, data_tot);
-+	printk(KERN_ERR "smb_trans2: invalid data, disp=%u, cnt=%u, tot=%u, ofs=%u\n",
-+	       data_disp, data_count, data_tot, data_offset);
-+out_EIO:
- 	req->rq_errno = -EIO;
- out:
- 	return req->rq_errno;

Copied: trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/smbfs-overflow-fixes.dpatch (from rev 2592, trunk/kernel/source/kernel-source-2.6.11-2.6.11/debian/patches/smbfs-overflow-fixes-2.dpatch)