NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
kern/58916: timerfd(2) claims ready for write
>Number: 58916
>Category: kern
>Synopsis: timerfd(2) claims ready for write
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: kern-bug-people
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Wed Dec 18 14:55:00 +0000 2024
>Originator: Taylor R Campbell
>Release: current, 10
>Organization:
The TimerFD Writation
>Environment:
>Description:
For a timerfd(2), select(2) returns writable if asked and poll(2) returns POLLOUT|POLLWRNORM if asked. (Also POLLRDNORM if asked.)
In contrast, in Linux, select(2) never returns writable and poll(2) never returns POLLOUT|POLLWRNORM -- or, for that matter, anything other than POLLIN.
Writing to a timerfd fails with EOPNOTSUPP, so it's not useful to claim writable. This doesn't appear to be a POSIX interface, so it looks like Linux is the `spec' here if I haven't missed anything obvious.
>How-To-Repeat:
run Python 3.13.1 test suite
======================================================================
FAIL: test_timerfd_ns_select (test.test_os.TimerfdTests.test_timerfd_ns_select)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/scratch/lang/python313/work/Python-3.13.1/Lib/test/test_os.py", line 4436, in test_timerfd_ns_select
self.assertEqual((rfd, wfd, xfd), ([], [], []))
~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError: Tuples differ: ([], [3], []) != ([], [], [])
First differing element 1:
[3]
[]
- ([], [3], [])
? -
+ ([], [], [])
>Fix:
Yes, please!
Home |
Main Index |
Thread Index |
Old Index