[Intel-gfx] [PATCH v3 2/3] x86/quirks: Improve line wrap on quirk conditions
Lucas De Marchi
lucas.demarchi at intel.com
Fri Jan 7 21:05:15 UTC 2022
Remove extra parenthesis and wrap lines so it's easier to read what are
the conditions being checked. The call to the hook also had an extra
indentation: remove here to conform to coding style.
Signed-off-by: Lucas De Marchi <lucas.demarchi at intel.com>
---
arch/x86/kernel/early-quirks.c | 14 ++++++--------
1 file changed, 6 insertions(+), 8 deletions(-)
diff --git a/arch/x86/kernel/early-quirks.c b/arch/x86/kernel/early-quirks.c
index 8b689c2b8cc7..df34963e23bf 100644
--- a/arch/x86/kernel/early-quirks.c
+++ b/arch/x86/kernel/early-quirks.c
@@ -767,14 +767,12 @@ static int __init check_dev_quirk(int num, int slot, int func)
device = read_pci_config_16(num, slot, func, PCI_DEVICE_ID);
for (i = 0; early_qrk[i].f != NULL; i++) {
- if (((early_qrk[i].vendor == PCI_ANY_ID) ||
- (early_qrk[i].vendor == vendor)) &&
- ((early_qrk[i].device == PCI_ANY_ID) ||
- (early_qrk[i].device == device)) &&
- (!((early_qrk[i].class ^ class) &
- early_qrk[i].class_mask)))
- early_qrk[i].f(num, slot, func);
-
+ if ((early_qrk[i].vendor == PCI_ANY_ID ||
+ early_qrk[i].vendor == vendor) &&
+ (early_qrk[i].device == PCI_ANY_ID ||
+ early_qrk[i].device == device) &&
+ !((early_qrk[i].class ^ class) & early_qrk[i].class_mask))
+ early_qrk[i].f(num, slot, func);
}
type = read_pci_config_byte(num, slot, func,
--
2.34.1
More information about the Intel-gfx
mailing list