All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: Synaptics Touchpad workaround for strange behavior after Sync loss (With Patch).
From: Peter Berg Larsen @ 2004-01-11  2:39 UTC (permalink / raw)
  To: Vojtech Pavlik; +Cc: Gunter Königsmann, linux-kernel
In-Reply-To: <Pine.LNX.4.40.0401102336450.588-100000@shannon.math.ku.dk>


On Sat, 10 Jan 2004, Peter Berg Larsen wrote:

> I dont have a machine with active multiplexing so the the patch is
> untested. It warns when the mouse is removed, and tries to recover
> if multiplexing is disabled.

A lot a have changed since 2.6.0 so here is the patch against 2.6.1:

diff -rup a/include/linux/serio.h b/include/linux/serio.h
--- a/include/linux/serio.h	Sun Oct 20 04:57:23 2002
+++ b/include/linux/serio.h	Sun Oct 20 04:58:32 2002
@@ -99,6 +99,7 @@
 #define SERIO_TIMEOUT	1
 #define SERIO_PARITY	2
 #define SERIO_FRAME	4
+#define SERIO_REMOVED	8

 #define SERIO_TYPE	0xff000000UL
 #define SERIO_XT	0x00000000UL
diff -rup a/drivers/input/serio/i8042.c b/drivers/input/serio/i8042.c
--- a/drivers/input/serio/i8042.c	2004-01-11 03:52:53.000000000 +0100
+++ b/drivers/input/serio/i8042.c	2004-01-11 04:02:34.000000000 +0100
@@ -78,6 +78,7 @@ struct timer_list i8042_timer;
 #define i8042_request_irq_cookie (&i8042_timer)

 static irqreturn_t i8042_interrupt(int irq, void *dev_id, struct pt_regs *regs);
+static int i8042_enable_mux_mode(struct i8042_values *values, unsigned char *mux_version);

 /*
  * The i8042_wait_read() and i8042_wait_write functions wait for the i8042 to
@@ -375,7 +376,7 @@ static irqreturn_t i8042_interrupt(int i
 		int data;
 		int str;
 	} buffer[I8042_BUFFER_SIZE];
-	int i, j = 0;
+	int i, j = 0, mux_failed = 0;

 	spin_lock_irqsave(&i8042_lock, flags);

@@ -397,15 +398,17 @@ static irqreturn_t i8042_interrupt(int i

 			if (str & I8042_STR_MUXERR) {
 				switch (data) {
-					case 0xfd:
+					case 0xfd: dfl = SERIO_REMOVED; break;
 					case 0xfe: dfl = SERIO_TIMEOUT; break;
 					case 0xff: dfl = SERIO_PARITY; break;
+					default: mux_failed = 1;
 				}
 				data = 0xfe;
 			} else dfl = 0;

-			dbg("%02x <- i8042 (interrupt, aux%d, %d%s%s)",
+			dbg("%02x <- i8042 (interrupt, aux%d, %d%s%s%s)",
 				data, (str >> 6), irq,
+				dfl & SERIO_REMOVED ? ", removed" : "",
 				dfl & SERIO_PARITY ? ", bad parity" : "",
 				dfl & SERIO_TIMEOUT ? ", timeout" : "");

@@ -429,6 +432,12 @@ static irqreturn_t i8042_interrupt(int i
 		serio_interrupt(&i8042_kbd_port, data, dfl, regs);
 	}

+	if (mux_failed) {
+		printk(KERN_ERR "i8042.c: Reverted to lagacy aux mode.\n");
+		if (i8042_enable_mux_mode(NULL,NULL))
+			printk(KERN_ERR "i8042.c: Failed to activate mux again.\n");
+	}
+
 	return IRQ_RETVAL(j);
 }



Peter




^ permalink raw reply

* Re: [PATCH] udev - advanced user query options
From: Robert Love @ 2004-01-11  2:37 UTC (permalink / raw)
  To: linux-hotplug
In-Reply-To: <20040111023300.GA4762@vrfy.org>

On Sat, 2004-01-10 at 21:33, Kay Sievers wrote:

> This patch improves the user options for udev.
> It is possible now to query for the name, the symlinks or owner/group.
> If asked for the name of the node we are able to prepend the udev_root
> with the -r option.

Dude, this is some really great work - keep it up!

Stuff like this can be really useful for scripts or debugging.

	Robert Love




-------------------------------------------------------
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html
_______________________________________________
Linux-hotplug-devel mailing list  http://linux-hotplug.sourceforge.net
Linux-hotplug-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel

^ permalink raw reply

* Re: USB hangs
From: Alan Cox @ 2004-01-11  2:33 UTC (permalink / raw)
  To: Matthew Dharm
  Cc: Marcelo Tosatti, Linux Kernel Mailing List, USB Developers,
	Greg KH
In-Reply-To: <20040111002304.GE16484@one-eyed-alien.net>

On Sul, 2004-01-11 at 00:23, Matthew Dharm wrote:
> Where is USB kmalloc'ing with GFP_KERNEL?  I thought we tracked all those
> down and eliminated them.

Not sure. I just worked from tracebacks. I needed it to work rather
than having the time to go hunting for specific faults. Plus I'd
argue PF_MEMALLOC is a better solution anyway.


^ permalink raw reply

* PROBLEM: atkbd.c: Unknown key released (translated set 2, code 0x7a on isa0060/serio0)
From: Murilo Pontes @ 2004-01-10 23:35 UTC (permalink / raw)
  To: linux-kernel


My ABNT-2 keyboard work fine with kernel 2.6.0, but I found two bugs in:
versions:
2.6.1-rc1
2.6.1-rc1-mm1
2.6.1-rc1-mm2
2.6.1-rc2
2.6.1-rc2-mm1
2.6.1-rc3
2.6.1-mm1
2.6.1-mm2


First bug:
My ABNT-2 keyboard not work "/" in console mode, but work fine in X11.
I turnaround problem with "/" near of num lock!
I has see in syslog: atkbd.c: Unknown key released (translated set 2, code 
0x7a on isa0060/serio0)

Second bug:
Loop device not work!

mount $RAMIMAGE $RAMMOUNTDIR -v -t minix -o loop=/dev/loop/0
ioctl: LOOP_SET_FD
losetup -d /dev/loop0
ioctl: LOOP_CLR_FD

23:30:19 [root@murilo:/MRX/tools/mrxcdram]#mount -V
mount: mount-2.12
23:31:00 [root@murilo:/MRX/tools/mrxcdram]#


Thanks for any help!!!!

^ permalink raw reply

* Re: [PATCH(s)][RFC] variable size and signedness issues in ldt.c - potential problem?
From: Jesper Juhl @ 2004-01-11  2:30 UTC (permalink / raw)
  To: Ingo Molnar; +Cc: linux-kernel, Andrew Morton
In-Reply-To: <Pine.LNX.4.58.0401090440180.27298@devserv.devel.redhat.com>


On Fri, 9 Jan 2004, Ingo Molnar wrote:

>
> On Thu, 8 Jan 2004, Jesper Juhl wrote:
>
> > I'm hunting the kernel source for any potential problem I can find (and
> > hopefully fix), and I've come across something that looks like a
> > possible problem in arch/i386/kernel/ldt.c
> >
> > First thing that looks suspicious is this bit in read_ldt() :
> >
> >         for (i = 0; i < size; i += PAGE_SIZE) {
> > 		...
> > 	}
> >
> > 'i' is a plain int while 'size' is an 'unsigned long' leaving the
> > possibility that if size contains a value greater than what a signed int
> > can hold then this code won't do the right thing, either 'i' will wrap
> > around to zero and the loop will never exit or something "unknown" will
> > happen (as far as I know, what happens when an int overflows is
> > implementation defined). [...]
>
> but the user does not control 'newsize'. Can you outline a scenario in
> where the value could overflow?
>

No, I cannot present a scenario where that can actually happen.
I'm not intimately familiar with this code, so I can't say for certain
that I've been down all the possible roads though.
It simply looked suspicious, and the change I suggested ensures with 100%
certainty that it can never happen - I thought that was a good thing and
that's the reason for the proposed patch. If you feel certain that an
overflow can never happen, then I trust that completely and the patch is
thus not needed.


> > The second thing is that in the body of the 'for' loop there is this
> > comparison :
> >
> > if (bytes > PAGE_SIZE)
>
> no, the value of bytes is really limited. Again, can you suggest a
> scenario in where this could overflow?
>
My answer here will have to be a repetition of the one above for the
previous code snippet.


> > I know that the only user of read_ldt() and write_ldt() is
> > sys_modify_ldt() , and the arguments for read_ldt and write_ldt thus
> > have to match sys_modify_ldt, but why is the 'bytecount' argument for
> > sys_modify_ldt an 'unsigned long' and the return type an 'int' ? The
> > signedness of the return type makes sense given that it't supposed to
> > return -1 on error. But on success, in the case where it calls read_ldt,
> > it's supposed to return the actual number of bytes read. But if the
> > number of bytes to read is given as an unsigned long, and the number
> > actually read exceeds the size of a signed int then the return value
> > will get truncated upon return - how can that be right? [...]
>
> LDT size is limited by LDT_ENTRY_SIZE*LDT_ENTRIES. We explicitly truncate
> bytecount to this range so unsigned vs. signed makes no difference.
>
Ok, that's allright then. Thank you for the explanation.


> > [...] And if the return value can never exceed what a signed int can
> > hold, then why is it possible to request an unsigned long amount of
> > bytes to read in the first place?
>
> that's quite common for the interface definitions. Since we are on x86
> unsigned long == unsigned int.
>
Again, thank you for clarifying. I'm learning a lot here and I'm grateful
for your time in answering these basic questions.

One additional thing I noticed in the ldt code is that it seems to me that
there could be some bennefit to moving the declaration of 'bytes' in the
for() loop in read_ldt() outside the loop. It gets initialized by
'bytes = size - i;' every time through the loop before it's used, so I se
no reason to re-create the variable every time through the loop.
If that makes sense, then here's a patch to make this change (it's against
2.6.1-mm1) :

--- linux-2.6.1-mm1-orig/arch/i386/kernel/ldt.c	2004-01-09 19:04:23.000000000 +0100
+++ linux-2.6.1-mm1-juhl/arch/i386/kernel/ldt.c	2004-01-11 03:36:02.000000000 +0100
@@ -118,10 +118,11 @@ void destroy_context(struct mm_struct *m
 	mm->context.size = 0;
 }

-static int read_ldt(void __user * ptr, unsigned long bytecount)
+static int read_ldt(void __user *ptr, unsigned long bytecount)
 {
 	int err, i;
 	unsigned long size;
+	unsigned long bytes;
 	struct mm_struct * mm = current->mm;

 	if (!mm->context.size)
@@ -144,7 +145,7 @@ static int read_ldt(void __user * ptr, u
 	__flush_tlb_global();

 	for (i = 0; i < size; i += PAGE_SIZE) {
-		int nr = i / PAGE_SIZE, bytes;
+		int nr = i / PAGE_SIZE;
 		char *kaddr = kmap(mm->context.ldt_pages[nr]);

 		bytes = size - i;



> > and finally a purely style related thing (sure, call me pedantic); in both
> > read_ldt() and write_ldt() 'mm' is declared as
> >
> > struct mm_struct * mm = current->mm;
>
> yep, you are right, this is the wrong style.
>

Ok, thank you for confirming that.

Since this /is/ incorrect style I've created a patch to clean it up, as
well as a bunch of other instances of the same style issue I found nearby.
I certainly haven't cleaned up *all* instances of this inccorect style,
but I have nailed 26 files with such instances, and I believe I've nailed
all occourances of this style issue in those files.

Patch is below against 2.6.1-mm1 - please consider applying (I've added
Andrew to the CC since this patch is against his tree and you have
confirmed this to be a valid issue).
The patch makes no functional changes - it's purely a coding-style cleanup.



diff -urdp linux-2.6.1-mm1-orig/arch/alpha/kernel/smp.c linux-2.6.1-mm1-juhl/arch/alpha/kernel/smp.c
--- linux-2.6.1-mm1-orig/arch/alpha/kernel/smp.c	2004-01-09 07:59:19.000000000 +0100
+++ linux-2.6.1-mm1-juhl/arch/alpha/kernel/smp.c	2004-01-11 02:02:36.000000000 +0100
@@ -972,7 +972,7 @@ static void
 ipi_flush_tlb_page(void *x)
 {
 	struct flush_tlb_page_struct *data = (struct flush_tlb_page_struct *)x;
-	struct mm_struct * mm = data->mm;
+	struct mm_struct *mm = data->mm;

 	if (mm == current->active_mm && !asn_locked())
 		flush_tlb_current_page(mm, data->vma, data->addr);
diff -urdp linux-2.6.1-mm1-orig/arch/cris/arch-v10/README.mm linux-2.6.1-mm1-juhl/arch/cris/arch-v10/README.mm
--- linux-2.6.1-mm1-orig/arch/cris/arch-v10/README.mm	2004-01-09 08:00:12.000000000 +0100
+++ linux-2.6.1-mm1-juhl/arch/cris/arch-v10/README.mm	2004-01-11 02:01:30.000000000 +0100
@@ -177,7 +177,7 @@ The example address is 0xd004000c; in bi
 Given the top-level Page Directory, the offset in that directory is calculated
 using the upper 8 bits:

-extern inline pgd_t * pgd_offset(struct mm_struct * mm, unsigned long address)
+extern inline pgd_t * pgd_offset(struct mm_struct *mm, unsigned long address)
 {
 	return mm->pgd + (address >> PGDIR_SHIFT);
 }
diff -urdp linux-2.6.1-mm1-orig/arch/i386/kernel/ldt.c linux-2.6.1-mm1-juhl/arch/i386/kernel/ldt.c
--- linux-2.6.1-mm1-orig/arch/i386/kernel/ldt.c	2004-01-09 19:04:23.000000000 +0100
+++ linux-2.6.1-mm1-juhl/arch/i386/kernel/ldt.c	2004-01-11 02:31:16.000000000 +0100
@@ -118,11 +118,11 @@ void destroy_context(struct mm_struct *m
 	mm->context.size = 0;
 }

-static int read_ldt(void __user * ptr, unsigned long bytecount)
+static int read_ldt(void __user *ptr, unsigned long bytecount)
 {
 	int err, i;
 	unsigned long size;
-	struct mm_struct * mm = current->mm;
+	struct mm_struct *mm = current->mm;

 	if (!mm->context.size)
 		return 0;
@@ -164,7 +164,7 @@ static int read_ldt(void __user * ptr, u
 	return bytecount;
 }

-static int read_default_ldt(void __user * ptr, unsigned long bytecount)
+static int read_default_ldt(void __user *ptr, unsigned long bytecount)
 {
 	int err;
 	unsigned long size;
@@ -183,9 +183,9 @@ static int read_default_ldt(void __user
 	return err;
 }

-static int write_ldt(void __user * ptr, unsigned long bytecount, int oldmode)
+static int write_ldt(void __user *ptr, unsigned long bytecount, int oldmode)
 {
-	struct mm_struct * mm = current->mm;
+	struct mm_struct *mm = current->mm;
 	__u32 entry_1, entry_2, *lp;
 	int error;
 	struct user_desc ldt_info;
diff -urdp linux-2.6.1-mm1-orig/arch/i386/kernel/smp.c linux-2.6.1-mm1-juhl/arch/i386/kernel/smp.c
--- linux-2.6.1-mm1-orig/arch/i386/kernel/smp.c	2004-01-09 19:04:24.000000000 +0100
+++ linux-2.6.1-mm1-juhl/arch/i386/kernel/smp.c	2004-01-11 02:00:48.000000000 +0100
@@ -398,7 +398,7 @@ static void flush_tlb_others(cpumask_t c
 	spin_unlock(&tlbstate_lock);
 }

-void flush_tlb_mm (struct mm_struct * mm)
+void flush_tlb_mm(struct mm_struct *mm)
 {
 	cpumask_t cpu_mask;

diff -urdp linux-2.6.1-mm1-orig/arch/i386/mach-voyager/voyager_smp.c linux-2.6.1-mm1-juhl/arch/i386/mach-voyager/voyager_smp.c
--- linux-2.6.1-mm1-orig/arch/i386/mach-voyager/voyager_smp.c	2004-01-09 19:04:24.000000000 +0100
+++ linux-2.6.1-mm1-juhl/arch/i386/mach-voyager/voyager_smp.c	2004-01-11 01:58:46.000000000 +0100
@@ -846,7 +846,7 @@ smp_reschedule_interrupt(void)
 	/* do nothing */
 }

