HV:pic fix "Recursion in procedure calls found"

Functions shall not call themselves, either directly or indirectly.

vpic_set_pinstate will cal vpic_notify_intr and results to recursion
violations,fix it out by mov vpic_notify_intr out of vpic_set_pinstate.

Tracked-On: #861
Signed-off-by: Huihuang Shi <huihuang.shi@intel.com>
reviewed-by: Junjie Mao <junjie.mao@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
This commit is contained in:
Huihuang Shi 2018-11-07 17:41:14 +08:00 committed by wenlingz
parent 0a9d6841f7
commit 7e6d0a2176

View File

@ -434,8 +434,6 @@ static void vpic_set_pinstate(struct acrn_vpic *vpic, uint8_t pin,
dev_dbg(ACRN_DBG_PIC, "pic pin%hhu: %s, ignored\n",
pin, (level != 0U) ? "asserted" : "deasserted");
}
vpic_notify_intr(vpic);
}
/**
@ -488,6 +486,7 @@ void vpic_set_irq(struct acrn_vm *vm, uint32_t irq, uint32_t operation)
*/
break;
}
vpic_notify_intr(vpic);
spinlock_release(&(vpic->lock));
}