Re: [PATCH, RESEND] getrusage: fill ru_maxrss value

2008-12-16 Thread Jiri Pirko
On Tue, 16 Dec 2008 16:20:54 +0100 Oleg Nesterov o...@redhat.com wrote: On 12/16, Jiri Pirko wrote: This patch makes -ru_maxrss value in struct rusage filled accordingly to rss hiwater mark. This struct is filled as a parameter to getrusage syscall. -ru_maxrss value is set to pages which

Re: [PATCH v3 0/3] preadv pwritev syscalls.

2008-12-16 Thread Ralf Baechle
On Mon, Dec 15, 2008 at 09:57:24PM +0100, Gerd Hoffmann wrote: It fixes the alignment issue but still won't work; on MIPS 32-bit userspace will pass the 64-bit argument in two registers but the 64-bit kernel code will assume it to be passed in a single registers. It'd be ugly but passing

Re: [PATCH v3 0/3] preadv pwritev syscalls.

2008-12-16 Thread Kyle McMartin
On Tue, Dec 16, 2008 at 04:05:02PM +, Ralf Baechle wrote: If merge_64() was a standard macro in asm/compat.h on all architectures, compat_sys_pwrite() could invoke it directly and the need for the compat wrapper around the compat wrapper would go away. +1 for this. AFAIK, there's issues

Re: [PATCH v3 0/3] preadv pwritev syscalls.

2008-12-16 Thread Gerd Hoffmann
Ralf Baechle wrote: On Mon, Dec 15, 2008 at 09:57:24PM +0100, Gerd Hoffmann wrote: It fixes the alignment issue but still won't work; on MIPS 32-bit userspace will pass the 64-bit argument in two registers but the 64-bit kernel code will assume it to be passed in a single registers. It'd be

[PATCH, RESEND] getrusage: fill ru_maxrss value

2008-12-16 Thread Jiri Pirko
This patch makes -ru_maxrss value in struct rusage filled accordingly to rss hiwater mark. This struct is filled as a parameter to getrusage syscall. -ru_maxrss value is set to pages which might be correct as time application converts it to KBs. To make this happen we extend struct signal_struct

Re: [RFC v11][PATCH 00/13] Kernel based checkpoint/restart

2008-12-16 Thread Dave Hansen
Andrew, I just realized that you weren't cc'd on these when they were posted. Can we give them a run in -mm? As far as I know, all review comments have been addressed and there's nothing outstanding. On Fri, 2008-12-05 at 12:31 -0500, Oren Laadan wrote: Checkpoint-restart (c/r): fixed races

Re: [RFC v11][PATCH 03/13] General infrastructure for checkpoint restart

2008-12-16 Thread Mike Waychison
Oren Laadan wrote: +/* + * Helpers to write(read) from(to) kernel space to(from) the checkpoint + * image file descriptor (similar to how a core-dump is performed). + * + * cr_kwrite() - write a kernel-space buffer to the checkpoint image + * cr_kread() - read from the checkpoint image to a

Re: [RFC v11][PATCH 03/13] General infrastructure for checkpoint restart

2008-12-16 Thread Linus Torvalds
On Tue, 16 Dec 2008, Mike Waychison wrote: set_fs(fs) here Btw, this all is an excellent example of why people should try to aim for small functions and use lots of them. It's often _way_ more readable to do static inline int __some_fn(...) { .. do the real

Re: [PATCH v3 0/3] preadv pwritev syscalls.

2008-12-16 Thread Arnd Bergmann
On Tuesday 16 December 2008, Kyle McMartin wrote: I'd prefer to have the ordering coded explicitly instead, like this: asmlinkage int compat_sys_pwritev(unsigned long fd,        const struct compat_iovec __user *vec, unsigned long vlen,        unsigned pos_low, unsigned pos_high) {  

Re: [PATCH v3 0/3] preadv pwritev syscalls.

2008-12-16 Thread Gerd Hoffmann
Kyle McMartin wrote: On Tue, Dec 16, 2008 at 05:48:58PM +0100, Gerd Hoffmann wrote: i.e. the ordering of the splitted argument depends on the os endianness? What is the reason for this? Eh? The splitting will occur at the C ABI level, not as a result of glibc (though, it could be done that

Re: [RFC v11][PATCH 03/13] General infrastructure for checkpoint restart

2008-12-16 Thread Mike Waychison
Oren Laadan wrote: diff --git a/checkpoint/sys.c b/checkpoint/sys.c index 375129c..bd14ef9 100644 --- a/checkpoint/sys.c +++ b/checkpoint/sys.c +/* + * During checkpoint and restart the code writes outs/reads in data + * to/from the checkpoint image from/to a temporary buffer (ctx-hbuf). + *

Re: [PATCH v3 0/3] preadv pwritev syscalls.

2008-12-16 Thread Heiko Carstens
On Tue, Dec 16, 2008 at 10:34:49PM +0100, Gerd Hoffmann wrote: Kyle McMartin wrote: On Tue, Dec 16, 2008 at 05:48:58PM +0100, Gerd Hoffmann wrote: i.e. the ordering of the splitted argument depends on the os endianness? What is the reason for this? Eh? The splitting will occur at the C

Re: [RFC v11][PATCH 03/13] General infrastructure for checkpoint restart

2008-12-16 Thread Oren Laadan
Dave Hansen wrote: On Tue, 2008-12-16 at 13:54 -0800, Mike Waychison wrote: Oren Laadan wrote: diff --git a/checkpoint/sys.c b/checkpoint/sys.c index 375129c..bd14ef9 100644 --- a/checkpoint/sys.c +++ b/checkpoint/sys.c +/* + * During checkpoint and restart the code writes outs/reads in

Re: [RFC v11][PATCH 03/13] General infrastructure for checkpoint restart

2008-12-16 Thread Dave Hansen
On Tue, 2008-12-16 at 14:43 -0800, Mike Waychison wrote: Hmm, if I'm understanding you correctly, adding ref counts explicitly (like you suggest below) would be used to let a lower layer defer writes. Seems like this could be just as easily done with explicits kmallocs and transferring

Re: [RFC v11][PATCH 03/13] General infrastructure for checkpoint restart

2008-12-16 Thread Mike Waychison
Oren Laadan wrote: Dave Hansen wrote: On Tue, 2008-12-16 at 13:54 -0800, Mike Waychison wrote: Oren Laadan wrote: diff --git a/checkpoint/sys.c b/checkpoint/sys.c index 375129c..bd14ef9 100644 --- a/checkpoint/sys.c +++ b/checkpoint/sys.c +/* + * During checkpoint and restart the code writes

Re: [RFC v11][PATCH 03/13] General infrastructure for checkpoint restart

2008-12-16 Thread Oren Laadan
Mike Waychison wrote: Oren Laadan wrote: Dave Hansen wrote: On Tue, 2008-12-16 at 13:54 -0800, Mike Waychison wrote: Oren Laadan wrote: diff --git a/checkpoint/sys.c b/checkpoint/sys.c index 375129c..bd14ef9 100644 --- a/checkpoint/sys.c +++ b/checkpoint/sys.c +/* + * During

Re: [RFC v11][PATCH 04/13] x86 support for checkpoint/restart

2008-12-16 Thread Mike Waychison
Oren Laadan wrote: Add logic to save and restore architecture specific state, including thread-specific state, CPU registers and FPU state. In addition, architecture capabilities are saved in an architecure specific extension of the header (cr_hdr_head_arch); Currently this includes only FPU