Re: [patch] [RFC] Kexec on MIPS

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Oct 18, 2006 at 11:21:21PM +0200, Nicolas Schichan wrote:

One more problem:

+       sys     sys_kexec_load          1

The last column is the number of arguments slots of the syscall as counted
by the MIPS argument passing conventions, so this should actually be 4.
Not this was actually a harmless bug; it does hurt for syscalls that need
more than 4 slots.

Then buglets with O32 / N32 ABIs on 64-bit kernels:

diff -Nru linux-orig/arch/mips/kernel/scall64-n32.S linux-work/arch/mips/kernel/scall64-n32.S
--- linux-orig/arch/mips/kernel/scall64-n32.S   2006-10-14 05:34:03.000000000 +0200
+++ linux-work/arch/mips/kernel/scall64-n32.S   2006-10-17 15:58:59.000000000 +0200
@@ -392,3 +392,4 @@
        PTR     sys_tee
        PTR     sys_vmsplice                    /* 6271 */
        PTR     sys_move_pages
+       PTR     sys_kexec_load
diff -Nru linux-orig/arch/mips/kernel/scall64-o32.S linux-work/arch/mips/kernel/scall64-o32.S
--- linux-orig/arch/mips/kernel/scall64-o32.S   2006-10-14 05:34:03.000000000 +0200
+++ linux-work/arch/mips/kernel/scall64-o32.S   2006-10-17 15:59:23.000000000 +0200
@@ -514,4 +514,5 @@
        PTR     sys_tee
        PTR     sys_vmsplice
        PTR     compat_sys_move_pages
+       PTR     sys_kexec_load
        .size   sys_call_table,.-sys_call_table

That is these two being 32-bit syscalls on a 64-bit kernel need to use the
compat_sys_kexec_load syscall wrapper to work right.

And finally there are the syscall numbers.  The ones you've picked are
already taken, so I've choosen:

	O32 ABI: 4311
	N64 ABI: 5270
	N32 ABI: 6270

Note I'll allocate these syscalls immediately to give ABI stability - it's
a standard Linux syscall afterall.  So you can drop the unistd.h bits from
your patch.

And finally:

diff -Nru linux-orig/Makefile linux-work/Makefile
--- linux-orig/Makefile 2006-10-14 05:34:03.000000000 +0200
+++ linux-work/Makefile 2006-10-17 16:09:02.000000000 +0200

You may want to drop that part from your patch, too ;-)

  Ralf


[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux