asmlinkage void noinstr el1_sync_handler(struct pt_regs *regs)
{
unsigned long esr = read_sysreg(esr_el1);//esr_el1是异常状态寄存器
//#define ESR_ELx_EC(esr) (((esr) & ESR_ELx_EC_MASK) >> ESR_ELx_EC_SHIFT)
//#define ESR_ELx_EC_SHIFT (26)
//#define ESR_ELx_EC_MASK (UL(0x3F) << ESR_ELx_EC_SHIFT)
switch (ESR_ELx_EC(esr)) {//取esr的[26,31]位,这个寄存器的[26,31]位代表异常类。
case ESR_ELx_EC_DABT_CUR://当前异常等级的数据异常
case ESR_ELx_EC_IABT_CUR://当前异常等级的指令异常
el1_abort(regs, esr);
break;
/*
* We don't handle ESR_ELx_EC_SP_ALIGN, since we will have hit a
* recursive exception when trying to push the initial pt_regs.