linux/arch/parisc
Peter Zijlstra ba0a6c9f6f fcntl: add F_[SG]ETOWN_EX
In order to direct the SIGIO signal to a particular thread of a
multi-threaded application we cannot, like suggested by the manpage, put a
TID into the regular fcntl(F_SETOWN) call.  It will still be send to the
whole process of which that thread is part.

Since people do want to properly direct SIGIO we introduce F_SETOWN_EX.

The need to direct SIGIO comes from self-monitoring profiling such as with
perf-counters.  Perf-counters uses SIGIO to notify that new sample data is
available.  If the signal is delivered to the same task that generated the
new sample it can augment that data by inspecting the task's user-space
state right after it returns from the kernel.  This is esp.  convenient
for interpreted or virtual machine driven environments.

Both F_SETOWN_EX and F_GETOWN_EX take a pointer to a struct f_owner_ex
as argument:

struct f_owner_ex {
	int   type;
	pid_t pid;
};

Where type is one of F_OWNER_TID, F_OWNER_PID or F_OWNER_GID.

Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Reviewed-by: Oleg Nesterov <oleg@redhat.com>
Tested-by: stephane eranian <eranian@googlemail.com>
Cc: Michael Kerrisk <mtk.manpages@googlemail.com>
Cc: Roland McGrath <roland@redhat.com>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Cc: Christoph Hellwig <hch@lst.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-09-24 07:21:01 -07:00
..
configs parisc: update defconfigs 2009-03-13 01:33:34 -04:00
hpux ptrace: remove PT_DTRACE from avr32, mn10300, parisc, s390, sh, xtensa 2009-06-18 13:03:48 -07:00
include/asm fcntl: add F_[SG]ETOWN_EX 2009-09-24 07:21:01 -07:00
kernel headers: utsname.h redux 2009-09-23 18:13:10 -07:00
lib parisc: fix mismatched parenthesis in memcpy.c 2009-07-03 03:34:09 +00:00
math-emu parisc: decode_exc.c should include kernel.h 2009-07-03 03:34:08 +00:00
mm arches: drop superfluous casts in nr_free_pages() callers 2009-09-22 07:17:34 -07:00
oprofile oprofile: more whitespace fixes 2008-10-15 20:55:51 +02:00
Kconfig perf: Do the big rename: Performance Counters -> Performance Events 2009-09-21 14:28:04 +02:00
Kconfig.debug alpha/parisc: remove config variable DEBUG_RWLOCK 2008-02-06 10:41:03 -08:00
Makefile kbuild: use INSTALLKERNEL to select customized installkernel script 2009-09-20 12:18:14 +02:00
defpalo.conf
install.sh kbuild: use INSTALLKERNEL to select customized installkernel script 2009-09-20 12:18:14 +02:00
nm