hv: treewide: fix 'Switch empty default has no comment'

This patch add some comments after the default and before the break
in the switch statement based on MISRA-C requirement.

Signed-off-by: Shiqing Gao <shiqing.gao@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
This commit is contained in:
Shiqing Gao
2018-08-08 10:32:09 +08:00
committed by lijinxia
parent af7943c5e6
commit 4106fadeb3
8 changed files with 97 additions and 0 deletions

View File

@@ -87,6 +87,11 @@ handle_vpic_irqline(struct vm *vm, uint32_t irq, enum irq_mode mode)
case IRQ_PULSE:
ret = vpic_pulse_irq(vm, irq);
default:
/*
* In this switch statement, mode shall either be IRQ_ASSERT or
* IRQ_DEASSERT or IRQ_PULSE.
* Gracefully return if prior case clauses have not been met.
*/
break;
}
@@ -113,6 +118,11 @@ handle_vioapic_irqline(struct vm *vm, uint32_t irq, enum irq_mode mode)
ret = vioapic_pulse_irq(vm, irq);
break;
default:
/*
* In this switch statement, mode shall either be IRQ_ASSERT or
* IRQ_DEASSERT or IRQ_PULSE.
* Gracefully return if prior case clauses have not been met.
*/
break;
}
return ret;