patch-2.1.126 linux/arch/mips/kernel/irixelf.c

Next file: linux/arch/mips/kernel/irixinv.c
Previous file: linux/arch/mips/kernel/irix5sys.h
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.125/linux/arch/mips/kernel/irixelf.c linux/arch/mips/kernel/irixelf.c
@@ -378,8 +378,8 @@
 
 	/* Now fill out the bss section.  First pad the last page up
 	 * to the page boundary, and then perform a mmap to make sure
-	 * that there are zeromapped pages up to and including the last
-	 * bss page.
+	 * that there are zero-mapped pages up to and including the
+	 * last bss page.
 	 */
 #ifdef DEBUG_ELF
 	printk("padzero(%08lx) ", (unsigned long) (elf_bss));
@@ -1254,10 +1254,9 @@
 	notes[1].type = NT_PRPSINFO;
 	notes[1].datasz = sizeof(psinfo);
 	notes[1].data = &psinfo;
-	psinfo.pr_state = current->state;
-	psinfo.pr_sname =
-		((current->state < 0 || current->state > 5) ?
-		('.') : ("RSDZTD"[current->state]));
+	i = current->state ? ffz(~current->state) + 1 : 0;
+	psinfo.pr_state = i;
+	psinfo.pr_sname = (i < 0 || i > 5) ? '.' : "RSDZTD"[i];
 	psinfo.pr_zomb = psinfo.pr_sname == 'Z';
 	psinfo.pr_nice = current->priority-15;
 	psinfo.pr_flag = current->flags;
@@ -1286,7 +1285,7 @@
 	notes[2].datasz = sizeof(*current);
 	notes[2].data = current;
 	
-	/* Try to dump the fpu. */
+	/* Try to dump the FPU. */
 	prstatus.pr_fpvalid = dump_fpu (&fpu);
 	if (!prstatus.pr_fpvalid) {
 		numnote--;
@@ -1388,7 +1387,7 @@
 	return has_dumped;
 }
 
-__initfunc(int init_irix_binfmt(void))
+int __init init_irix_binfmt(void)
 {
 	return register_binfmt(&irix_format);
 }

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov