visemul.c (ec208491936d6adb8a70c3dd4a517cdfe54e823d) | visemul.c (121dd5f2776522e03970916514b46e355480e538) |
---|---|
1/* visemul.c: Emulation of VIS instructions. 2 * 3 * Copyright (C) 2006 David S. Miller (davem@davemloft.net) 4 */ 5#include <linux/kernel.h> 6#include <linux/errno.h> 7#include <linux/thread_info.h> | 1/* visemul.c: Emulation of VIS instructions. 2 * 3 * Copyright (C) 2006 David S. Miller (davem@davemloft.net) 4 */ 5#include <linux/kernel.h> 6#include <linux/errno.h> 7#include <linux/thread_info.h> |
8#include <linux/perf_event.h> |
|
8 9#include <asm/ptrace.h> 10#include <asm/pstate.h> 11#include <asm/system.h> 12#include <asm/fpumacro.h> 13#include <asm/uaccess.h> 14 15/* OPF field of various VIS instructions. */ --- 780 unchanged lines hidden (view full) --- 796 */ 797int vis_emul(struct pt_regs *regs, unsigned int insn) 798{ 799 unsigned long pc = regs->tpc; 800 unsigned int opf; 801 802 BUG_ON(regs->tstate & TSTATE_PRIV); 803 | 9 10#include <asm/ptrace.h> 11#include <asm/pstate.h> 12#include <asm/system.h> 13#include <asm/fpumacro.h> 14#include <asm/uaccess.h> 15 16/* OPF field of various VIS instructions. */ --- 780 unchanged lines hidden (view full) --- 797 */ 798int vis_emul(struct pt_regs *regs, unsigned int insn) 799{ 800 unsigned long pc = regs->tpc; 801 unsigned int opf; 802 803 BUG_ON(regs->tstate & TSTATE_PRIV); 804 |
805 perf_sw_event(PERF_COUNT_SW_EMULATION_FAULTS, 1, 0, regs, 0); 806 |
|
804 if (test_thread_flag(TIF_32BIT)) 805 pc = (u32)pc; 806 807 if (get_user(insn, (u32 __user *) pc)) 808 return -EFAULT; 809 810 save_and_clear_fpu(); 811 --- 79 unchanged lines hidden --- | 807 if (test_thread_flag(TIF_32BIT)) 808 pc = (u32)pc; 809 810 if (get_user(insn, (u32 __user *) pc)) 811 return -EFAULT; 812 813 save_and_clear_fpu(); 814 --- 79 unchanged lines hidden --- |