xref: /kernel/linux/linux-5.10/arch/mips/include/asm/irq_regs.h
  • Home
  • History
  • Annotate Annotate
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
  • only in /kernel/linux/linux-5.10/arch/mips/include/asm/
18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0-or-later */
28c2ecf20Sopenharmony_ci/*
38c2ecf20Sopenharmony_ci *
48c2ecf20Sopenharmony_ci * Copyright (C) 2006 Ralf Baechle (ralf@linux-mips.org)
58c2ecf20Sopenharmony_ci */
68c2ecf20Sopenharmony_ci#ifndef __ASM_IRQ_REGS_H
78c2ecf20Sopenharmony_ci#define __ASM_IRQ_REGS_H
88c2ecf20Sopenharmony_ci
98c2ecf20Sopenharmony_ci#define ARCH_HAS_OWN_IRQ_REGS
108c2ecf20Sopenharmony_ci
118c2ecf20Sopenharmony_ci#include <linux/thread_info.h>
128c2ecf20Sopenharmony_ci
138c2ecf20Sopenharmony_cistatic inline struct pt_regs *get_irq_regs(void)
148c2ecf20Sopenharmony_ci{
158c2ecf20Sopenharmony_ci	return current_thread_info()->regs;
168c2ecf20Sopenharmony_ci}
178c2ecf20Sopenharmony_ci
188c2ecf20Sopenharmony_cistatic inline struct pt_regs *set_irq_regs(struct pt_regs *new_regs)
198c2ecf20Sopenharmony_ci{
208c2ecf20Sopenharmony_ci	struct pt_regs *old_regs;
218c2ecf20Sopenharmony_ci
228c2ecf20Sopenharmony_ci	old_regs = get_irq_regs();
238c2ecf20Sopenharmony_ci	current_thread_info()->regs = new_regs;
248c2ecf20Sopenharmony_ci
258c2ecf20Sopenharmony_ci	return old_regs;
268c2ecf20Sopenharmony_ci}
278c2ecf20Sopenharmony_ci
288c2ecf20Sopenharmony_ci#endif /* __ASM_IRQ_REGS_H */
29

Indexes created Thu Nov 07 10:32:03 CST 2024