[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[SCM] Hurd branch, rbraun/select_timeout_pthread, created. hurd-release-
From: |
Richard Braun |
Subject: |
[SCM] Hurd branch, rbraun/select_timeout_pthread, created. hurd-release-0-2-3481-gbe6e5b8 |
Date: |
Sun, 10 Feb 2013 20:20:46 +0000 |
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Hurd".
The branch, rbraun/select_timeout_pthread has been created
at be6e5b86bdb9055b01ab929cb6b6eec49521ef93 (commit)
- Log -----------------------------------------------------------------
commit be6e5b86bdb9055b01ab929cb6b6eec49521ef93
Author: Richard Braun <address@hidden>
Date: Sun Feb 10 21:11:46 2013 +0100
Selectively compile io_select{,_timeout} as a routine
Now that servers implement the select timeout, there is no need for a
waittime MIG parameter. In order to make client calls asynchronous,
io_select and io_select_timeout should be simple routines. But in order
to minimize changes in the server code, it would be better to keep them
as routines. A new build macro, _HURD_IO_SELECT_ROUTINE, allows choosing
how these RPCs are compiled by MIG.
* Makeconf (CPPFLAGS): Add -D_HURD_IO_SELECT_ROUTINE.
* hurd/io.defs (io_select_timeout): Declare as a routine if
_HURD_IO_SELECT_ROUTINE is defined, or a simpleroutine otherwise.
(io_select): Likewise. In addition, remove the waittime timeout parameter.
commit 1d391c682b05a988b523a94e41e6d21a56d66fa8
Author: Richard Braun <address@hidden>
Date: Sat Feb 9 15:06:43 2013 +0100
Add io_select_timeout to the io interface
This change fixes a problem that can occur with non-blocking (and also
blocking for very short times) select/poll calls. The problem occurs
because the timeout is implemented at the client side. For a
non-blocking call, this means that (depending on the code path taken in
the C library) the client could get a timeout without a full RPC
round-trip to the server. Moving the implementation of the timeout to
the servers guarantees a full round-trip, and correct results for
non-blocking calls.
A new type, time_data_t, is introduced as well. Except for the integer
widths, its internal format matches the standard struct timespec.
This change depends on the availability of the recently added
pthread_hurd_cond_timedwait_np function in libpthread.
* boot/boot.c (io_select_common): New static function.
(S_io_select): Use io_select_common.
(S_io_select_timeout): New function which makes use of io_select_common.
* console-client/kbd-repeat.c (repeater_select): Add a timeout parameter.
* console-client/pc-mouse.c (repeater_select): Likewise.
* console-client/trans.c (io_select_common): New static function.
(netfs_S_io_select): Use io_select_common.
(netfs_S_io_select_timeout): New function which makes use of
io_select_common.
* console-client/trans.h (struct consnode): Add a timeout parameter.
* hurd/hurd_types.defs (time_data_t): New type.
* hurd/hurd_types.h (struct time_data) (time_data_t): Likewise.
* hurd/io.defs (io_select_timeout): New MIG routine.
* libdiskfs/io-select.c (diskfs_S_io_select_timeout): New function.
* libnetfs/io-select.c (netfs_S_io_select_timeout): Likewise.
* libpipe/pipe.c (pipe_pair_select): Add a timeout parameter.
* libpipe/pipe.h (pipe_select_readable): Likewise.
(pipe_select_writable): Likewise.
(pipe_pair_select): Likewise.
* libpipe/pq.h: Include <hurd/hurd_types.h>.
* libtrivfs/io-select.c (trivfs_S_io_select_timeout): New function.
* pfinet/glue-include/linux/sched.h: Include <errno.h>.
(interruptible_sleep_on): Function removed, replaced with ...
(interruptible_sleep_on_timeout): New function.
(schedule): Update to use interruptible_sleep_on_timeout.
(schedule_timeout): Likewise.
* pfinet/io-ops.c (io_select_common): New static function.
(S_io_select): Use io_select_common.
(S_io_select_timeout): New function which makes use of io_select_common.
* pfinet/tunnel.c (io_select_common): New static function.
(trivfs_S_io_select): Use io_select_common.
(trivfs_S_io_select_timeout): New function which makes use of
io_select_common.
* pflocal/connq.c (connq_listen): Replace noblock with a timeout
parameter.
* pflocal/connq.h: Include <hurd/hurd_types.h>.
(connq_listen): Update declaration to replace noblock with a timeout
parameter.
* pflocal/io.c (io_select_common): New static function.
(S_io_select): Use io_select_common.
(S_io_select_timeout): New function which makes use of io_select_common.
* pflocal/socket.c (S_socket_accept): Update call to connq_listen to
match new declaration.
* storeio/io.c (trivfs_S_io_select_timeout): New function.
* term/ptyio.c (pty_io_select): Add a timeout parameter.
* term/term.h (pty_io_select): Likewise.
* term/users.c (io_select_common): New static function.
(trivfs_S_io_select): Use io_select_common.
(trivfs_S_io_select_timeout): New function which makes use of
io_select_common.
* trans/fifo.c (io_select_common): New static function.
(trivfs_S_io_select): Use io_select_common.
(trivfs_S_io_select_timeout): New function which makes use of
io_select_common.
* trans/firmlink.c (trivfs_S_io_select_timeout): New function.
* trans/new-fifo.c (io_select_common): New static function.
(trivfs_S_io_select): Use io_select_common.
(trivfs_S_io_select_timeout): New function which makes use of
io_select_common.
* trans/null.c (trivfs_S_io_select_timeout): New function.
* trans/streamio.c (io_select_common): New static function.
(trivfs_S_io_select): Use io_select_common.
(trivfs_S_io_select_timeout): New function which makes use of
io_select_common.
-----------------------------------------------------------------------
hooks/post-receive
--
Hurd
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [SCM] Hurd branch, rbraun/select_timeout_pthread, created. hurd-release-0-2-3481-gbe6e5b8,
Richard Braun <=