linux/arch/sparc/kernel
Davide Libenzi 4d672e7ac7 timerfd: new timerfd API
This is the new timerfd API as it is implemented by the following patch:

int timerfd_create(int clockid, int flags);
int timerfd_settime(int ufd, int flags,
		    const struct itimerspec *utmr,
		    struct itimerspec *otmr);
int timerfd_gettime(int ufd, struct itimerspec *otmr);

The timerfd_create() API creates an un-programmed timerfd fd.  The "clockid"
parameter can be either CLOCK_MONOTONIC or CLOCK_REALTIME.

The timerfd_settime() API give new settings by the timerfd fd, by optionally
retrieving the previous expiration time (in case the "otmr" parameter is not
NULL).

The time value specified in "utmr" is absolute, if the TFD_TIMER_ABSTIME bit
is set in the "flags" parameter.  Otherwise it's a relative time.

The timerfd_gettime() API returns the next expiration time of the timer, or
{0, 0} if the timerfd has not been set yet.

Like the previous timerfd API implementation, read(2) and poll(2) are
supported (with the same interface).  Here's a simple test program I used to
exercise the new timerfd APIs:

http://www.xmailserver.org/timerfd-test2.c

[akpm@linux-foundation.org: coding-style cleanups]
[akpm@linux-foundation.org: fix ia64 build]
[akpm@linux-foundation.org: fix m68k build]
[akpm@linux-foundation.org: fix mips build]
[akpm@linux-foundation.org: fix alpha, arm, blackfin, cris, m68k, s390, sparc and sparc64 builds]
[heiko.carstens@de.ibm.com: fix s390]
[akpm@linux-foundation.org: fix powerpc build]
[akpm@linux-foundation.org: fix sparc64 more]
Signed-off-by: Davide Libenzi <davidel@xmailserver.org>
Cc: Michael Kerrisk <mtk-manpages@gmx.net>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Davide Libenzi <davidel@xmailserver.org>
Cc: Michael Kerrisk <mtk-manpages@gmx.net>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Michael Kerrisk <mtk.manpages@gmail.com>
Cc: Davide Libenzi <davidel@xmailserver.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-02-05 09:44:07 -08:00
..
Makefile
apc.c
asm-offsets.c
auxio.c
cpu.c
devices.c [SPARC]: Add missing of_node_put 2007-12-05 05:38:00 -08:00
ebus.c
entry.S
errtbls.c
etrap.S
head.S
idprom.c
init_task.c
ioport.c Spelling fixes: lenght->length 2008-02-03 15:42:53 +02:00
irq.c [SPARC]: Remove duplicate includes. 2007-11-06 21:23:11 -08:00
irq.h
led.c
module.c
muldiv.c
of_device.c [SPARC/64]: Consolidate of_register_driver 2007-10-17 21:17:42 -07:00
pcic.c [SPARC]: Add missing "space" 2007-12-05 05:37:58 -08:00
pmc.c
process.c [SPARC32]: __inline__ --> inline 2007-10-27 00:17:01 -07:00
prom.c
ptrace.c [SPARC32]: Spelling fixes 2007-12-20 13:55:45 -08:00
rtrap.S
sclow.S
semaphore.c
setup.c [SPARC]: Constify function pointer tables. 2008-01-22 18:29:20 -08:00
signal.c
smp.c
sparc-stub.c
sparc_ksyms.c
sun4c_irq.c
sun4d_irq.c
sun4d_smp.c
sun4m_irq.c
sun4m_smp.c
sun4setup.c
sunos_asm.S
sunos_ioctl.c
sys_solaris.c
sys_sparc.c Use helpers to obtain task pid in printks (arch code) 2007-10-19 11:53:43 -07:00
sys_sunos.c pid namespaces: changes to show virtual ids to user 2007-10-19 11:53:40 -07:00
systbls.S timerfd: new timerfd API 2008-02-05 09:44:07 -08:00
tadpole.c
tick14.c
time.c [SPARC]: Make gettimeofday() monotonic again. 2008-01-12 21:52:15 -08:00
trampoline.S
traps.c Use helpers to obtain task pid in printks (arch code) 2007-10-19 11:53:43 -07:00
unaligned.c
vmlinux.lds.S all archs: consolidate init and exit sections in vmlinux.lds.h 2008-01-28 23:21:17 +01:00
windows.c
wof.S
wuf.S