hv: coding style clean-up related to Boolean

While following two styles are both correct, the 2nd one is simpler.
	bool is_level_triggered;
	1. if (is_level_triggered == true) {...}
	2. if (is_level_triggered) {...}

This patch cleans up the style in hypervisor.

Tracked-On: #861
Signed-off-by: Shiqing Gao <shiqing.gao@intel.com>
This commit is contained in:
Shiqing Gao
2020-11-27 09:58:57 +08:00
committed by wenlingz
parent 74203e39d9
commit 6f10bd00bf
6 changed files with 6 additions and 6 deletions

View File

@@ -295,7 +295,7 @@ void write_sriov_cap_reg(struct pci_vdev *vdev, uint32_t offset, uint32_t bytes,
if (reg == PCIR_SRIOV_CONTROL) {
bool enable;
enable = (((val & PCIM_SRIOV_VF_ENABLE) != 0U) ? true : false);
enable = ((val & PCIM_SRIOV_VF_ENABLE) != 0U);
if (enable != is_vf_enabled(vdev)) {
if (enable) {
/*