mirror of
https://github.com/google/cpu_features.git
synced 2025-07-02 05:33:17 +02:00
powerpc: Add AT_PLATFORM and AT_BASE_PLATFORM
Some PowerPC machines can operate in a mode that appears different to a process than the actual hardware. AT_PLATFORM indicates the supported instruction set and AT_BASE_PLATFORM indicates the actual microarchitecture of the hardware. Signed-off-by: Rashmica Gupta <rashmica.gupta@au1.ibm.com>
This commit is contained in:

committed by
Rashmica Gupta

parent
1c8bf0ecd8
commit
c45e32f812
@ -16,6 +16,7 @@
|
||||
#define CPU_FEATURES_INCLUDE_CPUINFO_PPC_H_
|
||||
|
||||
#include "cpu_features_macros.h"
|
||||
#include "internal/hwcaps.h"
|
||||
|
||||
CPU_FEATURES_START_CPP_NAMESPACE
|
||||
|
||||
@ -77,6 +78,7 @@ typedef struct {
|
||||
char model[64]; // 0 terminated string
|
||||
char machine[64]; // 0 terminated string
|
||||
char cpu[64]; // 0 terminated string
|
||||
PlatformType type;
|
||||
} PPCPlatformStrings;
|
||||
|
||||
PPCPlatformStrings GetPPCPlatformStrings(void);
|
||||
|
@ -119,6 +119,13 @@ typedef struct {
|
||||
|
||||
HardwareCapabilities CpuFeatures_GetHardwareCapabilities(void);
|
||||
|
||||
typedef struct {
|
||||
char platform[64]; // 0 terminated string
|
||||
char base_platform[64]; // 0 terminated string
|
||||
} PlatformType;
|
||||
|
||||
PlatformType CpuFeatures_GetPlatformType(void);
|
||||
|
||||
CPU_FEATURES_END_CPP_NAMESPACE
|
||||
|
||||
#endif // CPU_FEATURES_INCLUDE_INTERNAL_HWCAPS_H_
|
||||
|
Reference in New Issue
Block a user