Make struct pci_vpd_pci22.busy a 1-bit field instead of a bool. We intend
to add another flag, and two bitfields are cheaper than two bools.
Tested-by: Shane Seymour <shane.seymour@hpe.com>
Tested-by: Babu Moger <babu.moger@oracle.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Hannes Reinecke <hare@suse.com>
struct pci_vpd base;
struct mutex lock;
u16 flag;
- bool busy;
u8 cap;
+ u8 busy:1;
};
/*
return ret;
if ((status & PCI_VPD_ADDR_F) == vpd->flag) {
- vpd->busy = false;
+ vpd->busy = 0;
return 0;
}
pos & ~3);
if (ret < 0)
break;
- vpd->busy = true;
+ vpd->busy = 1;
vpd->flag = PCI_VPD_ADDR_F;
ret = pci_vpd_pci22_wait(dev);
if (ret < 0)
if (ret < 0)
break;
- vpd->busy = true;
+ vpd->busy = 1;
vpd->flag = 0;
ret = pci_vpd_pci22_wait(dev);
if (ret < 0)
vpd->base.ops = &pci_vpd_pci22_ops;
mutex_init(&vpd->lock);
vpd->cap = cap;
- vpd->busy = false;
+ vpd->busy = 0;
dev->vpd = &vpd->base;
return 0;
}