Commit Graph

240860 Commits

Author SHA1 Message Date
christos be8ee66399 PR/50823: David Binderman: Limit scanf width 2016-02-17 19:52:20 +00:00
christos d6c5440ef4 PR/50824: David Binderman: Limit scanf width 2016-02-17 19:51:29 +00:00
christos 22383670cc whitespace and header sorting changes (Ingo Schwarze). No functional changes. 2016-02-17 19:47:49 +00:00
riastradh 446ef7b7a7 Don't schedule a softint if we have nothing to do.
Some systems seem to have gotten stuck in a softint processing loop
doing nothing and then trying to do it again.  Might fix gson's
frozen qemu/anita sparc autobuilds -- tested on macallan's real sparc
hardware and confirmed to fix at least some freeze at boot.
2016-02-17 19:44:40 +00:00
plunky e6e528b81c extend the match function, to match devices from a selection of
manufacturers that use modern Broadcom chips, and which represent
as a vendor-specific device class.
2016-02-17 10:52:55 +00:00
riastradh d80621961e Need <sys/mutex.h> for mutex(9). 2016-02-17 01:48:36 +00:00
riastradh 9e2ce23efb Caller must have exclusive access to rndsource for rnd_add_data(_sync). 2016-02-17 01:48:04 +00:00
riastradh e3389acee7 Make hyperentropy rndsource work synchronously, again.
This time for real!  *crosses fingers*
2016-02-17 01:42:25 +00:00
riastradh 7e7551b30d Move entropy_count into the scope where it is used.
Omit now-unused definition.

XXX This code probably shouldn't be under DIAGNOSTIC...  It is
significantly more than just an assertion.
2016-02-17 01:23:32 +00:00
riastradh 25f6b3cbaa Use real atomics, not atomics faked with membars, for rnd_printing. 2016-02-17 01:09:49 +00:00
riastradh 4242e92df8 Omit needless call to rnd_getmore in rnd_extract_data.
The only remaining caller -- rnd_extract -- already does it.
2016-02-17 01:01:42 +00:00
riastradh 3d1bee43d3 Omit call to rnd_getmore from rnd_process_events.
There are three cases to consider here:

1. You have on-demand synchronous rndsources, e.g. RDRAND (and you're
willing to use it).  In that case, you'll just use those whenever you
need to extract entropy.  There's no benefit to requesting more from
them when we're entering data into the pool.

2. You have on-demand asynchronous rndsources.  These should continue
trying to feed data to the entropy pool as long as it needs more, so
there's no benefit to requesting more from them when we're entering
data into the pool.

3. You don't have any on-demand rndsources.  Then rnd_getmore does
nothing, so there's no benefit to calling it.

ok tls
2016-02-17 00:57:36 +00:00
riastradh 0cbde2cd73 Match various Apple USB Bluetooth controllers.
From mlelstv.
2016-02-17 00:49:28 +00:00
riastradh bb2b89402e regen 2016-02-17 00:48:57 +00:00
riastradh 535089561c Add various USB Bluetooth controllers.
From mlelstv.
2016-02-17 00:46:17 +00:00
riastradh 3945f2f07a Add rnd_add_data_sync for synchronous on-demand rndsource callbacks.
Avoids lock recursion in rndsinks:

rndsink user holds lock
calls rndsink_request
calls rnd_getmore
calls an rndsource callback
calls rnd_add_data
calls rnd_process_events
calls rndsinks_distribute
calls rndsink callback
acquires rndsink user lock.

This can happen only before the rnd_process_events softint is
established, but that's enough to cause a problem and is the main
reason why all our HWRNG drivers are so byzantine (soon to be
fixed!).

