4 Commits

Author SHA1 Message Date
David van Moolenbroek
ca779acd72 Add sequence numbers to grant IDs
The memory grant identifier for safecopies now includes a sequence
number in its upper bits, to prevent accidental reuse of a grant ID
after revocation and subsequent reallocation.  This should increase
overall system robustness by a tiny amount, and possibly help catch
bugs in system services early on.  For now, the lower 20 bits of the
grant ID are used as grant table slot index (thus allowing for up to
a million grants per process), and the next 11 bits of the (signed
32-bit) grant ID are used to store the per-slot sequence number.  As
grant IDs are never exposed to userland, the split can be changed
later on without breaking the userland ABI.

Change-Id: Ic34be27ff2a45db0ea5db037a24eef9efcd9ca40
2016-01-16 14:04:19 +01:00
Dr. Florian Grätz
6077d1ad24 Kernel: convert K&R functions to ANSI
Changed all K&R style functions to ANSI-style declarations within the
kernel directory. The code compiles and aparently works for i386. For
arm my toolchain does not work, but I have changed the code with great
care. Also, the make command fails for the test suite. Therefore, I
strongly recommand to review the code with care.

Edited by David van Moolenbroek to convert really all K&R functions.

Change-Id: I58cde797d36f4caa9c72db4e4dc27d8545ab8866
2016-01-16 14:04:17 +01:00
Cristiano Giuffrida
9e6b1315c3 kernel: Allow kernel calls to return ENOTREADY.
This is required to avoid races with safecopy() at live update time.

Change-Id: I1f3e22d40f22d94bd2b850915f9b8163a08b5616
2015-09-16 11:02:31 +00:00
Lionel Sambuc
433d6423c3 New sources layout
Change-Id: Ic716f336b7071063997cf5b4dae6d50e0b4631e9
2014-07-31 16:00:30 +02:00