PCI: Simplify bool comparisons

Take care about Coccinelle warnings:

  drivers/pci/pci.c:6008:6-12: WARNING: Comparison to bool
  drivers/pci/pci.c:6024:7-13: WARNING: Comparison to bool

No change to functionality intended.

Link: https://lore.kernel.org/r/20200925224555.1752460-1-kw@linux.com
Signed-off-by: Krzysztof Wilczyński <kw@linux.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
This commit is contained in:
Krzysztof Wilczyński 2020-09-25 22:45:55 +00:00 коммит произвёл Bjorn Helgaas
Родитель 32b313ce9d
Коммит 0a98bb98f2
1 изменённых файлов: 2 добавлений и 2 удалений

Просмотреть файл

@ -5996,7 +5996,7 @@ int pci_set_vga_state(struct pci_dev *dev, bool decode,
if (flags & PCI_VGA_STATE_CHANGE_DECODES) {
pci_read_config_word(dev, PCI_COMMAND, &cmd);
if (decode == true)
if (decode)
cmd |= command_bits;
else
cmd &= ~command_bits;
@ -6012,7 +6012,7 @@ int pci_set_vga_state(struct pci_dev *dev, bool decode,
if (bridge) {
pci_read_config_word(bridge, PCI_BRIDGE_CONTROL,
&cmd);
if (decode == true)
if (decode)
cmd |= PCI_BRIDGE_CTL_VGA;
else
cmd &= ~PCI_BRIDGE_CTL_VGA;