ok tls
2016-02-17 00:43:42 +00:00
riastradh a7a8acd649 Cast uint8_t to uint32_t before shifting left by 24.
Otherwise this is undefined behaviour unless int is 32-bit and the
uint8_t value happens to be <=127.
2016-02-17 00:01:23 +00:00
riastradh 7d9363db07 Need <sys/queue.h> for LIST_ENTRY and <sys/null.h> for NULL. 2016-02-16 23:07:58 +00:00
christos e84df91e32 More header cleanups from Ingo Schwarze. 2016-02-16 22:53:14 +00:00
christos bc4f01ce82 - don't set _GNU_SOURCE. We are not supposed to make decisions for others.
- don't special-case wcsdup()
From Ingo Schwarze.
2016-02-16 19:29:51 +00:00
christos 23f3e7075d get rid of bool_t (Ingo Schwarze) 2016-02-16 19:11:25 +00:00
christos 747f681109 more include file cleanup (Ingo Schwarze) 2016-02-16 19:08:41 +00:00
christos a539b892c3 include errno.h 2016-02-16 15:54:15 +00:00
christos aefc1e4460 From Ingo Scharze:
Let "el.h" include everything needed for struct editline,
and don't include that stuff multiple times.  That also improves
consistency, also avoids circular inclusions, and also makes it
easier to follow what is going on, even though not quite as nice.
But it seems like the best we can do...
2016-02-16 15:53:48 +00:00
christos f09cb8c626 cleanup chartype.h includes (Ingo Schwarze) 2016-02-16 14:08:25 +00:00
christos c807fdff98 one more 2016-02-16 14:07:47 +00:00
christos 40850369f8 cleanup inclusion of histedit.h (Ingo Schwarze) 2016-02-16 14:06:05 +00:00
christos 89cffc1532 include explicitly errno.h since we use it. 2016-02-16 14:04:58 +00:00
christos 67bb823526 No need to include "sys.h" from here; it is included from config.h 2016-02-16 14:04:24 +00:00
bouyer f35e6799e0 In xennet_xenbus_detach(), remove the event handler early (just after
xennet_stop()) so that we don't get events while slepping (e.g.
in softint_disestablish()) when some structures have already been
freed.
Problem reported and patch tested by Rohan Desai.
2016-02-16 08:41:32 +00:00
skrll 970a1b8e99 Re-enable the TT support that existed previously. 2016-02-16 07:51:13 +00:00
nonaka 732816bd3f Reduced INSTALL kernel size. 2016-02-16 05:14:31 +00:00
ozaki-r 1926a64c9e Remove workaround for GATEWAY
The workaround was introduced because lltable/llentry uses rwlock
but it may be executed in hardware interrupt due to fast forward.
Now we don't run fast forward in hardware interrupt anymore, so
we can remove the workaround.
2016-02-16 01:31:26 +00:00
christos d8252c8b23 attribute unused 2016-02-15 23:36:30 +00:00
christos 67b10d3e9e OpenBSD term.c rev. 1.7 2002/11/29 20:13:39 deraadt
spelling
2016-02-15 22:53:38 +00:00
christos f91f480498 OpenBSD readline.c rev. 1.14 2015/02/06 23:21:58 millert
use SIZE_MAX
2016-02-15 22:48:59 +00:00
riastradh f1c295721b cardbus autoconf uses cardbus_attach_args, not isapnp_attach_args. 2016-02-15 22:37:54 +00:00
christos 92b1772005 OpenBSD readline.c rev. 1.13 2015/01/13 08:33:12 reyk
rl_set_keyboard_input_timeout() for readline 4.2 compat
2016-02-15 21:58:37 +00:00
christos f8ee3c5528 OpenBSD eln.c rev. 1.3 2011/11/27 21:46:44 pascal
kill a C++-style comment
2016-02-15 21:56:35 +00:00
christos 42e2a4d875 Compile with WIDECHAR the same way the main Makefile does (Ingo Schwarze) 2016-02-15 21:38:07 +00:00
christos 1e12a8d1ca Don't free getline memory (Ingo Schwarze). 2016-02-15 21:35:52 +00:00
snj 00523047e3 allllllexander the greeeaaaaat, his name struck fear into hearts of men!
...but let's conquer that fear and give ol' alex a consistent and
correct date of death.

(he died of fever in baaaaaabylooooooonnnn)
2016-02-15 20:58:02 +00:00
riastradh 0c08237178 Use KASSERTs supported by CTASSERTs, not __builtin_unreachable.
pcc has no __builtin_unreachable, and this is clearer anyway.
2016-02-15 20:35:59 +00:00
snj ab9bcecd45 fix english 2016-02-15 20:33:18 +00:00
riastradh 523712cd76 Print error code for failure to map PRAMIN BAR. 2016-02-15 19:36:35 +00:00
rtr 0a0528fd0a Fix building of IPv4-Mapped IPv6 addresses.
As discussed on tech-net@ use in6_sin_2_v4mapsin6() to build mapped
addresses.
2016-02-15 19:00:42 +00:00
christos e8d0e8c012 forgot one fgetln define 2016-02-15 17:35:39 +00:00
christos 5390c8faa5 change tests for fgetln. 2016-02-15 16:14:39 +00:00
mbalmer 13a5a21897 Fix function name, no functional change.
Found by Travis Paul, (see PR/50786), thanks for reporting!
2016-02-15 15:56:33 +00:00
christos a7ab79fbe5 Use getline for better portability. 2016-02-15 15:53:45 +00:00