mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-12-27 13:30:45 -05:00
While the GCC and Clang compilers already define __ASSEMBLER__ automatically when compiling assembly code, __ASSEMBLY__ is a macro that only gets defined by the Makefiles in the kernel. This can be very confusing when switching between userspace and kernelspace coding, or when dealing with uapi headers that rather should use __ASSEMBLER__ instead. So let's standardize on the __ASSEMBLER__ macro that is provided by the compilers now. This is a completely mechanical patch (done with a simple "sed -i" statement). Cc: Michal Simek <monstr@monstr.eu> Signed-off-by: Thomas Huth <thuth@redhat.com> Link: https://lore.kernel.org/r/20250314071013.1575167-19-thuth@redhat.com Signed-off-by: Michal Simek <michal.simek@amd.com>
35 lines
1020 B
C
35 lines
1020 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
/*
|
|
* Definitions used by low-level trap handlers
|
|
*
|
|
* Copyright (C) 2008-2009 Michal Simek <monstr@monstr.eu>
|
|
* Copyright (C) 2007-2009 PetaLogix
|
|
* Copyright (C) 2007 John Williams <john.williams@petalogix.com>
|
|
*/
|
|
|
|
#ifndef _ASM_MICROBLAZE_ENTRY_H
|
|
#define _ASM_MICROBLAZE_ENTRY_H
|
|
|
|
#include <asm/percpu.h>
|
|
#include <asm/ptrace.h>
|
|
#include <linux/linkage.h>
|
|
|
|
/*
|
|
* These are per-cpu variables required in entry.S, among other
|
|
* places
|
|
*/
|
|
|
|
#define PER_CPU(var) var
|
|
|
|
# ifndef __ASSEMBLER__
|
|
DECLARE_PER_CPU(unsigned int, KSP); /* Saved kernel stack pointer */
|
|
DECLARE_PER_CPU(unsigned int, KM); /* Kernel/user mode */
|
|
DECLARE_PER_CPU(unsigned int, ENTRY_SP); /* Saved SP on kernel entry */
|
|
DECLARE_PER_CPU(unsigned int, R11_SAVE); /* Temp variable for entry */
|
|
DECLARE_PER_CPU(unsigned int, CURRENT_SAVE); /* Saved current pointer */
|
|
|
|
extern asmlinkage void do_notify_resume(struct pt_regs *regs, int in_syscall);
|
|
# endif /* __ASSEMBLER__ */
|
|
|
|
#endif /* _ASM_MICROBLAZE_ENTRY_H */
|