@@ -142,19 +142,22 @@ Raspberry Pi models. Code compiled for `arm1176` can be run on later 32 bits
142
142
CPUs.
143
143
144
144
The following values are specially processed :
145
- - ` arm1176` equivalent to `arm1176:cortex-a53`.
146
- - ` cortex-a7` equivalent to `cortex-a7:cortex-a53`. Optimized for later Pi
147
- models (Pi 3/Pi 4 and Pi Zero 2). Not suitable for Pi 1/Pi 2/Pi Zero.
148
- - ` cortex-a8` equivalent to `cortex-a8:max`.
149
- - ` cortex-a53` equivalent to `max:cortex-a53`.
145
+ - ` arm1176` equivalent to `arm1176:cortex-a53`.
146
+ - ` cortex-a7` equivalent to `cortex-a7:cortex-a53`. Optimized for later Pi
147
+ models (Pi 3/Pi 4 and Pi Zero 2). Not suitable for Pi 1/Pi 2/Pi Zero.
148
+ - ` cortex-a8` equivalent to `cortex-a8:max`.
149
+ - ` cortex-a53` equivalent to `max:cortex-a53`.
150
+ - ` cortex-a76` equivalent to `max:cortex-a76`. Note that this requires a newer
151
+ version of qemu, for example with runner ubuntu 24.04. See `test_cortex_a76`
152
+ in [cpu_info test](.github/workflows/test-cpu_info.yml).
150
153
151
154
Some software uses the output of `uname -m` or equivalent. This command is
152
155
directly driven by this `cpu` option. You might want to compile 32 bits
153
156
binaries with both `arm1176` which translates to `armv6l` and `cortex-a7` which
154
157
translates to `armv7l`.
155
158
156
159
For FPU and vector instruction sets, software usually automatically looks into
157
- ` /proc/cpuinfo` or equivalent. This can be patched with `cpu_info` option.
160
+ ` /proc/cpuinfo` or equivalent. See `cpu_info` option below .
158
161
159
162
Whether code is executed in 32 bits or 64 bits (and build generates 32 bits
160
163
or 64 bits binaries) depend on the image. See _32 and 64 bits_ below.
@@ -192,20 +195,23 @@ from the target system.
192
195
# ### `cpu_info`
193
196
194
197
Path to a fake cpu_info file to be used instead of `/proc/cpuinfo`. Default is
195
- to not fake the CPU (/proc/cpuinfo will report amd64 CPU of GitHub runner).
198
+ to not fake the CPU. With older versions of qemu, including the one provided
199
+ by ubuntu-latest as of this writing (ubuntu 22.04, qemu 6), `/proc/cpuinfo` is
200
+ not intercepted and will report amd64 CPU of GitHub runner.
196
201
197
202
Some software checks for features using `/proc/cpuinfo` and this option can be
198
203
used to trick them. The path is relative to the action (to use pre-defined
199
204
settings) or to the local repository.
200
205
201
206
Bundled with the action are the following 32 bits CPU infos :
202
- - ` cpuinfo/raspberrypi_zero_w`
203
- - ` cpuinfo/raspberrypi_3b` (requires `cortex-a7` cpu)
204
- - ` cpuinfo/raspberrypi_zero2_w` (requires `cortex-a7` cpu)
207
+ - ` cpuinfo/raspberrypi_zero_w`
208
+ - ` cpuinfo/raspberrypi_3b` (requires `cortex-a7` cpu)
209
+ - ` cpuinfo/raspberrypi_zero2_w` (requires `cortex-a7` cpu)
205
210
206
211
As well as the following 64 bits CPU infos :
207
- - ` cpuinfo/raspberrypi_4b`
208
- - ` cpuinfo/raspberrypi_zero2_w_arm64`
212
+ - ` cpuinfo/raspberrypi_4b`
213
+ - ` cpuinfo/raspberrypi_zero2_w_arm64`
214
+ - ` cpuinfo/raspberrypi_5`
209
215
210
216
On real hardware, the `/proc/cpuinfo` file content depends on the CPU being
211
217
used in 32 bits or 64 bits mode, which in turn depends on the base image.
@@ -217,6 +223,10 @@ passed to `cpu` option. In particular, when using 32 bits `cpu_info`, the
217
223
default emulated CPU for 32 bits may not work and you should set `cpu` option
218
224
to `cortex-a7`.
219
225
226
+ qemu 8.2 and higher do intercept `/proc/cpuinfo` to report something related
227
+ to the passed cpu option. So if you are running ubuntu-24.04 or if you install
228
+ your own version of qemu-user-arm/aarch64, this option will be effectless.
229
+
220
230
# ### `optimize_image`
221
231
222
232
Zero-fill unused filesystem blocks and shrink root filesystem during final clean-up, to make any later
0 commit comments