Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
ccan
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
mirror
ccan
Commits
8b4ef38b
Commit
8b4ef38b
authored
Aug 11, 2015
by
A. Samy
Committed by
Rusty Russell
Aug 12, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cpuid: namespacize some functions and define them as null if unsupported
parent
7d7de521
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
5 deletions
+7
-5
ccan/cpuid/cpuid.h
ccan/cpuid/cpuid.h
+7
-5
No files found.
ccan/cpuid/cpuid.h
View file @
8b4ef38b
...
...
@@ -262,12 +262,12 @@ static char const *const c_cpunames[] = {
*/
cputype_t
cpuid_get_cpu_type
(
void
);
static
inline
bool
is_intel_cpu
(
void
)
static
inline
bool
cpuid_is_intel
(
void
)
{
return
cpuid_get_cpu_type
()
==
CT_INTEL
;
}
static
inline
bool
is_amd_cpu
(
void
)
static
inline
bool
cpuid_is_amd
(
void
)
{
return
cpuid_get_cpu_type
()
==
CT_AMDK5
||
cpuid_get_cpu_type
()
==
CT_AMD
;
}
...
...
@@ -364,7 +364,7 @@ uint32_t cpuid_highest_ext_func_supported(void);
* For CPUID_PROC_BRAND_STRING:
* Have a char array with at least 48 bytes assigned to it.
*
* If an invalid
flag
has been passed a 0xbaadf00d is returned in *buf.
* If an invalid
request
has been passed a 0xbaadf00d is returned in *buf.
*/
void
cpuid
(
cpuid_t
request
,
uint32_t
*
buf
);
...
...
@@ -428,10 +428,12 @@ bool cpuid_has_edxfeature_ext(int extfeature);
#include <ccan/build_assert/build_assert.h>
#define cpuid_get_cpu_type() BUILD_ASSERT_OR_ZERO(0)
#define cpuid_get_cpu_type_string() BUILD_ASSERT_OR_ZERO(0)
#define cpuid_is_intel() BUILD_ASSERT_OR_ZERO(0)
#define cpuid_is_amd() BUILD_ASSERT_OR_ZERO(0)
#define cpuid_get_name() BUILD_ASSERT_OR_ZERO(0)
#define cpuid_is_supported() BUILD_ASSERT_OR_ZERO(0)
#define cpuid(
info
, buf) BUILD_ASSERT_OR_ZERO(0)
#define cpuid(
request
, buf) BUILD_ASSERT_OR_ZERO(0)
#define cpuid_write_info(info, featureset, outfile) BUILD_ASSERT_OR_ZERO(0)
#define cpuid_highest_ext_func_supported() BUILD_ASSERT_OR_ZERO(0)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment