Gary Wallace wrote:
>   I have determined that the "Uncompressing Linux...inflate returned
> FFFFFFFB" error is caused by the size of the uncompressed image.  I
> was able to shrink the image enough that it would uncompress by
> lowering CONFIG_IPIPE_TRACE_SHIFT to 2 (I had to change the config
> limit to do this) and by building some of the drivers as modules.

2^2 = 4 entries for trace points. This renders the tracer useless.

> 
>   One of the motorola developers also pointed out to me that using
> MOTLoad I could just download and boot the uncompressed image file.  I
> used "netBoot -d/dev/enet1 -c192.168.151.133 -s192.168.151.135
> -fvmlinux.bin".

So this problem melts down to the large static buffer the tracer
introduces. Hmm, by booting with tracing disabled, allocating the buffer
dynamically via vmalloc, and then arming the tracer we may work around
this issue.

Attached is a patch against the applied tracer which hacks in such a
feature. It works on my qemu-i386 box (does anyone know if qemu-ppc
would be usable for us as well?), but I only tested it roughly. Please
give it a try.

> 
>   Unfortunately, though I now get past the uncompress error my kernel
> is consistently hanging in the boot process instead of generating the
> kernel preempt bug error.  Thus I still haven't been able to get a
> trace.  I haven't had time recently to work on this, but as soon as I
> can I hope to continue attempts to generate a trace of the problem.
> I would suggest you try booting an uncompressed image in the hopes
> that you'll be able to generate a trace.

I'm afraid that this problem has a different reason (and I still wonder
why you needed such a small TRACE_SHIFT...). Anyway, step by step.
Thanks in advance for your patience.

Jan


PS: Re-added the list to CC.
Index: linux-2.6.16.16/kernel/ipipe/tracer.c
===================================================================
--- linux-2.6.16.16.orig/kernel/ipipe/tracer.c
+++ linux-2.6.16.16/kernel/ipipe/tracer.c
@@ -27,6 +27,7 @@
 #include <linux/seq_file.h>
 #include <linux/proc_fs.h>
 #include <linux/ctype.h>
+#include <linux/vmalloc.h>
 #include <linux/ipipe_trace.h>
 #include <asm/uaccess.h>
 
@@ -86,14 +87,9 @@ enum ipipe_trace_type
 };
 
 
-int ipipe_trace_enable = 1;
+int ipipe_trace_enable = 0;
 
-static struct ipipe_trace_path trace_paths[NR_CPUS][IPIPE_TRACE_PATHS] =
-	{ [0 ... NR_CPUS-1] =
-		{ [0 ... IPIPE_TRACE_PATHS-1] =
-			{ .begin = -1, .end = -1 }
-		}
-	};
+static struct ipipe_trace_path *trace_paths[NR_CPUS];
 static int active_path[NR_CPUS] =
 	{ [0 ... NR_CPUS-1] = IPIPE_DEFAULT_ACTIVE };
 static int max_path[NR_CPUS] =
@@ -1101,6 +1097,18 @@ void __init __ipipe_init_trace_proc(void
 {
 	struct proc_dir_entry *trace_dir;
 	struct proc_dir_entry *entry;
+	int i,j;
+
+	for (i = 0; i < NR_CPUS; i++) {
+		trace_paths[i] = vmalloc(sizeof(struct ipipe_trace_path) * IPIPE_TRACE_PATHS);
+		if (!trace_paths)
+			return;
+		for (j = 0; j < IPIPE_TRACE_PATHS; j++) {
+			trace_paths[i][j].begin = -1;
+			trace_paths[i][j].end   = -1;
+		}
+	}
+	ipipe_trace_enable = 1;
 
 	trace_dir = create_proc_entry("trace", S_IFDIR, ipipe_proc_root);
 

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
Xenomai-help mailing list
[email protected]
https://mail.gna.org/listinfo/xenomai-help

Reply via email to