linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: tip-bot for Andi Kleen <tipbot@zytor.com>
To: linux-tip-commits@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, hpa@zytor.com, mingo@kernel.org,
	ak@linux.intel.com, tglx@linutronix.de, hpa@linux.intel.com
Subject: [tip:x86/asmlinkage] x86, asmlinkage: Make several variables used from assembler/linker script visible
Date: Tue, 6 Aug 2013 14:43:52 -0700	[thread overview]
Message-ID: <tip-277d5b40b7bf495d2d4193746181b17dd98441b2@git.kernel.org> (raw)
In-Reply-To: <1375740170-7446-10-git-send-email-andi@firstfloor.org>

Commit-ID:  277d5b40b7bf495d2d4193746181b17dd98441b2
Gitweb:     http://git.kernel.org/tip/277d5b40b7bf495d2d4193746181b17dd98441b2
Author:     Andi Kleen <ak@linux.intel.com>
AuthorDate: Mon, 5 Aug 2013 15:02:43 -0700
Committer:  H. Peter Anvin <hpa@linux.intel.com>
CommitDate: Tue, 6 Aug 2013 14:20:13 -0700

x86, asmlinkage: Make several variables used from assembler/linker script visible

Plus one function, load_gs_index().

Signed-off-by: Andi Kleen <ak@linux.intel.com>
Link: http://lkml.kernel.org/r/1375740170-7446-10-git-send-email-andi@firstfloor.org
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
---
 arch/x86/include/asm/pgtable.h       | 3 ++-
 arch/x86/include/asm/processor.h     | 2 +-
 arch/x86/include/asm/special_insns.h | 2 +-
 arch/x86/kernel/cpu/amd.c            | 4 ++--
 arch/x86/kernel/cpu/common.c         | 4 ++--
 arch/x86/kernel/process.c            | 2 +-
 arch/x86/kernel/process_64.c         | 2 +-
 arch/x86/kernel/setup.c              | 4 ++--
 arch/x86/kernel/signal.c             | 2 +-
 arch/x86/lib/usercopy_64.c           | 2 +-
 10 files changed, 14 insertions(+), 13 deletions(-)

diff --git a/arch/x86/include/asm/pgtable.h b/arch/x86/include/asm/pgtable.h
index 7dc305a..4e47659 100644
--- a/arch/x86/include/asm/pgtable.h
+++ b/arch/x86/include/asm/pgtable.h
@@ -22,7 +22,8 @@
  * ZERO_PAGE is a global shared page that is always zero: used
  * for zero-mapped memory areas etc..
  */
-extern unsigned long empty_zero_page[PAGE_SIZE / sizeof(unsigned long)];
+extern unsigned long empty_zero_page[PAGE_SIZE / sizeof(unsigned long)]
+	__visible;
 #define ZERO_PAGE(vaddr) (virt_to_page(empty_zero_page))
 
 extern spinlock_t pgd_lock;
diff --git a/arch/x86/include/asm/processor.h b/arch/x86/include/asm/processor.h
index 24cf5ae..573c1ad 100644
--- a/arch/x86/include/asm/processor.h
+++ b/arch/x86/include/asm/processor.h
@@ -412,7 +412,7 @@ union irq_stack_union {
 	};
 };
 
-DECLARE_PER_CPU_FIRST(union irq_stack_union, irq_stack_union);
+DECLARE_PER_CPU_FIRST(union irq_stack_union, irq_stack_union) __visible;
 DECLARE_INIT_PER_CPU(irq_stack_union);
 
 DECLARE_PER_CPU(char *, irq_stack_ptr);
diff --git a/arch/x86/include/asm/special_insns.h b/arch/x86/include/asm/special_insns.h
index 2f4d924..645cad2 100644
--- a/arch/x86/include/asm/special_insns.h
+++ b/arch/x86/include/asm/special_insns.h
@@ -101,7 +101,7 @@ static inline void native_wbinvd(void)
 	asm volatile("wbinvd": : :"memory");
 }
 
-extern void native_load_gs_index(unsigned);
+extern asmlinkage void native_load_gs_index(unsigned);
 
 #ifdef CONFIG_PARAVIRT
 #include <asm/paravirt.h>
diff --git a/arch/x86/kernel/cpu/amd.c b/arch/x86/kernel/cpu/amd.c
index f654ece..466e3d1 100644
--- a/arch/x86/kernel/cpu/amd.c
+++ b/arch/x86/kernel/cpu/amd.c
@@ -66,8 +66,8 @@ static inline int wrmsrl_amd_safe(unsigned msr, unsigned long long val)
  *	performance at the same time..
  */
 
