summaryrefslogtreecommitdiff
path: root/Documentation/prctl/disable-tsc-test.c
diff options
context:
space:
mode:
authorPeter Foley <pefoley2@pefoley.com>2014-09-25 11:23:15 -0700
committerJiri Kosina <jkosina@suse.cz>2014-09-26 11:02:56 +0200
commit0421fc837c822e86c76884a30a9155e512a5a66a (patch)
treedbe95a10a0705f5caf3e7b85bcbed2709f663138 /Documentation/prctl/disable-tsc-test.c
parentadb19fb66eeebac07fe37d968725bb8906dadb8e (diff)
Documentation: make functions static to avoid prototype warnings
Signed-off-by: Peter Foley <pefoley2@pefoley.com> Signed-off-by: Randy Dunlap <rdunlap@infradead.org> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'Documentation/prctl/disable-tsc-test.c')
-rw-r--r--Documentation/prctl/disable-tsc-test.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/Documentation/prctl/disable-tsc-test.c b/Documentation/prctl/disable-tsc-test.c
index 843c81eac235..2541e65cb64b 100644
--- a/Documentation/prctl/disable-tsc-test.c
+++ b/Documentation/prctl/disable-tsc-test.c
@@ -29,14 +29,15 @@ const char *tsc_names[] =
[PR_TSC_SIGSEGV] = "PR_TSC_SIGSEGV",
};
-uint64_t rdtsc() {
+static uint64_t rdtsc(void)
+{
uint32_t lo, hi;
/* We cannot use "=A", since this would use %rax on x86_64 */
__asm__ __volatile__ ("rdtsc" : "=a" (lo), "=d" (hi));
return (uint64_t)hi << 32 | lo;
}
-void sigsegv_cb(int sig)
+static void sigsegv_cb(int sig)
{
int tsc_val = 0;