linux/include/asm-sparc64
Davide Libenzi f348d70a32 [PATCH] POLLRDHUP/EPOLLRDHUP handling for half-closed devices notifications
Implement the half-closed devices notifiation, by adding a new POLLRDHUP
(and its alias EPOLLRDHUP) bit to the existing poll/select sets.  Since the
existing POLLHUP handling, that does not report correctly half-closed
devices, was feared to be changed, this implementation leaves the current
POLLHUP reporting unchanged and simply add a new bit that is set in the few
places where it makes sense.  The same thing was discussed and conceptually
agreed quite some time ago:

http://lkml.org/lkml/2003/7/12/116

Since this new event bit is added to the existing Linux poll infrastruture,
even the existing poll/select system calls will be able to use it.  As far
as the existing POLLHUP handling, the patch leaves it as is.  The
pollrdhup-2.6.16.rc5-0.10.diff defines the POLLRDHUP for all the existing
archs and sets the bit in the six relevant files.  The other attached diff
is the simple change required to sys/epoll.h to add the EPOLLRDHUP
definition.

There is "a stupid program" to test POLLRDHUP delivery here:

 http://www.xmailserver.org/pollrdhup-test.c

It tests poll(2), but since the delivery is same epoll(2) will work equally.

Signed-off-by: Davide Libenzi <davidel@xmailserver.org>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Michael Kerrisk <mtk-manpages@gmx.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-25 08:22:56 -08:00
..
a.out.h [SPARC64]: Increase top of 32-bit process stack. 2006-03-20 01:16:36 -08:00
agp.h
apb.h
asi.h [SPARC64]: Sun4v specific ASI defines. 2006-03-20 01:11:43 -08:00
atomic.h [PATCH] atomic: add_unless cmpxchg optimise 2006-03-23 07:38:17 -08:00
auxio.h
auxvec.h
bbc.h
bitops.h [FLS64]: generic version 2006-01-03 13:11:06 -08:00
bpp.h
bsderrno.h
bug.h
bugs.h
byteorder.h
cache.h [PATCH] Move read_mostly definition to asm/cache.h 2006-03-23 07:38:10 -08:00
cacheflush.h
chafsr.h
checksum.h
chmctrl.h
cmt.h
compat.h
const.h
cpudata.h [SPARC64]: Add a secondary TSB for hugepage mappings. 2006-03-22 01:15:14 -08:00
cputime.h
current.h
dcr.h
dcu.h
delay.h
display7seg.h
div64.h
dma-mapping.h
dma.h
ebus.h [SPARC]: More abstractions and cleanups of dma handling in cs4231. 2005-11-07 14:09:19 -08:00
elf.h [SPARC64]: Add HWCAP_SPARC_BLKINIT elf capability flag for Niagara. 2006-03-20 01:13:26 -08:00
emergency-restart.h
envctrl.h
errno.h
estate.h
fbio.h
fcntl.h
fhc.h
floppy.h
fpumacro.h
futex.h [SPARC64]: Mark __ex_table section correctly. 2006-03-04 23:23:56 -08:00
hardirq.h
head.h [SPARC64]: Add GET_GL_GLOBAL() macro for SUN4V. 2006-03-20 01:13:18 -08:00
hw_irq.h
hypervisor.h [SPARC64]: Fix bugs in SUN4V cpu mondo dispatch. 2006-03-20 01:14:09 -08:00
ide.h
idprom.h [SPARC]: Clean up idprom header files. 2006-03-20 01:12:08 -08:00
intr_queue.h [SPARC64]: Sun4v interrupt queue register definitions. 2006-03-20 01:11:44 -08:00
io.h
ioctl.h
ioctls.h
iommu.h
ipc.h
ipcbuf.h
irq.h [SPARC64]: Fix uniprocessor IRQ targetting on SUN4V. 2006-03-20 01:13:24 -08:00
isa.h
kdebug.h
kmap_types.h
kprobes.h [PATCH] kprobes: fix build breakage 2006-01-10 08:01:40 -08:00
linkage.h
local.h
lsu.h
mc146818rtc.h
mman.h [PATCH] add asm-generic/mman.h 2006-02-15 15:32:22 -08:00
mmu.h [SPARC64]: Add a secondary TSB for hugepage mappings. 2006-03-22 01:15:14 -08:00
mmu_context.h [SPARC64]: Add a secondary TSB for hugepage mappings. 2006-03-22 01:15:14 -08:00
module.h
mostek.h
msgbuf.h
mutex.h [PATCH] mutex subsystem, add default include/asm-*/mutex.h files 2006-01-09 15:59:19 -08:00
namei.h
ns87303.h
numnodes.h [SPARC64]: Move over to sparsemem. 2006-03-20 01:14:22 -08:00
openprom.h
openpromio.h
oplib.h [SPARC64]: Fix system type in /proc/cpuinfo and remove bogus OBP check. 2006-03-20 01:14:25 -08:00
page.h [SPARC64]: Add a secondary TSB for hugepage mappings. 2006-03-22 01:15:14 -08:00
param.h
parport.h
pbm.h [SPARC64]: More SUN4V PCI controller work. 2006-03-20 01:12:11 -08:00
pci.h [SPARC64]: Beginnings of SUN4V PCI controller support. 2006-03-20 01:12:10 -08:00
pconf.h
percpu.h [PATCH] more for_each_cpu() conversions 2006-03-23 07:38:17 -08:00
perfctr.h
pgalloc.h [SPARC64]: Kill pgtable quicklists and use SLAB. 2006-03-20 01:11:14 -08:00
pgtable.h [SPARC64]: Add a secondary TSB for hugepage mappings. 2006-03-22 01:15:14 -08:00
pil.h [SPARC64]: Fix new context version SMP handling. 2006-03-20 01:14:21 -08:00
poll.h [PATCH] POLLRDHUP/EPOLLRDHUP handling for half-closed devices notifications 2006-03-25 08:22:56 -08:00
posix_types.h
processor.h [SPARC64]: Top-down address space allocation for 32-bit tasks. 2006-03-20 01:16:35 -08:00
psrcompat.h
pstate.h [SPARC64]: Fixup TSTATE layout diagram in asm/pstate.h 2006-03-20 01:13:02 -08:00
ptrace.h
reg.h
resource.h
rtc.h
rwsem-const.h
rwsem.h
sbus.h
scatterlist.h
scratchpad.h [SPARC64]: Sun4v scratchpad register layout. 2006-03-20 01:11:44 -08:00
seccomp.h
sections.h
semaphore.h
sembuf.h
setup.h
sfafsr.h
sfp-machine.h
shmbuf.h
shmparam.h
sigcontext.h
siginfo.h
signal.h
smp.h [SPARC64]: Add SMT scheduling support for Niagara. 2006-03-20 01:14:24 -08:00
socket.h
sockios.h
solerrno.h
sparsemem.h [SPARC64]: Move over to sparsemem. 2006-03-20 01:14:22 -08:00
spinlock.h [SPARC64]: Implement __raw_read_trylock() 2006-01-23 21:03:56 -08:00
spinlock_types.h
spitfire.h [SPARC64]: Add 'hypervisor' to ultra_tlb_type enumeration. 2006-03-20 01:11:39 -08:00
starfire.h
stat.h
statfs.h
string.h
sunbpp.h
svr4.h
system.h [SPARC64]: Kill all %pstate changes in context switch code. 2006-03-20 01:11:49 -08:00
termbits.h
termios.h [SPARC]: remove duplicate TIOCPKT_ definitions 2005-11-07 14:10:42 -08:00
thread_info.h [SPARC64]: Correctable ECC errors cannot occur at trap level > 0. 2006-03-20 01:11:33 -08:00
timer.h
timex.h [SPARC64]: Define ARCH_HAS_READ_CURRENT_TIMER. 2006-03-20 01:13:29 -08:00
tlb.h [SPARC64] mm: simpler tlb_flush_mmu 2005-11-07 14:12:08 -08:00
tlbflush.h [SPARC64]: Move away from virtual page tables, part 1. 2006-03-20 01:11:13 -08:00
topology.h
tsb.h [SPARC64]: Create a seperate kernel TSB for 4MB/256MB mappings. 2006-03-20 01:13:56 -08:00
ttable.h [SPARC64]: More TLB/TSB handling fixes. 2006-03-20 01:13:34 -08:00
types.h
uaccess.h [SPARC64]: __bzero_noasi --> __clear_user 2006-03-20 01:13:28 -08:00
uctx.h
unaligned.h
unistd.h [SPARC]: sys_newfstatat --> sys_fstatat64 2006-02-12 23:30:11 -08:00
upa.h
user.h
utrap.h
vdev.h [SPARC64]: Decode virtual-devices interrupts correctly. 2006-03-20 01:13:05 -08:00
vga.h
visasm.h
watchdog.h
xor.h [SPARC64]: Niagara optimized XOR functions for RAID. 2006-03-20 01:14:03 -08:00