Release 4.14 arch/microblaze/include/asm/irqflags.h
/*
* Copyright (C) 2006 Atmark Techno, Inc.
*
* This file is subject to the terms and conditions of the GNU General Public
* License. See the file "COPYING" in the main directory of this archive
* for more details.
*/
#ifndef _ASM_MICROBLAZE_IRQFLAGS_H
#define _ASM_MICROBLAZE_IRQFLAGS_H
#include <linux/types.h>
#include <asm/registers.h>
#if CONFIG_XILINX_MICROBLAZE0_USE_MSR_INSTR
static inline notrace unsigned long arch_local_irq_save(void)
{
unsigned long flags;
asm volatile(" msrclr %0, %1 \n"
" nop \n"
: "=r"(flags)
: "i"(MSR_IE)
: "memory");
return flags;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
David Howells | 18 | 85.71% | 1 | 33.33% |
Michal Simek | 2 | 9.52% | 1 | 33.33% |
Steven Rostedt | 1 | 4.76% | 1 | 33.33% |
Total | 21 | 100.00% | 3 | 100.00% |
static inline notrace void arch_local_irq_disable(void)
{
/* this uses r0 without declaring it - is that correct? */
asm volatile(" msrclr r0, %0 \n"
" nop \n"
:
: "i"(MSR_IE)
: "memory");
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
David Howells | 13 | 92.86% | 1 | 50.00% |
Steven Rostedt | 1 | 7.14% | 1 | 50.00% |
Total | 14 | 100.00% | 2 | 100.00% |
static inline notrace void arch_local_irq_enable(void)
{
/* this uses r0 without declaring it - is that correct? */
asm volatile(" msrset r0, %0 \n"
" nop \n"
:
: "i"(MSR_IE)
: "memory");
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
David Howells | 13 | 92.86% | 1 | 50.00% |
Steven Rostedt | 1 | 7.14% | 1 | 50.00% |
Total | 14 | 100.00% | 2 | 100.00% |
#else /* !CONFIG_XILINX_MICROBLAZE0_USE_MSR_INSTR */
static inline notrace unsigned long arch_local_irq_save(void)
{
unsigned long flags, tmp;
asm volatile (" mfs %0, rmsr \n"
" nop \n"
" andi %1, %0, %2 \n"
" mts rmsr, %1 \n"
" nop \n"
: "=r"(flags), "=r"(tmp)
: "i"(~MSR_IE)
: "memory");
return flags;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
David Howells | 20 | 86.96% | 1 | 33.33% |
Michal Simek | 2 | 8.70% | 1 | 33.33% |
Steven Rostedt | 1 | 4.35% | 1 | 33.33% |
Total | 23 | 100.00% | 3 | 100.00% |
static inline notrace void arch_local_irq_disable(void)
{
unsigned long tmp;
asm volatile(" mfs %0, rmsr \n"
" nop \n"
" andi %0, %0, %1 \n"
" mts rmsr, %0 \n"
" nop \n"
: "=r"(tmp)
: "i"(~MSR_IE)
: "memory");
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
David Howells | 16 | 94.12% | 1 | 50.00% |
Steven Rostedt | 1 | 5.88% | 1 | 50.00% |
Total | 17 | 100.00% | 2 | 100.00% |
static inline notrace void arch_local_irq_enable(void)
{
unsigned long tmp;
asm volatile(" mfs %0, rmsr \n"
" nop \n"
" ori %0, %0, %1 \n"
" mts rmsr, %0 \n"
" nop \n"
: "=r"(tmp)
: "i"(MSR_IE)
: "memory");
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
David Howells | 16 | 94.12% | 1 | 50.00% |
Steven Rostedt | 1 | 5.88% | 1 | 50.00% |
Total | 17 | 100.00% | 2 | 100.00% |
#endif /* CONFIG_XILINX_MICROBLAZE0_USE_MSR_INSTR */
static inline notrace unsigned long arch_local_save_flags(void)
{
unsigned long flags;
asm volatile(" mfs %0, rmsr \n"
" nop \n"
: "=r"(flags)
:
: "memory");
return flags;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
Michal Simek | 18 | 85.71% | 2 | 50.00% |
David Howells | 2 | 9.52% | 1 | 25.00% |
Steven Rostedt | 1 | 4.76% | 1 | 25.00% |
Total | 21 | 100.00% | 4 | 100.00% |
static inline notrace void arch_local_irq_restore(unsigned long flags)
{
asm volatile(" mts rmsr, %0 \n"
" nop \n"
:
: "r"(flags)
: "memory");
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
David Howells | 11 | 73.33% | 1 | 33.33% |
Michal Simek | 3 | 20.00% | 1 | 33.33% |
Steven Rostedt | 1 | 6.67% | 1 | 33.33% |
Total | 15 | 100.00% | 3 | 100.00% |
static inline notrace bool arch_irqs_disabled_flags(unsigned long flags)
{
return (flags & MSR_IE) == 0;
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
David Howells | 17 | 80.95% | 1 | 33.33% |
Michal Simek | 3 | 14.29% | 1 | 33.33% |
Steven Rostedt | 1 | 4.76% | 1 | 33.33% |
Total | 21 | 100.00% | 3 | 100.00% |
static inline notrace bool arch_irqs_disabled(void)
{
return arch_irqs_disabled_flags(arch_local_save_flags());
}
Contributors
Person | Tokens | Prop | Commits | CommitProp |
David Howells | 16 | 94.12% | 1 | 50.00% |
Steven Rostedt | 1 | 5.88% | 1 | 50.00% |
Total | 17 | 100.00% | 2 | 100.00% |
#endif /* _ASM_MICROBLAZE_IRQFLAGS_H */
Overall Contributors
Person | Tokens | Prop | Commits | CommitProp |
David Howells | 144 | 70.24% | 1 | 20.00% |
Michal Simek | 51 | 24.88% | 3 | 60.00% |
Steven Rostedt | 10 | 4.88% | 1 | 20.00% |
Total | 205 | 100.00% | 5 | 100.00% |
Information contained on this website is for historical information purposes only and does not indicate or represent copyright ownership.