New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
/proc/cpuinfo missing Hardware/Revision/Serial on arm64 #2110
Comments
This trouble renders all Rasberry Pi GPIO etc. scripts unusable on this architecture. |
|
This is a won't fix. |
A simple, although not very elegant, workaround for this (without patching the userspace libraries or kernel) is to bind-mount a faux version of With the
hth, |
Decode hardware revision from either: 1) 'revision' string in /proc/cpuinfo (legacy) 2) binary number in /proc/device-tree/system/linux,revision The second path is recommended by raspberrypi.org for newer operating systems. See raspberrypi/linux#2110
The information contained in /proc/cpuinfo while using an arm64 kernel contains less information than then 32-bit arm version, leading to the system not being recognized as a Raspberry Pi, e.g. by the RPi.GPIO library.
Especially, the missing Hardware/Revision lines below the individual CPUs seem to cause trouble, as they are being used for identification of the specific model.
From what I can see in the source code, for arm64 the cpuinfo comes from here: https://github.com/raspberrypi/linux/blob/rpi-4.12.y/arch/arm64/kernel/cpuinfo.c, while for arm it is generated in setup.c (would be https://github.com/raspberrypi/linux/blob/rpi-4.12.y/arch/arm64/kernel/setup.c for arm64).
Content of /proc/cpuinfo with the arm64 kernel:
What I expected (running on a 32-Bit arm kernel, serial removed):
Additional system information:
The text was updated successfully, but these errors were encountered: