@@ -43,8 +43,6 @@ and there’s also an input pool which gathers entropy from various sources
43
43
available on the system, and is used to feed into or seed the other two
44
44
components. A very detailed description is available [ here] [ 3 ] .
45
45
46
- ### Linux kernels from 4.8 until 5.17 (included)
47
-
48
46
The details of this newer implementation are used to make the recommendations
49
47
present in the document. There are in-kernel interfaces used to obtain random
50
48
numbers as well, but they are similar to using ` /dev/urandom ` (or ` getrandom `
@@ -103,15 +101,17 @@ not increase the current entropy estimation. There is also an `ioctl` interface
103
101
which, given the appropriate privileges, can be used to add data to the input
104
102
entropy pool while also increasing the count, or completely empty all pools.
105
103
106
- ### Linux kernels from 5.18 onwards
107
-
108
- Since version 5.18, Linux has support for the
109
- [ Virtual Machine Generation Identifier] ( https://learn.microsoft.com/en-us/windows/win32/hyperv_v2/virtual-machine-generation-identifier ) .
110
- The purpose of VMGenID is to notify the guest about time shift events, such as
111
- resuming from a snapshot. The device exposes a 16-byte cryptographically random
112
- identifier in guest memory. Firecracker implements VMGenID. When resuming a
113
- microVM from a snapshot Firecracker writes a new identifier and injects a
114
- notification to the guest. Linux,
104
+ ### Linux kernels with VMGenID support
105
+
106
+ Linux has support for the
107
+ [ Virtual Machine Generation Identifier] ( https://learn.microsoft.com/en-us/windows/win32/hyperv_v2/virtual-machine-generation-identifier )
108
+ since 5.18 for ACPI systems. Since 6.10, Linux added support also for systems
109
+ that use DeviceTree instead of ACPI. The purpose of VMGenID is to notify the
110
+ guest about time shift events, such as resuming from a snapshot. The device
111
+ exposes a 16-byte cryptographically random identifier in guest memory.
112
+ Firecracker implements VMGenID. When resuming a microVM from a snapshot
113
+ Firecracker writes a new identifier and injects a notification to the guest.
114
+ Linux,
115
115
[ uses this value] ( https://elixir.bootlin.com/linux/v5.18.19/source/drivers/virt/vmgenid.c#L77 )
116
116
[ as new randomness for its CSPRNG] ( https://elixir.bootlin.com/linux/v5.18.19/source/drivers/char/random.c#L908 ) .
117
117
Quoting the random.c implementation of the kernel:
@@ -133,9 +133,15 @@ to emit a uevent to user space when it handles the notification. User space can
133
133
poll this uevent to know when it is safe to use ` getrandom() ` , et al. avoiding
134
134
the race condition.
135
135
136
- Please note that, Firecracker will always enable VMGenID. In kernels earlier
137
- than 5.18, where there is no VMGenID driver, the device will not have any effect
138
- in the guest.
136
+ Firecracker supports VMGenID on ARM systems using the DeviceTree binding that
137
+ was added for the device in Linux 6.10. However, the latest Linux kernel that
138
+ Firecracker supports is 6.1. As a result, in order to use VMGenID on ARM
139
+ systems, users need to use a 6.1 kernel with the DeviceTree binding support
140
+ backported from 6.10. We provide a set of patches that apply cleanly on mainline
141
+ Linux 6.1 [ here] ( ../../resources/patches/vmgenid_dt ) .
142
+
143
+ Please note that, Firecracker will always enable VMGenID. In kernels where there
144
+ is no VMGenID driver, the device will not have any effect in the guest.
139
145
140
146
### User space considerations
141
147
0 commit comments