Skip to content

Commit 7b5dc58

Browse files
authored
CPU (Linux): fix CPU detection on some PPC platforms (#1640)
On some PowerPC devices (notably the Nintendo Wii and Nintendo Wii U), fastfetch detects the CPU incorrectly. It goes down the code path of 'detectSocName()', and actually matches the model of the device itself... as the CPU model name. This is obviously incorrect, and leads to reporting such as 'CPU: wii'. Disable this code path alltogether on PPC to prevent this, and just let it pull from cpuinfo. This lets it have correct CPU reporting, such as on the Wii, giving 'CPU: 750CL @ 0.73GHz'.
1 parent 8681d2f commit 7b5dc58

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/detection/cpu/cpu_linux.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -608,7 +608,7 @@ FF_MAYBE_UNUSED static const char* detectCPUOthers(const FFCPUOptions* options,
608608

609609
#if __ANDROID__
610610
detectAndroid(cpu);
611-
#else
611+
#elif !__powerpc__ && !__powerpc
612612
detectSocName(cpu);
613613
#endif
614614

0 commit comments

Comments
 (0)