-static struct mm_struct * flush_mm;
+static struct mm_struct *flush_mm;
 static unsigned long flush_va;
 static spinlock_t tlbstate_lock = SPIN_LOCK_UNLOCKED;
 #define FLUSH_ALL	0xffffffff
@@ -963,7 +963,7 @@ flush_tlb_current_task(void)


 void
-flush_tlb_mm (struct mm_struct * mm)
+flush_tlb_mm (struct mm_struct *mm)
 {
 	unsigned long cpu_mask;

diff -urdp linux-2.6.1-mm1-orig/arch/ppc64/xmon/xmon.c linux-2.6.1-mm1-juhl/arch/ppc64/xmon/xmon.c
--- linux-2.6.1-mm1-orig/arch/ppc64/xmon/xmon.c	2004-01-09 07:59:56.000000000 +0100
+++ linux-2.6.1-mm1-juhl/arch/ppc64/xmon/xmon.c	2004-01-11 02:03:11.000000000 +0100
@@ -1909,7 +1909,7 @@ mem_translate()
 	int c;
 	unsigned long ea, va, vsid, vpn, page, hpteg_slot_primary, hpteg_slot_secondary, primary_hash, i, *steg, esid, stabl;
 	HPTE *  hpte;
-	struct mm_struct * mm;
+	struct mm_struct *mm;
 	pte_t  *ptep = NULL;
 	void * pgdir;

diff -urdp linux-2.6.1-mm1-orig/arch/x86_64/kernel/smp.c linux-2.6.1-mm1-juhl/arch/x86_64/kernel/smp.c
--- linux-2.6.1-mm1-orig/arch/x86_64/kernel/smp.c	2004-01-09 19:04:26.000000000 +0100
+++ linux-2.6.1-mm1-juhl/arch/x86_64/kernel/smp.c	2004-01-11 02:04:23.000000000 +0100
@@ -290,7 +290,7 @@ void flush_tlb_current_task(void)
 	preempt_enable();
 }

