summaryrefslogtreecommitdiffstats
path: root/sys/dev
diff options
context:
space:
mode:
authorglebius <glebius@FreeBSD.org>2016-02-17 21:13:33 +0000
committerglebius <glebius@FreeBSD.org>2016-02-17 21:13:33 +0000
commita2c31fef2be2cbcc7bb6f4ac85ba4657f65242c6 (patch)
treedc4c94d39fa370ed0f1ba25bdcc8531229511009 /sys/dev
parent69771cc9af7117bb790bdc06580e91e8a7492696 (diff)
downloadFreeBSD-src-a2c31fef2be2cbcc7bb6f4ac85ba4657f65242c6.zip
FreeBSD-src-a2c31fef2be2cbcc7bb6f4ac85ba4657f65242c6.tar.gz
Ternary operator has lower priority than OR.
Found by: PVS-Studio
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/ata/chipsets/ata-serverworks.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/sys/dev/ata/chipsets/ata-serverworks.c b/sys/dev/ata/chipsets/ata-serverworks.c
index 720727f..540534f 100644
--- a/sys/dev/ata/chipsets/ata-serverworks.c
+++ b/sys/dev/ata/chipsets/ata-serverworks.c
@@ -162,9 +162,8 @@ ata_serverworks_chipinit(device_t dev)
}
}
else {
- pci_write_config(dev, 0x5a,
- (pci_read_config(dev, 0x5a, 1) & ~0x40) |
- (ctlr->chip->cfg1 == SWKS_100) ? 0x03 : 0x02, 1);
+ pci_write_config(dev, 0x5a, (pci_read_config(dev, 0x5a, 1) & ~0x40) |
+ ((ctlr->chip->cfg1 == SWKS_100) ? 0x03 : 0x02), 1);
}
ctlr->setmode = ata_serverworks_setmode;
return 0;
OpenPOWER on IntegriCloud