Commit Graph

77 Commits

Author SHA1 Message Date
Thomas Schoebel-Theuer
925f564e8f net: safeguard socket aliveness 2023-05-23 10:47:38 +02:00
Thomas Schoebel-Theuer
3b1b98e686 net: correct interface adaptation 2023-02-20 09:22:34 +01:00
Thomas Schoebel-Theuer
26311c611c net: fix spelling of constants
The typo in mars_recv_raw() was equivalent to MSG_CONFIRM, which should
not imply a functional harm, but obviously any nonblocking
reads on sockets did not work as intended (by staying
a synchronous operation).

Two other potential typos now corrected, without causing a difference
in the resulting constant values.

Side note 1: kernel_connect() is documented in net/socket.c that the
spelling O_NONBLOCK is the right one.

Side note 2: kernel_accept() is documented in net/socket.c that the
spelling SOCK_NONBLOCK is the right one for this case.
However, this in turn is defined as equivalent to O_NONBLOCK
in include/linux/net.h (thus no real difference).

Overall: humans may be misleaded.
2023-02-19 17:23:39 +01:00
Thomas Schoebel-Theuer
4406b649af net: remember detected snd state transitions 2022-08-16 09:53:35 +02:00
Thomas Schoebel-Theuer
1fe3ff7c89 net: remember detected rcv state transitions 2022-08-16 09:53:35 +02:00
Thomas Schoebel-Theuer
bd0445ffce net: fix long-lasting rcv timeouts upon lost sockets 2022-08-16 09:53:35 +02:00
Thomas Schoebel-Theuer
19aea1fc59 net: fix long-lasting snd timeouts upon lost sockets 2022-08-16 09:53:35 +02:00
Thomas Schoebel-Theuer
701963fe28 net: factor out SS_CONNECTED state checking and add SS_CONNECTING 2022-08-16 09:53:35 +02:00
Thomas Schoebel-Theuer
eefd950f26 net: safeguard mref transfer 2022-05-27 07:43:54 +02:00
Thomas Schoebel-Theuer
dfd4fc3478 net: improve error reporting 2022-05-16 17:56:46 +02:00
Thomas Schoebel-Theuer
d066093807 net: fix aborts during string receive 2022-05-16 17:56:39 +02:00
Thomas Schoebel-Theuer
5237ca4b16 all: adapt to SO_SNDTIMEO_NEW 2021-02-10 13:36:06 +01:00
Thomas Schoebel-Theuer
2cb3520e01 infra: rework net address parsing 2020-11-07 08:01:06 +01:00
Thomas Schoebel-Theuer
530a938a62 net: safeguard recv of bad string size 2020-11-07 07:58:53 +01:00
Thomas Schoebel-Theuer
e1547a1387 net: better sending failure status code 2020-10-28 06:09:11 +01:00
Thomas Schoebel-Theuer
27d3e9ff9b net: use IP_FREEBIND for server sockets 2020-08-11 09:17:52 +02:00
Thomas Schoebel-Theuer
8d9ac84b46 infra: extend cmds with 2 strings 2020-07-20 21:20:47 +02:00
Thomas Schoebel-Theuer
e551b6d89f infra: make Lamport exchange more generic 2020-07-08 21:09:39 +02:00
Thomas Schoebel-Theuer
ea4fbc1885 all: remove superfluous dealloc tests and clears 2020-07-08 21:00:05 +02:00
Thomas Schoebel-Theuer
a8b91e2d8a net: fix decompression block-aligned allocation 2020-06-30 21:07:09 +02:00
Thomas Schoebel-Theuer
d0dcec57b1 net: suppress annoying error message 2020-05-17 07:38:23 +02:00
Thomas Schoebel-Theuer
8a86c08750 net: correct error message 2020-04-13 11:21:17 +02:00
Thomas Schoebel-Theuer
95883b055c infra: allow transport compression 2020-04-13 11:21:17 +02:00
Thomas Schoebel-Theuer
66d6659462 net: simplify mars_recv_cb() 2020-04-13 11:21:16 +02:00
Thomas Schoebel-Theuer
4256cc17a1 net: simplify mref sending 2020-04-13 11:21:16 +02:00
Thomas Schoebel-Theuer
9e6fb4120c infra: deprecate ref_cs_mode 2020-04-13 10:54:19 +02:00
Thomas Schoebel-Theuer
d87fb27473 all: deprecate mref_skip_sync 2020-04-13 10:54:19 +02:00
Thomas Schoebel-Theuer
40e72f9e7d all: deprecate mref_rw and mref_may_write 2020-04-13 10:54:19 +02:00
Thomas Schoebel-Theuer
131b28e377 infra: introduce common_proto_level 2020-04-13 09:55:19 +02:00
Thomas Schoebel-Theuer
593ca2bb8f infra: allow mixed network protocol levels 2020-04-13 09:55:19 +02:00
Thomas Schoebel-Theuer
0c5b5daa38 infra: {send,recv}ing mars_cmd via wrapper 2020-04-13 09:55:19 +02:00
Thomas Schoebel-Theuer
f8e552a21b net: ignore signals 2019-12-25 09:19:08 +01:00
Thomas Schoebel-Theuer
222f048937 all: adapt to new timespec64 type 2019-12-25 09:19:07 +01:00
Thomas Schoebel-Theuer
a8766f3016 net: move compat check 2019-12-25 09:19:07 +01:00
Thomas Schoebel-Theuer
764399d262 net: move compat check 2019-12-25 09:19:07 +01:00
Thomas Schoebel-Theuer
8257466b14 Merge branch 'mars0.1.y' into mars0.1a.y 2018-10-22 13:07:23 +02:00
Thomas Schoebel-Theuer
0d579d48ba net: fix O_NONBLOCK races
Runtime modification of _shared_ socket flags like O_NONBLOCK
is a bad idea. If I remember correctly, long ago there was no
other way. Current kernels allow different flags on the stack per
kernel_*() call, but I am not sure whether this could break
compatibility with some very ancient kernels. Unfortunately, I
cannot test MARS with these dinosaur kernels anymore, but hopefully
nobody uses them anyway.
2018-10-22 10:49:29 +02:00
Thomas Schoebel-Theuer
1615dbf538 net: make TOS / DSCP compile time configurable 2018-05-15 14:57:27 +02:00
Thomas Schoebel-Theuer
d5dc1ea8af all: differentiate traffic types 2018-05-14 20:42:00 +02:00
Thomas Schoebel-Theuer
1d3fb447d5 net: make mars_accept_socket() options dynamic 2018-05-14 19:42:05 +02:00
Thomas Schoebel-Theuer
2dff1c0c14 net: make mars_create_socket() options dynamic 2018-05-14 19:42:05 +02:00
Thomas Schoebel-Theuer
922a82d25e net: make socket options dynamic 2018-05-14 19:42:04 +02:00
Thomas Schoebel-Theuer
165f40ef41 client: adapt socket aborts to io_timeout 2018-03-19 06:41:10 +01:00
Thomas Schoebel-Theuer
2c6615e5ea net: speedup rmmod 2017-09-12 09:34:14 +02:00
Thomas Schoebel-Theuer
cf25790fd2 Merge tag 'mars0.1stable48' into mars0.1a.y 2017-09-11 11:53:28 +02:00
Thomas Schoebel-Theuer
56d7f72a62 net: early detection of socket hangups 2017-09-08 23:42:30 +02:00
Thomas Schoebel-Theuer
b32b2d57fe net: use quadratic backoff sleeptime 2017-05-28 19:20:26 +02:00
Thomas Schoebel-Theuer
ee1cf12efa infra: add non-strict version of Lamport clock 2017-05-28 19:20:25 +02:00
Thomas Schoebel-Theuer
d9d31d831e net: don't update Lamport clock too often 2017-04-15 18:10:45 +02:00
Thomas Schoebel-Theuer
4f071e362f infra: new interface to Lamport clock 2017-04-15 18:10:44 +02:00