-extern void vide(void);
-__asm__(".align 4\nvide: ret");
+extern __visible void vide(void);
+__asm__(".globl vide\n\t.align 4\nvide: ret");
 
 static void init_amd_k5(struct cpuinfo_x86 *c)
 {
diff --git a/arch/x86/kernel/cpu/common.c b/arch/x86/kernel/cpu/common.c
index 25eb274..2793d1f 100644
--- a/arch/x86/kernel/cpu/common.c
+++ b/arch/x86/kernel/cpu/common.c
@@ -1076,7 +1076,7 @@ struct desc_ptr debug_idt_descr = { NR_VECTORS * 16 - 1,
 				    (unsigned long) debug_idt_table };
 
 DEFINE_PER_CPU_FIRST(union irq_stack_union,
-		     irq_stack_union) __aligned(PAGE_SIZE);
+		     irq_stack_union) __aligned(PAGE_SIZE) __visible;
 
 /*
  * The following four percpu variables are hot.  Align current_task to
@@ -1093,7 +1093,7 @@ EXPORT_PER_CPU_SYMBOL(kernel_stack);
 DEFINE_PER_CPU(char *, irq_stack_ptr) =
 	init_per_cpu_var(irq_stack_union.irq_stack) + IRQ_STACK_SIZE - 64;
 
-DEFINE_PER_CPU(unsigned int, irq_count) = -1;
+DEFINE_PER_CPU(unsigned int, irq_count) __visible = -1;
 
 DEFINE_PER_CPU(struct task_struct *, fpu_owner_task);
 
diff --git a/arch/x86/kernel/process.c b/arch/x86/kernel/process.c
index 83369e5..c83516b 100644
--- a/arch/x86/kernel/process.c
+++ b/arch/x86/kernel/process.c
@@ -36,7 +36,7 @@
  * section. Since TSS's are completely CPU-local, we want them
  * on exact cacheline boundaries, to eliminate cacheline ping-pong.
  */
-DEFINE_PER_CPU_SHARED_ALIGNED(struct tss_struct, init_tss) = INIT_TSS;
+__visible DEFINE_PER_CPU_SHARED_ALIGNED(struct tss_struct, init_tss) = INIT_TSS;
 
 #ifdef CONFIG_X86_64
 static DEFINE_PER_CPU(unsigned char, is_idle);
diff --git a/arch/x86/kernel/process_64.c b/arch/x86/kernel/process_64.c
index 6e8c1d0..bb1dc51 100644
--- a/arch/x86/kernel/process_64.c
+++ b/arch/x86/kernel/process_64.c
@@ -52,7 +52,7 @@
 
 asmlinkage extern void ret_from_fork(void);
 
-DEFINE_PER_CPU(unsigned long, old_rsp);
+asmlinkage DEFINE_PER_CPU(unsigned long, old_rsp);
 
 /* Prints also some state that isn't saved in the pt_regs */
 void __show_regs(struct pt_regs *regs, int all)
diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c
index f8ec578..dfa55af 100644
--- a/arch/x86/kernel/setup.c
+++ b/arch/x86/kernel/setup.c
@@ -206,9 +206,9 @@ EXPORT_SYMBOL(boot_cpu_data);
 
 
 #if !defined(CONFIG_X86_PAE) || defined(CONFIG_X86_64)
-unsigned long mmu_cr4_features;
+__visible unsigned long mmu_cr4_features;
 #else
-unsigned long mmu_cr4_features = X86_CR4_PAE;
+__visible unsigned long mmu_cr4_features = X86_CR4_PAE;
 #endif
 
 /* Boot loader ID and version as integers, for the benefit of proc_dointvec */
diff --git a/arch/x86/kernel/signal.c b/arch/x86/kernel/signal.c
index 1dba45d..6a9acc6 100644
--- a/arch/x86/kernel/signal.c
+++ b/arch/x86/kernel/signal.c
@@ -728,7 +728,7 @@ static void do_signal(struct pt_regs *regs)
  * notification of userspace execution resumption
  * - triggered by the TIF_WORK_MASK flags
  */