-void flush_tlb_mm (struct mm_struct * mm)
+void flush_tlb_mm (struct mm_struct *mm)
 {
 	cpumask_t cpu_mask;

diff -urdp linux-2.6.1-mm1-orig/drivers/oprofile/buffer_sync.c linux-2.6.1-mm1-juhl/drivers/oprofile/buffer_sync.c
--- linux-2.6.1-mm1-orig/drivers/oprofile/buffer_sync.c	2004-01-09 07:59:19.000000000 +0100
+++ linux-2.6.1-mm1-juhl/drivers/oprofile/buffer_sync.c	2004-01-11 02:05:14.000000000 +0100
@@ -202,7 +202,7 @@ static inline unsigned long fast_get_dco
  * not strictly necessary but allows oprofile to associate
  * shared-library samples with particular applications
  */
-static unsigned long get_exec_dcookie(struct mm_struct * mm)
+static unsigned long get_exec_dcookie(struct mm_struct *mm)
 {
 	unsigned long cookie = 0;
 	struct vm_area_struct * vma;
@@ -230,7 +230,7 @@ out:
  * sure to do this lookup before a mm->mmap modification happens so
  * we don't lose track.
  */
-static unsigned long lookup_dcookie(struct mm_struct * mm, unsigned long addr, off_t * offset)
+static unsigned long lookup_dcookie(struct mm_struct *mm, unsigned long addr, off_t * offset)
 {
 	unsigned long cookie = 0;
 	struct vm_area_struct * vma;
@@ -301,7 +301,7 @@ static void add_sample_entry(unsigned lo
 }


-static void add_us_sample(struct mm_struct * mm, struct op_sample * s)
+static void add_us_sample(struct mm_struct *mm, struct op_sample * s)
 {
 	unsigned long cookie;
 	off_t offset;
@@ -326,7 +326,7 @@ static void add_us_sample(struct mm_stru
  * sample is converted into a persistent dentry/offset pair
  * for later lookup from userspace.
  */
-static void add_sample(struct mm_struct * mm, struct op_sample * s, int in_kernel)
+static void add_sample(struct mm_struct *mm, struct op_sample * s, int in_kernel)
 {
 	if (in_kernel) {
 		add_sample_entry(s->eip, s->event);
@@ -338,7 +338,7 @@ static void add_sample(struct mm_struct
 }


-static void release_mm(struct mm_struct * mm)
+static void release_mm(struct mm_struct *mm)
 {
 	if (mm)
 		up_read(&mm->mmap_sem);
@@ -350,7 +350,7 @@ static void release_mm(struct mm_struct
  */
 static struct mm_struct * take_tasks_mm(struct task_struct * task)
 {
-	struct mm_struct * mm;
+	struct mm_struct *mm;

 	/* Subtle. We don't need to keep a reference to this task's mm,
 	 * because, for the mm to be freed on another CPU, that would have
@@ -425,8 +425,8 @@ static void increment_tail(struct oprofi
  */
 static void sync_buffer(struct oprofile_cpu_buffer * cpu_buf)
 {
-	struct mm_struct * mm = 0;
-	struct task_struct * new;
+	struct mm_struct *mm = 0;
+	struct task_struct *new;
 	unsigned long cookie = 0;
 	int in_kernel = 1;
 	unsigned int i;
diff -urdp linux-2.6.1-mm1-orig/fs/proc/base.c linux-2.6.1-mm1-juhl/fs/proc/base.c
--- linux-2.6.1-mm1-orig/fs/proc/base.c	2004-01-09 19:04:31.000000000 +0100
+++ linux-2.6.1-mm1-juhl/fs/proc/base.c	2004-01-11 01:52:10.000000000 +0100
@@ -215,7 +215,7 @@ static int proc_exe_link(struct inode *i
 	struct vm_area_struct * vma;
 	int result = -ENOENT;
 	struct task_struct *task = proc_task(inode);
-	struct mm_struct * mm = get_task_mm(task);
+	struct mm_struct *mm = get_task_mm(task);

 	if (!mm)
 		goto out;
diff -urdp linux-2.6.1-mm1-orig/include/asm-alpha/mmu_context.h linux-2.6.1-mm1-juhl/include/asm-alpha/mmu_context.h
--- linux-2.6.1-mm1-orig/include/asm-alpha/mmu_context.h	2004-01-09 07:59:34.000000000 +0100
+++ linux-2.6.1-mm1-juhl/include/asm-alpha/mmu_context.h	2004-01-11 02:10:28.000000000 +0100
@@ -187,7 +187,7 @@ do {								\
 	cpu_data[cpu].asn_lock = 0;				\
 	barrier();						\
 	if (cpu_data[cpu].need_new_asn) {			\
-		struct mm_struct * mm = current->active_mm;	\
+		struct mm_struct *mm = current->active_mm;	\
 		cpu_data[cpu].need_new_asn = 0;			\
 		if (!mm->context[cpu])			\
 			__load_new_mm_context(mm);		\
diff -urdp linux-2.6.1-mm1-orig/include/asm-alpha/tlbflush.h linux-2.6.1-mm1-juhl/include/asm-alpha/tlbflush.h
--- linux-2.6.1-mm1-orig/include/asm-alpha/tlbflush.h	2004-01-09 07:59:02.000000000 +0100
+++ linux-2.6.1-mm1-juhl/include/asm-alpha/tlbflush.h	2004-01-11 02:10:59.000000000 +0100
@@ -33,7 +33,7 @@ ev5_flush_tlb_current(struct mm_struct *
    specific icache page.  */

 __EXTERN_INLINE void
-ev4_flush_tlb_current_page(struct mm_struct * mm,
+ev4_flush_tlb_current_page(struct mm_struct *mm,
 			   struct vm_area_struct *vma,
 			   unsigned long addr)
 {
@@ -46,7 +46,7 @@ ev4_flush_tlb_current_page(struct mm_str
 }

 __EXTERN_INLINE void
-ev5_flush_tlb_current_page(struct mm_struct * mm,
+ev5_flush_tlb_current_page(struct mm_struct *mm,
 			   struct vm_area_struct *vma,
 			   unsigned long addr)
 {
diff -urdp linux-2.6.1-mm1-orig/include/asm-arm26/rmap.h linux-2.6.1-mm1-juhl/include/asm-arm26/rmap.h
--- linux-2.6.1-mm1-orig/include/asm-arm26/rmap.h	2004-01-09 07:59:26.000000000 +0100
+++ linux-2.6.1-mm1-juhl/include/asm-arm26/rmap.h	2004-01-11 02:12:00.000000000 +0100
@@ -12,7 +12,7 @@
  * page tables and the last 2 kB are the software page tables.
  */

-static inline void pgtable_add_rmap(struct page *page, struct mm_struct * mm, unsigned long address)
+static inline void pgtable_add_rmap(struct page *page, struct mm_struct *mm, unsigned long address)
 {
         page->mapping = (void *)mm;
         page->index = address & ~((PTRS_PER_PTE * PAGE_SIZE) - 1);
@@ -28,16 +28,16 @@ static inline void pgtable_remove_rmap(s

 static inline struct mm_struct * ptep_to_mm(pte_t * ptep)
 {
-	struct page * page = virt_to_page(ptep);
+	struct page *page = virt_to_page(ptep);
         return (struct mm_struct *)page->mapping;
 }

 /* The page table takes half of the page */
 #define PTE_MASK  ((PAGE_SIZE / 2) - 1)

-static inline unsigned long ptep_to_address(pte_t * ptep)
+static inline unsigned long ptep_to_address(pte_t *ptep)
 {
-        struct page * page = virt_to_page(ptep);
+        struct page *page = virt_to_page(ptep);
         unsigned long low_bits;

         low_bits = ((unsigned long)ptep & PTE_MASK) * PTRS_PER_PTE;
diff -urdp linux-2.6.1-mm1-orig/include/asm-cris/pgtable.h linux-2.6.1-mm1-juhl/include/asm-cris/pgtable.h
--- linux-2.6.1-mm1-orig/include/asm-cris/pgtable.h	2004-01-09 07:59:05.000000000 +0100
+++ linux-2.6.1-mm1-juhl/include/asm-cris/pgtable.h	2004-01-11 02:38:27.000000000 +0100
@@ -257,7 +257,7 @@ extern inline unsigned long __pte_page(p
  * don't need the __pa and __va transformations.
  */

-extern inline void pmd_set(pmd_t * pmdp, pte_t * ptep)
+extern inline void pmd_set(pmd_t *pmdp, pte_t *ptep)
 { pmd_val(*pmdp) = _PAGE_TABLE | (unsigned long) ptep; }

 #define pmd_page(pmd)		(pfn_to_page(pmd_val(pmd) >> PAGE_SHIFT))
@@ -267,7 +267,7 @@ extern inline void pmd_set(pmd_t * pmdp,
 #define pgd_index(address) ((address >> PGDIR_SHIFT) & (PTRS_PER_PGD-1))

 /* to find an entry in a page-table-directory */
-extern inline pgd_t * pgd_offset(struct mm_struct * mm, unsigned long address)
+extern inline pgd_t *pgd_offset(struct mm_struct *mm, unsigned long address)
 {
 	return mm->pgd + pgd_index(address);
 }
@@ -276,7 +276,7 @@ extern inline pgd_t * pgd_offset(struct
 #define pgd_offset_k(address) pgd_offset(&init_mm, address)

 /* Find an entry in the second-level page table.. */
-extern inline pmd_t * pmd_offset(pgd_t * dir, unsigned long address)
+extern inline pmd_t *pmd_offset(pgd_t *dir, unsigned long address)
 {
 	return (pmd_t *) dir;
 }
diff -urdp linux-2.6.1-mm1-orig/include/asm-generic/rmap.h linux-2.6.1-mm1-juhl/include/asm-generic/rmap.h
--- linux-2.6.1-mm1-orig/include/asm-generic/rmap.h	2004-01-09 07:59:44.000000000 +0100
+++ linux-2.6.1-mm1-juhl/include/asm-generic/rmap.h	2004-01-11 02:40:01.000000000 +0100
@@ -26,7 +26,7 @@
  */
 #include <linux/mm.h>

-static inline void pgtable_add_rmap(struct page * page, struct mm_struct * mm, unsigned long address)
+static inline void pgtable_add_rmap(struct page *page, struct mm_struct *mm, unsigned long address)
 {
 #ifdef BROKEN_PPC_PTE_ALLOC_ONE
 	/* OK, so PPC calls pte_alloc() before mem_map[] is setup ... ;( */
@@ -40,22 +40,22 @@ static inline void pgtable_add_rmap(stru
 	inc_page_state(nr_page_table_pages);
 }

-static inline void pgtable_remove_rmap(struct page * page)
+static inline void pgtable_remove_rmap(struct page *page)
 {
 	page->mapping = NULL;
 	page->index = 0;
 	dec_page_state(nr_page_table_pages);
 }

-static inline struct mm_struct * ptep_to_mm(pte_t * ptep)
+static inline struct mm_struct *ptep_to_mm(pte_t *ptep)
 {
-	struct page * page = kmap_atomic_to_page(ptep);
+	struct page *page = kmap_atomic_to_page(ptep);
 	return (struct mm_struct *) page->mapping;
 }

-static inline unsigned long ptep_to_address(pte_t * ptep)
+static inline unsigned long ptep_to_address(pte_t *ptep)
 {
-	struct page * page = kmap_atomic_to_page(ptep);
+	struct page *page = kmap_atomic_to_page(ptep);
 	unsigned long low_bits;
 	low_bits = ((unsigned long)ptep & ~PAGE_MASK) * PTRS_PER_PTE;
 	return page->index + low_bits;
diff -urdp linux-2.6.1-mm1-orig/include/linux/mm.h linux-2.6.1-mm1-juhl/include/linux/mm.h
--- linux-2.6.1-mm1-orig/include/linux/mm.h	2004-01-09 19:04:32.000000000 +0100
+++ linux-2.6.1-mm1-juhl/include/linux/mm.h	2004-01-11 02:40:53.000000000 +0100
@@ -608,17 +608,17 @@ unsigned long max_sane_readahead(unsigne
 extern int expand_stack(struct vm_area_struct * vma, unsigned long address);

 /* Look up the first VMA which satisfies  addr < vm_end,  NULL if none. */
-extern struct vm_area_struct * find_vma(struct mm_struct * mm, unsigned long addr);
-extern struct vm_area_struct * find_vma_prev(struct mm_struct * mm, unsigned long addr,
+extern struct vm_area_struct *find_vma(struct mm_struct *mm, unsigned long addr);
+extern struct vm_area_struct *find_vma_prev(struct mm_struct *mm, unsigned long addr,
 					     struct vm_area_struct **pprev);
-extern int split_vma(struct mm_struct * mm, struct vm_area_struct * vma,
+extern int split_vma(struct mm_struct *mm, struct vm_area_struct *vma,
 		     unsigned long addr, int new_below);

 /* Look up the first VMA which intersects the interval start_addr..end_addr-1,
    NULL if none.  Assume start_addr < end_addr. */
-static inline struct vm_area_struct * find_vma_intersection(struct mm_struct * mm, unsigned long start_addr, unsigned long end_addr)
+static inline struct vm_area_struct *find_vma_intersection(struct mm_struct *mm, unsigned long start_addr, unsigned long end_addr)
 {
-	struct vm_area_struct * vma = find_vma(mm,start_addr);
+	struct vm_area_struct *vma = find_vma(mm,start_addr);

 	if (vma && end_addr <= vma->vm_start)
 		vma = NULL;
@@ -629,8 +629,8 @@ extern struct vm_area_struct *find_exten

 extern unsigned int nr_used_zone_pages(void);

-extern struct page * vmalloc_to_page(void *addr);
-extern struct page * follow_page(struct mm_struct *mm, unsigned long address,
+extern struct page *vmalloc_to_page(void *addr);
+extern struct page *follow_page(struct mm_struct *mm, unsigned long address,
 		int write);
 extern int remap_page_range(struct vm_area_struct *vma, unsigned long from,
 		unsigned long to, unsigned long size, pgprot_t prot);
diff -urdp linux-2.6.1-mm1-orig/include/linux/profile.h linux-2.6.1-mm1-juhl/include/linux/profile.h
--- linux-2.6.1-mm1-orig/include/linux/profile.h	2004-01-09 07:59:33.000000000 +0100
+++ linux-2.6.1-mm1-juhl/include/linux/profile.h	2004-01-11 02:09:08.000000000 +0100
@@ -33,34 +33,34 @@ struct task_struct;
 struct mm_struct;

 /* task is in do_exit() */
-void profile_exit_task(struct task_struct * task);
+void profile_exit_task(struct task_struct *task);

 /* change of vma mappings */
-void profile_exec_unmap(struct mm_struct * mm);
+void profile_exec_unmap(struct mm_struct *mm);

 /* exit of all vmas for a task */
-void profile_exit_mmap(struct mm_struct * mm);
+void profile_exit_mmap(struct mm_struct *mm);

-int profile_event_register(enum profile_type, struct notifier_block * n);
+int profile_event_register(enum profile_type, struct notifier_block *n);

-int profile_event_unregister(enum profile_type, struct notifier_block * n);
+int profile_event_unregister(enum profile_type, struct notifier_block *n);

-int register_profile_notifier(struct notifier_block * nb);
-int unregister_profile_notifier(struct notifier_block * nb);
+int register_profile_notifier(struct notifier_block *nb);
+int unregister_profile_notifier(struct notifier_block *nb);

 struct pt_regs;

 /* profiling hook activated on each timer interrupt */
-void profile_hook(struct pt_regs * regs);
+void profile_hook(struct pt_regs *regs);

 #else

-static inline int profile_event_register(enum profile_type t, struct notifier_block * n)
+static inline int profile_event_register(enum profile_type t, struct notifier_block *n)
 {
 	return -ENOSYS;
 }

-static inline int profile_event_unregister(enum profile_type t, struct notifier_block * n)
+static inline int profile_event_unregister(enum profile_type t, struct notifier_block *n)
 {
 	return -ENOSYS;
 }
@@ -69,12 +69,12 @@ static inline int profile_event_unregist
 #define profile_exec_unmap(a) do { } while (0)
 #define profile_exit_mmap(a) do { } while (0)

-static inline int register_profile_notifier(struct notifier_block * nb)
+static inline int register_profile_notifier(struct notifier_block *nb)
 {
 	return -ENOSYS;
 }

-static inline int unregister_profile_notifier(struct notifier_block * nb)
+static inline int unregister_profile_notifier(struct notifier_block *nb)
 {
 	return -ENOSYS;
 }
diff -urdp linux-2.6.1-mm1-orig/include/linux/sched.h linux-2.6.1-mm1-juhl/include/linux/sched.h
--- linux-2.6.1-mm1-orig/include/linux/sched.h	2004-01-09 19:04:32.000000000 +0100
+++ linux-2.6.1-mm1-juhl/include/linux/sched.h	2004-01-11 02:43:04.000000000 +0100
@@ -184,11 +184,11 @@ struct namespace;
 #include <linux/aio.h>

 struct mm_struct {
-	struct vm_area_struct * mmap;		/* list of VMAs */
+	struct vm_area_struct *mmap;		/* list of VMAs */
 	struct rb_root mm_rb;
-	struct vm_area_struct * mmap_cache;	/* last find_vma result */
+	struct vm_area_struct *mmap_cache;	/* last find_vma result */
 	unsigned long free_area_cache;		/* first hole */
-	pgd_t * pgd;
+	pgd_t *pgd;
 	atomic_t mm_users;			/* How many users with user space? */
 	atomic_t mm_count;			/* How many references to "struct mm_struct" (users count as 1) */
 	int map_count;				/* number of VMAs */
@@ -675,11 +675,11 @@ static inline int capable(int cap)
 /*
  * Routines for handling mm_structs
  */
-extern struct mm_struct * mm_alloc(void);
+extern struct mm_struct *mm_alloc(void);

 /* mmdrop drops the mm and the page tables */
 extern inline void FASTCALL(__mmdrop(struct mm_struct *));
-static inline void mmdrop(struct mm_struct * mm)
+static inline void mmdrop(struct mm_struct *mm)
 {
 	if (atomic_dec_and_test(&mm->mm_count))
 		__mmdrop(mm);
@@ -717,7 +717,7 @@ extern long do_fork(unsigned long, unsig
 extern struct task_struct * copy_process(unsigned long, unsigned long, struct pt_regs *, unsigned long, int __user *, int __user *);

 #ifdef CONFIG_SMP
-extern void wait_task_inactive(task_t * p);
+extern void wait_task_inactive(task_t *p);
 #else
 #define wait_task_inactive(p)	do { } while (0)
 #endif
@@ -790,9 +790,9 @@ static inline void task_unlock(struct ta
  * Returns %NULL if the task has no mm. User must release
  * the mm via mmput() after use.
  */
-static inline struct mm_struct * get_task_mm(struct task_struct * task)
+static inline struct mm_struct *get_task_mm(struct task_struct *task)
 {
-	struct mm_struct * mm;
+	struct mm_struct *mm;

 	task_lock(task);
 	mm = task->mm;
diff -urdp linux-2.6.1-mm1-orig/kernel/fork.c linux-2.6.1-mm1-juhl/kernel/fork.c
--- linux-2.6.1-mm1-orig/kernel/fork.c	2004-01-09 19:04:32.000000000 +0100
+++ linux-2.6.1-mm1-juhl/kernel/fork.c	2004-01-11 02:45:12.000000000 +0100
@@ -270,9 +270,9 @@ static struct task_struct *dup_task_stru
 }

 #ifdef CONFIG_MMU
-static inline int dup_mmap(struct mm_struct * mm, struct mm_struct * oldmm)
+static inline int dup_mmap(struct mm_struct *mm, struct mm_struct * oldmm)
 {
-	struct vm_area_struct * mpnt, *tmp, **pprev;
+	struct vm_area_struct *mpnt, *tmp, **pprev;
 	int retval;
 	unsigned long charge = 0;

@@ -360,7 +360,7 @@ fail:
 	vm_unacct_memory(charge);
 	goto out;
 }
-static inline int mm_alloc_pgd(struct mm_struct * mm)
+static inline int mm_alloc_pgd(struct mm_struct *mm)
 {
 	mm->pgd = pgd_alloc(mm);
 	if (unlikely(!mm->pgd))
@@ -368,7 +368,7 @@ static inline int mm_alloc_pgd(struct mm
 	return 0;
 }

-static inline void mm_free_pgd(struct mm_struct * mm)
+static inline void mm_free_pgd(struct mm_struct *mm)
 {
 	pgd_free(mm->pgd);
 }
@@ -386,7 +386,7 @@ int mmlist_nr;

 #include <linux/init_task.h>

-static struct mm_struct * mm_init(struct mm_struct * mm)
+static struct mm_struct *mm_init(struct mm_struct *mm)
 {
 	atomic_set(&mm->mm_users, 1);
 	atomic_set(&mm->mm_count, 1);
@@ -409,9 +409,9 @@ static struct mm_struct * mm_init(struct
 /*
  * Allocate and initialize an mm_struct.
  */
-struct mm_struct * mm_alloc(void)
+struct mm_struct *mm_alloc(void)
 {
-	struct mm_struct * mm;
+	struct mm_struct *mm;

 	mm = allocate_mm();
 	if (mm) {
@@ -504,9 +504,9 @@ void mm_release(struct task_struct *tsk,
 	}
 }

-static int copy_mm(unsigned long clone_flags, struct task_struct * tsk)
+static int copy_mm(unsigned long clone_flags, struct task_struct *tsk)
 {
-	struct mm_struct * mm, *oldmm;
+	struct mm_struct *mm, *oldmm;
 	int retval;

 	tsk->min_flt = tsk->maj_flt = 0;
@@ -608,7 +608,7 @@ struct fs_struct *copy_fs_struct(struct

 EXPORT_SYMBOL_GPL(copy_fs_struct);

-static inline int copy_fs(unsigned long clone_flags, struct task_struct * tsk)
+static inline int copy_fs(unsigned long clone_flags, struct task_struct *tsk)
 {
 	if (clone_flags & CLONE_FS) {
 		atomic_inc(&current->fs->count);
@@ -633,7 +633,7 @@ static int count_open_files(struct files
 	return i;
 }

-static int copy_files(unsigned long clone_flags, struct task_struct * tsk)
+static int copy_files(unsigned long clone_flags, struct task_struct *tsk)
 {
 	struct files_struct *oldf, *newf;
 	struct file **old_fds, **new_fds;
@@ -774,7 +774,7 @@ int unshare_files(void)

 EXPORT_SYMBOL(unshare_files);

-static inline int copy_sighand(unsigned long clone_flags, struct task_struct * tsk)
+static inline int copy_sighand(unsigned long clone_flags, struct task_struct *tsk)
 {
 	struct sighand_struct *sig;

@@ -792,7 +792,7 @@ static inline int copy_sighand(unsigned
 	return 0;
 }

-static inline int copy_signal(unsigned long clone_flags, struct task_struct * tsk)
+static inline int copy_signal(unsigned long clone_flags, struct task_struct *tsk)
 {
 	struct signal_struct *sig;

diff -urdp linux-2.6.1-mm1-orig/kernel/profile.c linux-2.6.1-mm1-juhl/kernel/profile.c
--- linux-2.6.1-mm1-orig/kernel/profile.c	2004-01-09 08:00:03.000000000 +0100
+++ linux-2.6.1-mm1-juhl/kernel/profile.c	2004-01-11 02:06:35.000000000 +0100
@@ -58,14 +58,14 @@ void profile_exit_task(struct task_struc
 	up_read(&profile_rwsem);
 }

-void profile_exit_mmap(struct mm_struct * mm)
+void profile_exit_mmap(struct mm_struct *mm)
 {
 	down_read(&profile_rwsem);
 	notifier_call_chain(&exit_mmap_notifier, 0, mm);
 	up_read(&profile_rwsem);
 }

-void profile_exec_unmap(struct mm_struct * mm)
+void profile_exec_unmap(struct mm_struct *mm)
 {
 	down_read(&profile_rwsem);
 	notifier_call_chain(&exec_unmap_notifier, 0, mm);
diff -urdp linux-2.6.1-mm1-orig/mm/madvise.c linux-2.6.1-mm1-juhl/mm/madvise.c
--- linux-2.6.1-mm1-orig/mm/madvise.c	2004-01-09 19:04:32.000000000 +0100
+++ linux-2.6.1-mm1-juhl/mm/madvise.c	2004-01-11 01:52:52.000000000 +0100
@@ -16,7 +16,7 @@
 static long madvise_behavior(struct vm_area_struct * vma, unsigned long start,
 			     unsigned long end, int behavior)
 {
-	struct mm_struct * mm = vma->vm_mm;
+	struct mm_struct *mm = vma->vm_mm;
 	int error;

 	if (start != vma->vm_start) {
diff -urdp linux-2.6.1-mm1-orig/mm/mlock.c linux-2.6.1-mm1-juhl/mm/mlock.c
--- linux-2.6.1-mm1-orig/mm/mlock.c	2004-01-09 07:59:07.000000000 +0100
+++ linux-2.6.1-mm1-juhl/mm/mlock.c	2004-01-11 01:53:16.000000000 +0100
@@ -12,7 +12,7 @@
 static int mlock_fixup(struct vm_area_struct * vma,
 	unsigned long start, unsigned long end, unsigned int newflags)
 {
-	struct mm_struct * mm = vma->vm_mm;
+	struct mm_struct *mm = vma->vm_mm;
 	int pages;
 	int ret = 0;

diff -urdp linux-2.6.1-mm1-orig/mm/mmap.c linux-2.6.1-mm1-juhl/mm/mmap.c
--- linux-2.6.1-mm1-orig/mm/mmap.c	2004-01-09 19:04:32.000000000 +0100
+++ linux-2.6.1-mm1-juhl/mm/mmap.c	2004-01-11 02:49:25.000000000 +0100
@@ -147,7 +147,7 @@ static int browse_rb(struct rb_node * rb
 	return i;
 }

-static void validate_mm(struct mm_struct * mm) {
+static void validate_mm(struct mm_struct *mm) {
 	int bug = 0;
 	int i = 0;
 	struct vm_area_struct * tmp = mm->mmap;
@@ -284,7 +284,7 @@ static void vma_link(struct mm_struct *m
  * ->f_mappping->i_shared_sem if vm_file is non-NULL.
  */
 static void
-__insert_vm_struct(struct mm_struct * mm, struct vm_area_struct * vma)
+__insert_vm_struct(struct mm_struct *mm, struct vm_area_struct * vma)
 {
 	struct vm_area_struct * __vma, * prev;
 	struct rb_node ** rb_link, * rb_parent;
@@ -464,13 +464,13 @@ unsigned long do_mmap_pgoff(struct file
 			unsigned long len, unsigned long prot,
 			unsigned long flags, unsigned long pgoff)
 {
-	struct mm_struct * mm = current->mm;
-	struct vm_area_struct * vma, * prev;
+	struct mm_struct *mm = current->mm;
+	struct vm_area_struct *vma, *prev;
 	struct inode *inode;
 	unsigned int vm_flags;
 	int correct_wcount = 0;
 	int error;
-	struct rb_node ** rb_link, * rb_parent;
+	struct rb_node **rb_link, *rb_parent;
 	unsigned long charged = 0;

 	if (file) {
@@ -815,7 +815,7 @@ get_unmapped_area(struct file *file, uns
 EXPORT_SYMBOL(get_unmapped_area);

 /* Look up the first VMA which satisfies  addr < vm_end,  NULL if none. */
-struct vm_area_struct * find_vma(struct mm_struct * mm, unsigned long addr)
+struct vm_area_struct *find_vma(struct mm_struct *mm, unsigned long addr)
 {
 	struct vm_area_struct *vma = NULL;

@@ -858,7 +858,7 @@ find_vma_prev(struct mm_struct *mm, unsi
 			struct vm_area_struct **pprev)
 {
 	struct vm_area_struct *vma = NULL, *prev = NULL;
-	struct rb_node * rb_node;
+	struct rb_node *rb_node;
 	if (!mm)
 		goto out;

@@ -985,9 +985,9 @@ int expand_stack(struct vm_area_struct *
 }

 struct vm_area_struct *
-find_extend_vma(struct mm_struct * mm, unsigned long addr)
+find_extend_vma(struct mm_struct *mm, unsigned long addr)
 {
-	struct vm_area_struct * vma;
+	struct vm_area_struct *vma;
 	unsigned long start;

 	addr &= PAGE_MASK;
@@ -1173,7 +1173,7 @@ detach_vmas_to_be_unmapped(struct mm_str
  * Split a vma into two pieces at address 'addr', a new vma is allocated
  * either for the first part or the the tail.
  */
-int split_vma(struct mm_struct * mm, struct vm_area_struct * vma,
+int split_vma(struct mm_struct *mm, struct vm_area_struct *vma,
 	      unsigned long addr, int new_below)
 {
 	struct vm_area_struct *new;
@@ -1319,10 +1319,10 @@ asmlinkage long sys_munmap(unsigned long
  */
 unsigned long do_brk(unsigned long addr, unsigned long len)
 {
-	struct mm_struct * mm = current->mm;
-	struct vm_area_struct * vma, * prev;
+	struct mm_struct *mm = current->mm;
+	struct vm_area_struct *vma, *prev;
 	unsigned long flags;
-	struct rb_node ** rb_link, * rb_parent;
+	struct rb_node ** rb_link, *rb_parent;

 	len = PAGE_ALIGN(len);
 	if (!len)
@@ -1404,10 +1404,10 @@ out:
 EXPORT_SYMBOL(do_brk);

 /* Build the RB tree corresponding to the VMA list. */
-void build_mmap_rb(struct mm_struct * mm)
+void build_mmap_rb(struct mm_struct *mm)
 {
-	struct vm_area_struct * vma;
-	struct rb_node ** rb_link, * rb_parent;
+	struct vm_area_struct *vma;
+	struct rb_node **rb_link, *rb_parent;

 	mm->mm_rb = RB_ROOT;
 	rb_link = &mm->mm_rb.rb_node;
@@ -1473,10 +1473,10 @@ void exit_mmap(struct mm_struct *mm)
  * and into the inode's i_mmap ring.  If vm_file is non-NULL
  * then i_shared_sem is taken here.
  */
-void insert_vm_struct(struct mm_struct * mm, struct vm_area_struct * vma)
+void insert_vm_struct(struct mm_struct *mm, struct vm_area_struct * vma)
 {
-	struct vm_area_struct * __vma, * prev;
-	struct rb_node ** rb_link, * rb_parent;
+	struct vm_area_struct *__vma, *prev;
+	struct rb_node **rb_link, *rb_parent;

 	__vma = find_vma_prepare(mm,vma->vm_start,&prev,&rb_link,&rb_parent);
 	if (__vma && __vma->vm_start < vma->vm_end)
diff -urdp linux-2.6.1-mm1-orig/mm/mprotect.c linux-2.6.1-mm1-juhl/mm/mprotect.c
--- linux-2.6.1-mm1-orig/mm/mprotect.c	2004-01-09 07:59:26.000000000 +0100
+++ linux-2.6.1-mm1-juhl/mm/mprotect.c	2004-01-11 01:53:41.000000000 +0100
@@ -114,7 +114,7 @@ static int
 mprotect_attempt_merge(struct vm_area_struct *vma, struct vm_area_struct *prev,
 		unsigned long end, int newflags)
 {
-	struct mm_struct * mm = vma->vm_mm;
+	struct mm_struct *mm = vma->vm_mm;

 	if (!prev || !vma)
 		return 0;
@@ -154,7 +154,7 @@ static int
 mprotect_fixup(struct vm_area_struct *vma, struct vm_area_struct **pprev,
 	unsigned long start, unsigned long end, unsigned int newflags)
 {
-	struct mm_struct * mm = vma->vm_mm;
+	struct mm_struct *mm = vma->vm_mm;
 	unsigned long charged = 0;
 	pgprot_t newprot;
 	int error;
diff -urdp linux-2.6.1-mm1-orig/mm/nommu.c linux-2.6.1-mm1-juhl/mm/nommu.c
--- linux-2.6.1-mm1-orig/mm/nommu.c	2004-01-09 19:04:32.000000000 +0100
+++ linux-2.6.1-mm1-juhl/mm/nommu.c	2004-01-11 01:56:15.000000000 +0100
@@ -436,9 +436,9 @@ unsigned long do_mmap_pgoff(
 	return (unsigned long)result;
 }

-int do_munmap(struct mm_struct * mm, unsigned long addr, size_t len)
+int do_munmap(struct mm_struct *mm, unsigned long addr, size_t len)
 {
-	struct mm_tblock_struct * tblock, *tmp;
+	struct mm_tblock_struct *tblock, *tmp;

 #ifdef MAGIC_ROM_PTR
 	/*
@@ -489,7 +489,7 @@ int do_munmap(struct mm_struct * mm, uns
 }

 /* Release all mmaps. */
-void exit_mmap(struct mm_struct * mm)
+void exit_mmap(struct mm_struct *mm)
 {
 	struct mm_tblock_struct *tmp;

@@ -541,7 +541,7 @@ unsigned long do_brk(unsigned long addr,
 	return -ENOMEM;
 }

-struct vm_area_struct * find_vma(struct mm_struct * mm, unsigned long addr)
+struct vm_area_struct * find_vma(struct mm_struct *mm, unsigned long addr)
 {
 	return NULL;
 }
diff -urdp linux-2.6.1-mm1-orig/mm/rmap.c linux-2.6.1-mm1-juhl/mm/rmap.c
--- linux-2.6.1-mm1-orig/mm/rmap.c	2004-01-09 19:04:32.000000000 +0100
+++ linux-2.6.1-mm1-juhl/mm/rmap.c	2004-01-11 01:56:39.000000000 +0100
@@ -297,7 +297,7 @@ static int try_to_unmap_one(struct page
 {
 	pte_t *ptep = rmap_ptep_map(paddr);
 	unsigned long address = ptep_to_address(ptep);
-	struct mm_struct * mm = ptep_to_mm(ptep);
+	struct mm_struct *mm = ptep_to_mm(ptep);
 	struct vm_area_struct * vma;
 	pte_t pte;
 	int ret;
diff -urdp linux-2.6.1-mm1-orig/mm/swapfile.c linux-2.6.1-mm1-juhl/mm/swapfile.c
--- linux-2.6.1-mm1-orig/mm/swapfile.c	2004-01-09 19:04:32.000000000 +0100
+++ linux-2.6.1-mm1-juhl/mm/swapfile.c	2004-01-11 01:57:01.000000000 +0100
@@ -485,7 +485,7 @@ static int unuse_vma(struct vm_area_stru
 	return 0;
 }

-static int unuse_process(struct mm_struct * mm,
+static int unuse_process(struct mm_struct *mm,
 			swp_entry_t entry, struct page* page)
 {
 	struct vm_area_struct* vma;




Kind regards,

Jesper Juhl



^ permalink raw reply

* [PATCH] udev - advanced user query options
From: Kay Sievers @ 2004-01-11  2:33 UTC (permalink / raw)
  To: linux-hotplug

[-- Attachment #1: Type: text/plain, Size: 949 bytes --]

This patch improves the user options for udev.
It is possible now to query for the name, the symlinks or owner/group.
If asked for the name of the node we are able to prepend the udev_root
with the -r option.

SAMPLE:

  kay@pim:~/src/udev.test$ ./udev -V
  udev, version 012_bk

  kay@pim:~/src/udev.test$ ./udev -h
  Usage: [-qrVh]
    -q <name>  query database for the specified value
    -p <path>  device path used for query
    -r         print udev root
    -V         print udev version
    -h         print this help text

  kay@pim:~/src/udev.test$ ./udev -r
  /udev/

  kay@pim:~/src/udev.test$ ./udev -q name -p /class/video4linux/video0
  video/webcam0

  kay@pim:~/src/udev.test$ ./udev -q symlink -p /class/video4linux/video0
  camera0 kamera0

  kay@pim:~/src/udev.test$ ./udev -q owner -p /class/video4linux/video0
  501

  kay@pim:~/src/udev.test$ ./udev -r -q name -p /class/video4linux/video0
  /udev/video/webcam0


thanks,
Kay

[-- Attachment #2: 02-more-user-options.diff --]
[-- Type: text/plain, Size: 3070 bytes --]

diff -Nru a/udev.c b/udev.c
--- a/udev.c	Sun Jan 11 03:31:19 2004
+++ b/udev.c	Sun Jan 11 03:31:19 2004
@@ -82,13 +82,26 @@
 	return seqnum;
 }
 
+enum query_type {
+	NONE,
+	NAME,
+	SYMLINK,
+	OWNER,
+	GROUP
+};
+
 static inline int udev_user(int argc, char **argv)
 {
-	static const char short_options[] = "q:rVh";
+	static const char short_options[] = "p:q:rVh";
 	int option;
 	int retval = -EINVAL;
 	struct udevice dev;
+	int root = 0;
+	enum query_type query = NONE;
+	char result[NAME_SIZE] = "";
+	char path[NAME_SIZE] = "";
 
+	/* get command line options */
 	while (1) {
 		option = getopt(argc, argv, short_options);
 		if (option == -1)
@@ -96,25 +109,40 @@
 
 		dbg("option '%c'", option);
 		switch (option) {
+		case 'p':
+			dbg("udev path: %s\n", optarg);
+			strfieldcpy(path, optarg);
+			break;
+
 		case 'q':
 			dbg("udev query: %s\n", optarg);
-			retval = udevdb_open_ro();
-			if (retval != 0) {
-				printf("unable to open udev database\n");
-				return -1;
+
+			if (strcmp(optarg, "name") == 0) {
+				query = NAME;
+				break;
+			}
+
+			if (strcmp(optarg, "symlink") == 0) {
+				query = SYMLINK;
+				break;
 			}
-			retval = udevdb_get_dev(optarg, &dev);
-			if (retval == 0) {
-				printf("%s\n", dev.name);
-			} else {
-				printf("device not found in udev database\n");
+
+			if (strcmp(optarg, "owner") == 0) {
+				query = OWNER;
+				break;
+			}
+
+			if (strcmp(optarg, "group") == 0) {
+				query = GROUP;
+				break;
 			}
-			udevdb_exit();
-			return retval;
+
+			printf("unknown query type\n");
+			return -EINVAL;
 
 		case 'r':
-			printf("%s\n", udev_root);
-			return 0;
+			root = 1;
+			break;
 
 		case 'V':
 			printf("udev, version %s\n", UDEV_VERSION);
@@ -128,14 +156,63 @@
 		}
 	}
 
+	/* process options */
+	if (query != NONE) {
+		if (path[0] == '\0') {
+			printf("query needs device path specified\n");
+			return -EINVAL;
+		}
+
+		retval = udevdb_open_ro();
+		if (retval != 0) {
+			printf("unable to open udev database\n");
+			return -EACCES;
+		}
+		retval = udevdb_get_dev(path, &dev);
+		if (retval == 0) {
+			switch(query) {
+			case NAME:
+				if (root)
+				strfieldcpy(result, udev_root);
+				strncat(result, dev.name, sizeof(result));
+				break;
+
+			case SYMLINK:
+				strfieldcpy(result, dev.symlink);
+				break;
+
+			case GROUP:
+				strfieldcpy(result, dev.group);
+				break;
+
+			case OWNER:
+				strfieldcpy(result, dev.owner);
+				break;
+
+			default:
+				break;
+			}
+			printf("%s\n", result);
+		} else {
+			printf("device not found in udev database\n");
+		}
+		udevdb_exit();
+		return retval;
+	}
+
+	if (root) {
+		printf("%s\n", udev_root);
+		return 0;
+	}
+
 help:
 	printf("Usage: [-qrVh]\n"
-	       "  -q <path>  query database for the name of the created node\n"
+	       "  -q <name>  query database for the specified value\n"
+	       "  -p <path>  device path used for query\n"
 	       "  -r         print udev root\n"
 	       "  -V         print udev version\n"
 	       "  -h         print this help text\n"
 	       "\n");
-
 	return retval;
 }
 

^ permalink raw reply

* Additional info...
From: Dan @ 2004-01-11  2:31 UTC (permalink / raw)
  To: acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f

I should note that, unlike many of the issues I've seen by searching
Google and the message list archives, my DSDT compiles cleanly without
changing anything after de-compiling it...most problems that I've seen
were solved by fixing a statement that caused the AML compiler to die or
complain, so I'm starting to think this isn't a DSDT problem at
all...anyway, any information or tips would be great ^_^

~D. Stone



-------------------------------------------------------
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html

^ permalink raw reply

* Re: [PATCH 1/2] Synaptics rate switching
From: Dmitry Torokhov @ 2004-01-11  2:20 UTC (permalink / raw)
  To: Gunter Königsmann, Gunter Königsmann
  Cc: Gunter Königsmann, linux-kernel, Vojtech Pavlik,
	Andrew Morton
In-Reply-To: <Pine.LNX.4.53.0401102241130.1980@calcula.uni-erlangen.de>

On Saturday 10 January 2004 05:05 pm, Gunter Königsmann wrote:
> Tried it. Doesn't change a thing. Means: I get about half the number of
> warning messages, but that just corresponds to half the number of
> packets.
>
>
> What helps a lot, but not to 100% (get bad keypresses anyway) is
> totally deactivating the ACPI. Killing all processes that access
> /proc/acpi seems again to help a bit.
>
> And The number of Warnings seemingly increases with the labtop
> temperature... In a really cold room I get nearly no warnings at all.
> Jitter? Hardware, that is simply broken?
>

Actually, since you mentioned temperature.. is CPUFREQ active or does
the ACPI throttle your processor to a lower frequency if it gets hot?
 
Dmitry

^ permalink raw reply

* sysfs aware DRI drivers
From: Jon Smirl @ 2004-01-11  2:12 UTC (permalink / raw)
  To: linux-hotplug

If you want to play with my new DRI drivers they are at:
bk://mesa3d.bkbits.net/drm

cd into drm directory and 'make -f Makefile.linux'

They are actively under development so they may not work for running X at all.
But you can insmod them and watch the dri/card device appear. Worse that will
happen is that they will segfault. You will not be able to load these drivers if
the FB device is also loaded.

The hotplug reset/DDC program is not ready to play with yet.

==Jon Smirl
jonsmirl@yahoo.com

__________________________________
Do you Yahoo!?
Yahoo! Hotjobs: Enter the "Signing Bonus" Sweepstakes
http://hotjobs.sweepstakes.yahoo.com/signingbonus


-------------------------------------------------------
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html
_______________________________________________
Linux-hotplug-devel mailing list  http://linux-hotplug.sourceforge.net
Linux-hotplug-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel

^ permalink raw reply

* Re: Running Linux on an NCD HMX X-Terminal
From: Adam Nielsen @ 2004-01-11  2:04 UTC (permalink / raw)
  To: linux-mips
In-Reply-To: <200401101240.i0ACePX01584@mwave.heeltoe.com>

> I brought up linux on the PPC403 version of an NCD x-terminal.  As I recall
> I had to write program to hack the elf header to get kernels to load.
> The project is at http://sourceforge.net/projects/explora-linux/

Hmm...this looks interesting!

> You may get lucky and find they used the same format for MIPS...

Well I am hopeful, given that they use the same manual for the HMX and the 
Explora, but running ncdhack on the kernel didn't seem to have any effect :-(

I did try some fiddling with the ELF files, just to see what would happen (but 
not having any experience with this, I was just guessing ;-))  The load 
address for the proper boot image is 0x40020000 but the kernel is 0x88002000 
which I think is partly why it doesn't work.  If I shrink the ELF file a 
little by removing a couple of the sections (by telling objcopy to ignore 
them) *and* I change the load address to 0x40020000 then the xterm actually 
downloads the image but then gives a "File corrupted CRC error" just as it 
goes to boot it.

I'm not sure why that happens, because manipulating the file properly with 
objcopy should adjust any CRC checksums accordingly.  I wonder whether the 
xterm is checking that the image is 'official'?

Cheers,
Adam.

^ permalink raw reply

* Re: Trouble compiling kernel for G5.
From: Stefan Berndtsson @ 2004-01-11  1:58 UTC (permalink / raw)
  To: Benjamin Herrenschmidt; +Cc: linuxppc-dev list, Jens Axboe
In-Reply-To: <1073784645.763.47.camel@gaston>


Benjamin Herrenschmidt <benh@kernel.crashing.org> writes:

>>
>> ide0, timeout waiting                   for dbdma command stop
>> ide-cd: dma error
>> hda: DMA disabled
>> hda: dma error: status=0x50 { DriveReady SeekComplete }
>> hda: dma error: error=0x00
>> cdrom_newpc_intr: 4 residual after xfer
>> cdrom_newpc_intr: 4 residual after xfer
>>
>> And hdparm shows the drive to no longer have DMA turned on, which it did
>> before running growisofs.
>>
>> The same command on a B&W G3 runs fine with DMA (2.4.23 kernel).
>>
>> So, to answer your question, it seems it does not work, no.
>
> Look like an underrun again, or an alignement problem as there
> seem to be something weird with the DBDMA on the G5 at least
> (there is some "workaround" code in darwin that I haven't been
> able to understand fully yet).

Ok, I'll just sit tight and wait a bit then. :)

/Stefan

** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

^ permalink raw reply

* personality.h: struct map_segment
From: Justin Pryzby @ 2004-01-11  1:57 UTC (permalink / raw)
  To: linux-kernel

include/linux/personality.h defines

struct exec_domain {
        const char              *name;          /* name of the execdomain */
        handler_t               handler;        /* handler for syscalls */
        unsigned char           pers_low;       /* lowest personality */
        unsigned char           pers_high;      /* highest personality */
        unsigned long           *signal_map;    /* signal mapping */
        unsigned long           *signal_invmap; /* reverse signal mapping */
        struct map_segment      *err_map;       /* error mapping */
        struct map_segment      *socktype_map;  /* socket type mapping */
        struct map_segment      *sockopt_map;   /* socket option mapping */
        struct map_segment      *af_map;        /* address family mapping */
        struct module           *module;        /* module context of the ed. */
        struct exec_domain      *next;          /* linked list (internal) */
};

However, as best as I can tell, struct map_segment is never defined.
I've grepped 2.4 and 2.5, and googled to no avail.  I'm just curious, is
this simply unimplemented functionality?  And what is it ultimately
supposed to do?

Justin

^ permalink raw reply

* Re: Protecting against DoS
From: Peter Frischknecht @ 2004-01-11  1:50 UTC (permalink / raw)
  To: Pasi Kärkkäinen; +Cc: netfilter
In-Reply-To: <20031210165306.GH17221@edu.joroinen.fi>

Hello,

I wanted to let you know that you are not alone.
We manage networks in apartment complexes.  Hundreds of students use
their computers simultaneously and we have always been able to deal with
DoS attacks.

The attack you described is identical to the one we have suffered since
sometime in September.  In short: it cannot be stopped.  But there are
many things you can do.

As you may have found in personal research, the worm has the following
characteristics:
1 - It is a Zombie.  Computers do NOT automatically start attacking web
sites.  They wait for an instruction from outside.
2 - The connection to the outside "master server" is done via IRC.
3 - The infected computer attacks 1 to a few web servers at a time. (we
have never seen more than 3).
4 - Completely random spoofed src addresses.
5 - The MAC address is (Thank You GOD) not being spoofed.
6 - The intensity of the attack deems the offending computer almost
useless during the attack.

It seemed from your description that your network was fairly small.
In order to save bandwidth, we implement a transparent caching
strategy.  So we redirect port 80 to the cache.  Guess what!!!  Our
caching server ends up the target of the attack!!!

I can tell you that I tried every pertinent module in the patch-o-matic
volume.  It was a 3 month ordeal with very frequent lockups. "connlimit"
does not work because once you enable SYN cookies, there are no
connections to limit.  "limit" draws too much CPU power, eventually
helping lock up the box.

Blocking the foreign IP sources at the FORWARD level (or INPUT in my
case) stopped the packets, but still kept my server with a very high
system use.

I have hundreds of rules in the MANGLE and NAT tables, so the bad
packets were still traveling and being matched against all those rules. 
I placed the drops for the foreign IPs in the MANGLE table.  If you look
at the docs, it is the first table the packet hits.

BTW, to stop foreign IP packets, I created one ACCEP rule for every
known IP class inside my network.  The last line simply DROPs everything
coming from the internal network.

My networks are basically functional now.  But the HIGH CPU use
persists.  It is likely caused by the interrupt handling or the packet
counters/rules checking.  I recently ran accross this page on lowering
the interrupt handling:
ftp://robur.slu.se/pub/Linux/net-development/NAPI/NAPI_HOWTO.txt

Feel free to correspond with me.  We can trade ideas on the topic.

Peter Frischknecht
Empowering Solutions, Inc.




^ permalink raw reply

* Re: logitech cordless desktop deluxe optical keyboard issues
From: sven kissner @ 2004-01-11  1:53 UTC (permalink / raw)
  To: Andries.Brouwer; +Cc: linux-kernel
In-Reply-To: <UTC200401110028.i0B0SpL08329.aeb@smtp.cwi.nl>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

hi andries, 

thanks for your reply.

On Sunday 11 January 2004 01:28, Andries.Brouwer@cwi.nl wrote:
> I have seen patches by Vojtech somewhere that already did this,
> but looking at current bk source it seems that they have not been
> applied yet.

where can i find those patches? kml?

> Anyway, I released kbd-1.10 last week or so, and it ignores the
> kernel NR_KEYS but tries to adapt dynamically to the kernel.
> It would not come with this error message, I suppose.

the message doesn't appear anymore, but installing is giving me the following:
<-- snip -->
Setting up kbd (1.10-1) ...
Looking for keymap to install:
de-latin1-nodeadkeys
cannot open file de-latin1-nodeadkeys
Loading /etc/console/boottime.kmap.gz
<-- snap -->
i guess i just screwed up the paths ;)

> : atkbd.c: Unknown key pressed (translated set 2, code 0x91 on
> : isa0060/serio0) atkbd.c: Unknown key released (translated set 2, code
> : 0x91 on isa0060/serio0) atkbd.c: Unknown key pressed (translated set 2,
> : code 0x92 on isa0060/serio0) atkbd.c: Unknown key released (translated
> : set 2, code 0x92 on isa0060/serio0)
>
> This is something different, a key without associated keycode.
> That is normal. If it really has high bit set it is a bit unusual.
> (What does showkey -s show?)

showkey -s is giving me exactly the same:
<-- snip -->
atkbd.c: Unknown key pressed (translated set 2, code 0x92 on isa0060/serio0).
atkbd.c: Unknown key released (translated set 2, code 0x92 on isa0060/serio0).
<-- snap -->

sven
- -- 
..never argue with idiots. they drag you down to their level and beat you with 
experience..
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)

iD8DBQFAAKySPV/e7f4i4AERAm0FAJ97N/CT3PfUcJZK2+4gXy7e3lDFgwCgl/T2
qRVMrl5ik2NZ3dtGdxounJQ=
=8I8H
-----END PGP SIGNATURE-----

^ permalink raw reply

* Re: [PATCH] make tg3 NAPI support configurable
From: Jeff Garzik @ 2004-01-11  1:49 UTC (permalink / raw)
  To: Robert Olsson; +Cc: Greg Banks, David S. Miller, Linux Network Development list
In-Reply-To: <16354.64258.364153.488309@robur.slu.se>

Robert Olsson wrote:
> Greg Banks writes:
> 
>  > I've been having some issues with irq rates and cpu usage in the
>  > tg3 driver.  In short, on Altix machines they're far too high.
>  > It turned out that reverting the driver to its pre-NAPI interrupt
>  > coalescing scheme made the situation a lot better.
>  > 
>  > How much better?  Running 8192 byte UDP packets across gige
>  > with NAPI takes 99.5% of a CPU to service 29,100 irqs per second.
>  > With the pre-NAPI code the figures are 36.0% CPU and 4880 irq/sec.
>  > Similar improvements are seen for non-fragmented UDP and for TCP.
> 
>  Hello!
> 
>  You can use coalescing with NAPI as well, e1000 and other drivers
>  are doing this. This will give you same interrupt rates as non-
>  NAPI at low load and "polling" without any interrupts at high load.

Yes, this is something I've been meaning to add to tg3 for months now. 
Adding some about of hardware intr mitigation -in addition to- NAPI will 
not only help on the NAPI "hard case" of moderate load and a super-fast 
CPU, but also help avoid certain silicon bugs...


>  Furthermore NAPI can be extended to schedule dev->poll even for TX-
>  interrupts. There is pacth for e1000 doing this. We see about 5-8% 
>  overall system packet improvement with this.

tg3 already schedules for TX, so we've got that part covered :)

	Jeff

^ permalink raw reply

* Re: [bonding] Add basic support for dynamic configuration of bond interfaces
From: Jeff Garzik @ 2004-01-11  1:34 UTC (permalink / raw)
  To: Amir Noam; +Cc: Jay Vosburgh, bonding-devel, netdev
In-Reply-To: <200401081819.54484.amir.noam@intel.com>

Amir Noam wrote:
> The following patch sets provide basic support for future bonding 
> operations (specifically for dynamic configuration of bonding 
> interfaces).
> 
> This is done by adding two new bonding ioctls: one for deviceless 
> commands (an ioctl hook) and one for device oriented commands. Like 
> ethtool, the first u32 value in the data structure will indicate the 
> exact sub-command to be executed.
> 
> The sets are against the latest netdev-2.4 and net-drivers-2.5-exp 
> trees.


I don't disagree with the overall goal of these patches, but I think we 
might need to pause a bit, and consider how best to configure, add, and 
remove bonding interfaces, if we are coming up with a new interface.

For configuration tasks that occur outside the scope of a single bonding 
interface (i.e. a single struct net_device), you need a separate entity 
from a socket ioctl.  It's not ideal at all to configure N objects using 
a special ioctl ... when opening one of said objects :)

I would suggest a simple character device (misc_register), and let the 
userland application configure settings unrelated to a single object.

For a configuring state related to a _single_ bonding interface (i.e. a 
single net_device), socket ioctls are OK.

	Jeff

^ permalink raw reply

* Re: [linux-usb-devel] Re: USB hangs
From: David Brownell @ 2004-01-11  1:40 UTC (permalink / raw)
  To: Oliver Neukum
  Cc: Matthew Dharm, Alan Cox, Marcelo Tosatti,
	Linux Kernel Mailing List, USB Developers, Greg KH
In-Reply-To: <200401110149.34654.oliver@neukum.org>

Oliver Neukum wrote:
> Am Sonntag, 11. Januar 2004 01:23 schrieb Matthew Dharm:
> 
>>Where is USB kmalloc'ing with GFP_KERNEL?  I thought we tracked all those
>>down and eliminated them.
>>
> 
> 
> static int ohci_mem_init (struct ohci *ohci)
> {
> 	...
> }
> 
> This one here looks dangerous.

Since that happens as part of controller initialization,
long before usb-storage could possibly come into play ...
it doesn't seem to me like even a remote concern!




^ permalink raw reply

* No handler for Region [ERAM] on Gateway M350?
From: Dan @ 2004-01-11  1:33 UTC (permalink / raw)
  To: acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f

[-- Attachment #1: Type: text/plain, Size: 6646 bytes --]

Hello,

  I've recently been trying to get ACPI support up and running on my
Gateway M350 laptop...using kernel 2.6.1.  Everything seems to appear
just fine in /proc/acpi, except for the battery information;
/proc/acpi/battery exists, but there is nothing in the directory =( 
There is a series of error messages (AE_NOT_EXIST) in the dmesg output
relating to it, preceeded by a "No Handler for Region [ERAM]" error that
I suspect is the source of the other problems.  The kernel config with
regards to ACPI is as follows:

# Power management options (ACPI, APM)
# ACPI (Advanced Configuration and Power Interface) Support
CONFIG_ACPI=y
CONFIG_ACPI_BOOT=y
CONFIG_ACPI_INTERPRETER=y
CONFIG_ACPI_SLEEP=y
CONFIG_ACPI_SLEEP_PROC_FS=y
CONFIG_ACPI_AC=y
CONFIG_ACPI_BATTERY=y
CONFIG_ACPI_BUTTON=y
CONFIG_ACPI_FAN=y
CONFIG_ACPI_PROCESSOR=y
CONFIG_ACPI_THERMAL=y
# CONFIG_ACPI_ASUS is not set
# CONFIG_ACPI_TOSHIBA is not set
# CONFIG_ACPI_DEBUG is not set
CONFIG_ACPI_BUS=y
CONFIG_ACPI_EC=y
CONFIG_ACPI_POWER=y
CONFIG_ACPI_PCI=y
CONFIG_ACPI_SYSTEM=y
# CONFIG_ACPI_RELAXED_AML is not set
# CONFIG_SERIAL_8250_ACPI is not set
~~~~~~~~~~~~End .config~~~~~~~~~~~

The relevant section of dmesg is:

ACPI: RSDT (v001 GATEWA M350WVN  0x20030926  LTP 0x00000000) @0x1f6e6891
ACPI: FADT (v001 GATEWA M350WVN  0x20030926 PTL  0x00000050) @0x1f6ebe6a
ACPI: BOOT (v001 GATEWA M350WVN  0x20030926  LTP 0x00000001) @0x1f6ebfd8
ACPI: MADT (v001 INTEL  MONTARA  0x20030926 PTL  0x00000050) @0x1f6ebf7e
ACPI: SSDT (v001 INTEL  CPU0CST  0x00000001 INTL 0x20030224) @0x1f6e6ada
ACPI: SSDT (v001  INTEL  EISTRef 0x00002000 INTL 0x20030224) @0x1f6e68c9
ACPI: DSDT (v001 GATEWA M350WVN  0x20030926 MSFT 0x0100000e) @0x00000000
ACPI: Local APIC address 0xfee00000
ACPI: LAPIC (acpi_id[0x00] lapic_id[0x00] enabled)
Processor #0 15:2 APIC version 20
ACPI: LAPIC_NMI (acpi_id[0x00] high edge lint[0x1])
ACPI: IOAPIC (id[0x01] address[0xfec00000] global_irq_base[0x0])
IOAPIC[0]: Assigned apic_id 1
IOAPIC[0]: apic_id 1, version 32, address 0xfec00000, IRQ 0-23
ACPI: INT_SRC_OVR (bus 0 bus_irq 0 global_irq 2 dfl dfl)
ACPI: INT_SRC_OVR (bus 0 bus_irq 9 global_irq 9 high level)
ACPI BALANCE SET
Enabling APIC mode:  Flat.  Using 1 I/O APICs
Using ACPI (MADT) for SMP configuration information
Building zonelist for node : 0
current: c03c5a60
current->thread_info: c0448000
Initializing CPU#0
Kernel command line: root=/dev/hda2 video=vesa:ywrap,mtrr vga=0x317
PID hash table entries: 2048 (order 11: 16384 bytes)
Detected 2656.456 MHz processor.
Using tsc for high-res timesource
Console: colour dummy device 80x25
Memory: 505328k/514944k available (2400k kernel code, 8856k reserved,
952k data, 156k init, 0k highmem)
zapping low mappings.
Calibrating delay loop... 5242.88 BogoMIPS
Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
Mount-cache hash table entries: 512 (order: 0, 4096 bytes)
checking if image is initramfs...it isn't (ungzip failed); looks like an
initrd
Freeing initrd memory: 13k freed
CPU:     After generic identify, caps: bfebfbff 00000000 00000000
00000000
CPU:     After vendor identify, caps: bfebfbff 00000000 00000000
00000000
CPU: Trace cache: 12K uops, L1 D cache: 8K
CPU: L2 cache: 512K
CPU:     After all inits, caps: bfebfbff 00000000 00000000 00000080
Intel machine check architecture supported.
Intel machine check reporting enabled on CPU#0.
CPU#0: Intel P4/Xeon Extended MCE MSRs (12) available
CPU: Intel Mobile Intel(R) Pentium(R) 4     CPU 2.66GHz stepping 09
Enabling fast FPU save and restore... done.
Enabling unmasked SIMD FPU exception support... done.
Checking 'hlt' instruction... OK.
POSIX conformance testing by UNIFIX
enabled ExtINT on CPU#0
ESR value before enabling vector: 00000000
ESR value after enabling vector: 00000000
ENABLING IO-APIC IRQs
init IO_APIC IRQs
 IO-APIC (apicid-pin) 1-0, 1-16, 1-17, 1-18, 1-19, 1-20, 1-21, 1-22,
1-23 not connected.
..TIMER: vector=0x31 pin1=2 pin2=-1
Using local APIC timer interrupts.
calibrating APIC timer ...
..... CPU clock speed is 2654.0887 MHz.
..... host bus clock speed is 132.0744 MHz.
NET: Registered protocol family 16
PCI: PCI BIOS revision 2.10 entry at 0xfd9b2, last bus=2
PCI: Using configuration type 1
mtrr: v2.0 (20020519)
ACPI: Subsystem revision 20031203
 tbxface-0117 [03] acpi_load_tables      : ACPI Tables successfully
acquired
Parsing all Control
Methods:..........................................................
Table [DSDT](id F006) - 687 Objects with 55 Devices 194 Methods 19
Regions
Parsing all Control Methods:.
Table [SSDT](id F003) - 1 Objects with 0 Devices 1 Methods 0 Regions
Parsing all Control Methods:...
Table [SSDT](id F004) - 4 Objects with 0 Devices 3 Methods 0 Regions
ACPI Namespace successfully loaded at root c04852bc
IOAPIC[0]: Set PCI routing entry (1-9 -> 0x71 -> IRQ 9 Mode:1 Active:0)
evxfevnt-0093 [04] acpi_enable           : Transition to ACPI mode
successful
evgpeblk-0747 [06] ev_create_gpe_block   : GPE 00 to 31 [_GPE] 4 regs at
0000000000001028 on int 9
Completing Region/Field/Buffer/Package
initialization:..........................................................
Initialized 19/19 Regions 0/0 Fields 20/20 Buffers 19/19 Packages (700
nodes)
Executing all Device _STA and_INI methods:........evregion-0251 [21]
ev_address_space_dispa: No handler for Region [ERAM] (df652c28)
[EmbeddedControl]
 exfldio-0284 [20] ex_access_region      : Region EmbeddedControl(3) has
no handler
 dswexec-0435 [13] ds_exec_end_op        : [LGreater]: Could not resolve
operands, AE_NOT_EXIST
 psparse-1120: *** Error: Method execution failed [\_SB_.PCI0._INI]
(Node df657528), AE_NOT_EXIST
  nsinit-0408 [06] ns_init_one_device    : \_SB_.PCI0._INI failed:
AE_NOT_EXIST
..................................................
58 Devices found containing: 58 _STA, 0 _INI methods
ACPI: Interpreter enabled
ACPI: Using IOAPIC for interrupt routing
evregion-0251 [21] ev_address_space_dispa: No handler for Region [ERAM]
(df652c28) [EmbeddedControl]
 exfldio-0284 [20] ex_access_region      : Region EmbeddedControl(3) has
no handler
 psparse-1120: *** Error: Method execution failed [\_SB_.BAT0._STA]
(Node df658428), AE_NOT_EXIST
~~~~~~~~~~End dmesg~~~~~~~~~~~~~~

As you can see in the above section, the first error (and what I suspect
is causing the subsequent AE_NOT_EXIST errors) is the "No Handler for
Region [ERAM]" message that I can't seem to diagnose.  I've attached a
dump of my DSDT data, after running it through acpidmp, in case it's
relevant (bzipped so that it's not 200+K =P).  Any ideas at all would be
MOST appreciated =)  Thanks so much!

~D. Stone

[-- Attachment #2: gatewaym350.dsl.bz2 --]
[-- Type: application/x-bzip, Size: 34663 bytes --]

^ permalink raw reply

* [2.4 patch] disallow modular CONFIG_COMX
From: Adrian Bunk @ 2004-01-11  1:30 UTC (permalink / raw)
  To: Andreas Haumer; +Cc: Marcelo Tosatti, linux-kernel, jgarzik, linux-net
In-Reply-To: <3FF2EAB3.1090001@xss.co.at>

On Wed, Dec 31, 2003 at 04:26:43PM +0100, Andreas Haumer wrote:
>...
> Hi!

Hi Andreas!

>...
> Here's a first report:
>...
> *) Unresolved symbol in kernel/drivers/net/wan/comx.o: proc_get_inode
>...

CONFIG_COMX=m always gave an unresolved symbol in kernel 2.4, and it
seems noone is interested in properly fixing it.

The patch below disallows a modular CONFIG_COMX.

cu
Adrian

--- linux-2.4.25-pre4-modular/drivers/net/wan/Config.in.old	2004-01-11 01:38:08.000000000 +0100
+++ linux-2.4.25-pre4-modular/drivers/net/wan/Config.in	2004-01-11 01:39:20.000000000 +0100
@@ -23,7 +23,7 @@
 # COMX drivers
 #
 
-   tristate '  MultiGate (COMX) synchronous serial boards support' CONFIG_COMX
+   bool '  MultiGate (COMX) synchronous serial boards support' CONFIG_COMX
    if [ "$CONFIG_COMX" != "n" ]; then
       dep_tristate '    Support for COMX/CMX/HiCOMX boards' CONFIG_COMX_HW_COMX $CONFIG_COMX
       dep_tristate '    Support for LoCOMX board' CONFIG_COMX_HW_LOCOMX $CONFIG_COMX
--- linux-2.4.25-pre4-modular/Documentation/Configure.help.old	2004-01-11 01:39:35.000000000 +0100
+++ linux-2.4.25-pre4-modular/Documentation/Configure.help	2004-01-11 01:40:14.000000000 +0100
@@ -11149,9 +11149,6 @@
   You must say Y to "/proc file system support" (CONFIG_PROC_FS) to
   use this driver.
 
-  If you want to compile this as a module, say M and read
-  <file:Documentation/modules.txt>.  The module will be called comx.o.
-
 Support for COMX/CMX/HiCOMX boards
 CONFIG_COMX_HW_COMX
   Hardware driver for the 'CMX', 'COMX' and 'HiCOMX' boards from the

^ permalink raw reply

* Re: Trouble compiling kernel for G5.
From: Benjamin Herrenschmidt @ 2004-01-11  1:30 UTC (permalink / raw)
  To: Stefan Berndtsson; +Cc: linuxppc-dev list, Jens Axboe
In-Reply-To: <87d69rb7y4.fsf@hades.nocrew.org>


>
> ide0, timeout waiting                   for dbdma command stop
> ide-cd: dma error
> hda: DMA disabled
> hda: dma error: status=0x50 { DriveReady SeekComplete }
> hda: dma error: error=0x00
> cdrom_newpc_intr: 4 residual after xfer
> cdrom_newpc_intr: 4 residual after xfer
>
> And hdparm shows the drive to no longer have DMA turned on, which it did
> before running growisofs.
>
> The same command on a B&W G3 runs fine with DMA (2.4.23 kernel).
>
> So, to answer your question, it seems it does not work, no.

Look like an underrun again, or an alignement problem as there
seem to be something weird with the DBDMA on the G5 at least
(there is some "workaround" code in darwin that I haven't been
able to understand fully yet).

Ben.


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

^ permalink raw reply

* Re: Trouble compiling kernel for G5.
From: Stefan Berndtsson @ 2004-01-11  1:16 UTC (permalink / raw)
  To: Benjamin Herrenschmidt; +Cc: linuxppc-dev list
In-Reply-To: <1073781366.17403.41.camel@gaston>


Benjamin Herrenschmidt <benh@kernel.crashing.org> writes:

> On Sun, 2004-01-11 at 11:17, Stefan Berndtsson wrote:
>> Benjamin Herrenschmidt <benh@kernel.crashing.org> writes:
>>
>> > On Sat, 2004-01-10 at 04:24, Stefan Berndtsson wrote:
>> >> When trying to compile the latest rsynced kernel (checked today, 2004-01-09)
>> >> from source.mvista.com::linuxppc-2.5-benh (2.6.1-rc1-ben1) for my G5, I
>> >> run into the following message with SATA:
>> >
>> > rsync again
>>
>> Figured from the other mails that mvista wasn't up to date at the point,
>> so with a 2.6.1-ben1 it compiled and booted fine. Thanks.
>>
>> Any news on when DVD-writing will be possible with DMA turned on?
>
> It doesn't work at the moment ?

When I, on the G5, run:

growisofs -Z /dev/hda -dvd-video dvddir

I get:

ide0, timeout waiting                   for dbdma command stop
ide-cd: dma error
hda: DMA disabled
hda: dma error: status=0x50 { DriveReady SeekComplete }
hda: dma error: error=0x00
cdrom_newpc_intr: 4 residual after xfer
cdrom_newpc_intr: 4 residual after xfer

And hdparm shows the drive to no longer have DMA turned on, which it did
before running growisofs.

The same command on a B&W G3 runs fine with DMA (2.4.23 kernel).

So, to answer your question, it seems it does not work, no.

/Stefan

** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

^ permalink raw reply

* Re: [PATCH] bugfixes for dgrs.c
From: Jeff Garzik @ 2004-01-11  1:16 UTC (permalink / raw)
  To: Stephen Hemminger; +Cc: netdev
In-Reply-To: <20040108165343.7ed94da9@linux.local>

applied

^ permalink raw reply

* Re: [PATCH] Mark IBM TR driver as not 64 bit clean
From: Jeff Garzik @ 2004-01-11  1:15 UTC (permalink / raw)
  To: Andi Kleen; +Cc: netdev, mikep, linux-tr
In-Reply-To: <20040109090908.GA1772@averell>

applied to 2.6

^ permalink raw reply

* Re: [linux-usb-devel] Re: USB hangs
From: Oliver Neukum @ 2004-01-11  1:06 UTC (permalink / raw)
  To: Matthew Dharm
  Cc: Alan Cox, Marcelo Tosatti, Linux Kernel Mailing List,
	USB Developers, Greg KH
In-Reply-To: <20040111010143.GF16484@one-eyed-alien.net>


> I'll agree that it looks dangerous, tho pci_pool_create() is something I
> know little about.
> 
> Is this 2.4 or 2.6 code here?

2.4 / usb-ohci.h

	Regards
		Oliver


^ permalink raw reply

* Problem with loading ALSA mods - kernel 2.6.1
From: Steve Youngs @ 2004-01-11  1:04 UTC (permalink / raw)
  To: Linux Kernel List; +Cc: ALSA Team

[-- Attachment #1: Type: text/plain, Size: 593 bytes --]

When my sound modules load I'm getting this in the logs...

kernel: request_module: failed /sbin/modprobe -- sound-slot-0. error = 256
kernel: PCI: Found IRQ 10 for device 0000:00:09.0
kernel: modprobe: page allocation failure. order:4, mode:0x20

The modules load and sound works as expected.

What's that "page allocation failure" all about?

-- 
|---<Steve Youngs>---------------<GnuPG KeyID: A94B3003>---|
|              Ashes to ashes, dust to dust.               |
|      The proof of the pudding, is under the crust.       |
|------------------------------<sryoungs@bigpond.net.au>---|

[-- Attachment #2: Type: application/pgp-signature, Size: 256 bytes --]

^ permalink raw reply


This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.