forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit3ab4fc5
committed
Don't trust signalfd() on illumos.
Since commit6a2a70a, we've used signalfd() to receive latch wakeupswhen building with WAIT_USE_EPOLL (default for Linux and illumos), andour traditional self-pipe when falling back to WAIT_USE_POLL (defaultfor other Unixes with neither epoll() nor kqueue()).Unexplained hangs and kernel panics have been reported on illumossystems, apparently linked to this use of signalfd(), leading illumosusers and build farm members to have to define WAIT_USE_POLL explicitlyas a work-around. A bug report exists athttps://www.illumos.org/issues/13700 but no fix is available yet.Let's provide a way for illumos users to go back to self-pipes withepoll(), like releases before 14, and choose that by default. No changefor Linux users. To help with development/debugging, macrosWAIT_USE_{EPOLL,POLL} and WAIT_USE_{SIGNALFD,SELF_PIPE} can be definedexplicitly to override the defaults.Back-patch to 14, where we started using signalfd().Reported-by: Japin Li <japinli@hotmail.com>Reported-by: Olaf Bohlen <olbohlen@eenfach.de> (off-list)Reviewed-by: Japin Li <japinli@hotmail.com>Discussion:https://postgr.es/m/MEYP282MB1669C8D88F0997354C2313C1B6CA9%40MEYP282MB1669.AUSP282.PROD.OUTLOOK.COM1 parent00377b9 commit3ab4fc5
1 file changed
+40
-18
lines changedLines changed: 40 additions & 18 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
72 | 72 |
| |
73 | 73 |
| |
74 | 74 |
| |
75 |
| - | |
| 75 | + | |
76 | 76 |
| |
77 | 77 |
| |
78 | 78 |
| |
| |||
84 | 84 |
| |
85 | 85 |
| |
86 | 86 |
| |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
87 | 103 |
| |
88 | 104 |
| |
89 | 105 |
| |
| |||
146 | 162 |
| |
147 | 163 |
| |
148 | 164 |
| |
149 |
| - | |
| 165 | + | |
150 | 166 |
| |
151 | 167 |
| |
152 | 168 |
| |
153 | 169 |
| |
154 |
| - | |
| 170 | + | |
155 | 171 |
| |
156 | 172 |
| |
157 | 173 |
| |
| |||
164 | 180 |
| |
165 | 181 |
| |
166 | 182 |
| |
167 |
| - | |
| 183 | + | |
168 | 184 |
| |
169 | 185 |
| |
170 | 186 |
| |
| |||
190 | 206 |
| |
191 | 207 |
| |
192 | 208 |
| |
193 |
| - | |
| 209 | + | |
194 | 210 |
| |
195 | 211 |
| |
196 | 212 |
| |
| |||
264 | 280 |
| |
265 | 281 |
| |
266 | 282 |
| |
267 |
| - | |
| 283 | + | |
268 | 284 |
| |
269 | 285 |
| |
270 | 286 |
| |
| |||
316 | 332 |
| |
317 | 333 |
| |
318 | 334 |
| |
319 |
| - | |
| 335 | + | |
320 | 336 |
| |
321 | 337 |
| |
322 | 338 |
| |
323 | 339 |
| |
324 | 340 |
| |
325 | 341 |
| |
326 | 342 |
| |
327 |
| - | |
| 343 | + | |
328 | 344 |
| |
329 | 345 |
| |
330 | 346 |
| |
| |||
341 | 357 |
| |
342 | 358 |
| |
343 | 359 |
| |
344 |
| - | |
| 360 | + | |
345 | 361 |
| |
346 | 362 |
| |
| 363 | + | |
| 364 | + | |
| 365 | + | |
347 | 366 |
| |
348 | 367 |
| |
349 | 368 |
| |
| |||
407 | 426 |
| |
408 | 427 |
| |
409 | 428 |
| |
410 |
| - | |
| 429 | + | |
411 | 430 |
| |
412 | 431 |
| |
| 432 | + | |
| 433 | + | |
| 434 | + | |
413 | 435 |
| |
414 | 436 |
| |
415 | 437 |
| |
| |||
620 | 642 |
| |
621 | 643 |
| |
622 | 644 |
| |
623 |
| - | |
| 645 | + | |
624 | 646 |
| |
625 | 647 |
| |
626 | 648 |
| |
| |||
907 | 929 |
| |
908 | 930 |
| |
909 | 931 |
| |
910 |
| - | |
| 932 | + | |
911 | 933 |
| |
912 |
| - | |
| 934 | + | |
913 | 935 |
| |
914 | 936 |
| |
915 | 937 |
| |
| |||
2086 | 2108 |
| |
2087 | 2109 |
| |
2088 | 2110 |
| |
2089 |
| - | |
| 2111 | + | |
2090 | 2112 |
| |
2091 | 2113 |
| |
2092 | 2114 |
| |
| |||
2137 | 2159 |
| |
2138 | 2160 |
| |
2139 | 2161 |
| |
2140 |
| - | |
| 2162 | + | |
2141 | 2163 |
| |
2142 | 2164 |
| |
2143 | 2165 |
| |
| |||
2153 | 2175 |
| |
2154 | 2176 |
| |
2155 | 2177 |
| |
2156 |
| - | |
| 2178 | + | |
2157 | 2179 |
| |
2158 | 2180 |
| |
2159 | 2181 |
| |
| |||
2171 | 2193 |
| |
2172 | 2194 |
| |
2173 | 2195 |
| |
2174 |
| - | |
| 2196 | + | |
2175 | 2197 |
| |
2176 | 2198 |
| |
2177 | 2199 |
| |
| |||
2181 | 2203 |
| |
2182 | 2204 |
| |
2183 | 2205 |
| |
2184 |
| - | |
| 2206 | + | |
2185 | 2207 |
| |
2186 | 2208 |
| |
2187 | 2209 |
| |
|
0 commit comments
Comments
(0)