-void
+__visible void
 do_notify_resume(struct pt_regs *regs, void *unused, __u32 thread_info_flags)
 {
 	user_exit();
diff --git a/arch/x86/lib/usercopy_64.c b/arch/x86/lib/usercopy_64.c
index 906fea3..c905e89 100644
--- a/arch/x86/lib/usercopy_64.c
+++ b/arch/x86/lib/usercopy_64.c
@@ -68,7 +68,7 @@ EXPORT_SYMBOL(copy_in_user);
  * Since protection fault in copy_from/to_user is not a normal situation,
  * it is not necessary to optimize tail handling.
  */
-unsigned long
+__visible unsigned long
 copy_user_handle_tail(char *to, char *from, unsigned len, unsigned zerorest)
 {
 	char c;

  reply	other threads:[~2013-08-06 21:44 UTC|newest]

Thread overview: 37+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-05 22:02 x86: Clean up asmlinkage use Andi Kleen
2013-08-05 22:02 ` [PATCH 01/16] x86: Fix sys_call_table type in asm/syscall.h v2 Andi Kleen
2013-08-06 21:42   ` [tip:x86/asmlinkage] x86: Fix sys_call_table type in asm/ syscall.h tip-bot for Andi Kleen
2013-08-05 22:02 ` [PATCH 02/16] x86, asmlinkage: Change dotraplinkage into __visible on 32bit v2 Andi Kleen
2013-08-06 21:42   ` [tip:x86/asmlinkage] x86, asmlinkage: Change dotraplinkage into __visible on 32bit tip-bot for Andi Kleen
2013-08-05 22:02 ` [PATCH 03/16] x86, asmlinkage: Make all interrupt handlers asmlinkage / __visible Andi Kleen
2013-08-06 21:07   ` H. Peter Anvin
2013-08-06 21:24     ` H. Peter Anvin
2013-08-06 21:43   ` [tip:x86/asmlinkage] " tip-bot for Andi Kleen
2013-08-05 22:02 ` [PATCH 04/16] x86, asmlinkage: Make _*_start_kernel visible Andi Kleen
2013-08-06 21:43   ` [tip:x86/asmlinkage] " tip-bot for Andi Kleen
2013-08-05 22:02 ` [PATCH 05/16] x86, asmlinkage: Make 32bit/64bit __switch_to visible Andi Kleen
2013-08-06 21:43   ` [tip:x86/asmlinkage] x86, asmlinkage: Make 32bit/ 64bit " tip-bot for Andi Kleen
2013-08-05 22:02 ` [PATCH 06/16] x86, asmlinkage: Make various syscalls asmlinkage Andi Kleen
2013-08-06 21:43   ` [tip:x86/asmlinkage] " tip-bot for Andi Kleen
2013-08-05 22:02 ` [PATCH 07/16] x86, asmlinkage: Make kprobes code visible and fix assembler code Andi Kleen
2013-08-06 21:43   ` [tip:x86/asmlinkage] " tip-bot for Andi Kleen
2013-08-07  3:55     ` Masami Hiramatsu
2013-08-05 22:02 ` [PATCH 08/16] x86, asmlinkage, kexec: Drop bogus asmlinkage in machine_kexec_32 Andi Kleen
2013-08-05 23:03   ` H. Peter Anvin
2013-08-05 23:10     ` Andi Kleen
2013-08-05 22:02 ` [PATCH 09/16] x86, asmlinkage: Make several variables used from assembler/linker script visible Andi Kleen
2013-08-06 21:43   ` tip-bot for Andi Kleen [this message]
2013-08-05 22:02 ` [PATCH 10/16] x86, asmlinkage: Make syscall tables visible Andi Kleen
2013-08-06 21:44   ` [tip:x86/asmlinkage] " tip-bot for Andi Kleen
2013-08-05 22:02 ` [PATCH 11/16] x86, asmlinkage, apm: Make APM data structure used from assembler visible Andi Kleen
2013-08-06 21:44   ` [tip:x86/asmlinkage] " tip-bot for Andi Kleen
2013-08-05 22:02 ` [PATCH 12/16] x86, asmlinkage, paravirt: Add __visible/asmlinkage to xen paravirt ops Andi Kleen
2013-08-06 21:44   ` [tip:x86/asmlinkage] x86, asmlinkage, paravirt: Add __visible/ asmlinkage " tip-bot for Andi Kleen
2013-08-05 22:02 ` [PATCH 13/16] x86, asmlinkage: Make 64bit checksum functions visible Andi Kleen
2013-08-06 21:44   ` [tip:x86/asmlinkage] " tip-bot for Andi Kleen
2013-08-05 22:02 ` [PATCH 14/16] x86, asmlinkage: Make dump_stack visible Andi Kleen
2013-08-06 21:44   ` [tip:x86/asmlinkage] " tip-bot for Andi Kleen
2013-08-05 22:02 ` [PATCH 15/16] x86, asmlinkage, power: Make various symbols used by the suspend asm code visible Andi Kleen
2013-08-06 21:44   ` [tip:x86/asmlinkage] " tip-bot for Andi Kleen
2013-08-05 22:02 ` [PATCH 16/16] x86, asmlinkage, vdso: Mark vdso variables __visible Andi Kleen
2013-08-06 21:45   ` [tip:x86/asmlinkage] " tip-bot for Andi Kleen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=tip-277d5b40b7bf495d2d4193746181b17dd98441b2@git.kernel.org \
    --to=tipbot@zytor.com \
    --cc=ak@linux.intel.com \
    --cc=hpa@linux.intel.com \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tip-commits@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=tglx@linutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).