Allow a PVH dom0 access to all PHYSDEVOP_* ops.
Signed-off-by: Mukesh Rathor <mukesh.rathor@oracle.com>
Convert flow and adjust indentation.
Signed-off-by: Jan Beulich <jbeulich@suse.com>
{
switch ( cmd )
{
- case PHYSDEVOP_map_pirq:
- case PHYSDEVOP_unmap_pirq:
- case PHYSDEVOP_eoi:
- case PHYSDEVOP_irq_status_query:
- case PHYSDEVOP_get_free_pirq:
- return do_physdev_op(cmd, arg);
- default:
+ default:
+ if ( !is_pvh_vcpu(current) || !is_hardware_domain(current->domain) )
return -ENOSYS;
+ /* fall through */
+ case PHYSDEVOP_map_pirq:
+ case PHYSDEVOP_unmap_pirq:
+ case PHYSDEVOP_eoi:
+ case PHYSDEVOP_irq_status_query:
+ case PHYSDEVOP_get_free_pirq:
+ return do_physdev_op(cmd, arg);
}
}