diff options
author | Markus Armbruster <armbru@redhat.com> | 2019-12-04 10:36:23 +0100 |
---|---|---|
committer | Markus Armbruster <armbru@redhat.com> | 2019-12-18 08:36:15 +0100 |
commit | 8ca63ba8c2b1ee6746d2c245d70d82e7f7ef6e46 (patch) | |
tree | 3a8698896660c693232b4f333f155cae7a5758ab /hw/ppc/spapr_pci_nvlink2.c | |
parent | 8574c9f1ad905e473593230308a0b2a68c46ebe3 (diff) |
error: Clean up unusual names of Error * variables
Local Error * variables are conventionally named @err or @local_err,
and Error ** parameters @errp. Naming local variables like parameters
is confusing. Clean that up.
Naming parameters like local variables is also confusing. Left for
another day.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20191204093625.14836-17-armbru@redhat.com>
Diffstat (limited to 'hw/ppc/spapr_pci_nvlink2.c')
-rw-r--r-- | hw/ppc/spapr_pci_nvlink2.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/hw/ppc/spapr_pci_nvlink2.c b/hw/ppc/spapr_pci_nvlink2.c index 4aa89ede23..8332d5694e 100644 --- a/hw/ppc/spapr_pci_nvlink2.c +++ b/hw/ppc/spapr_pci_nvlink2.c @@ -57,7 +57,7 @@ struct SpaprPhbPciNvGpuConfig { uint64_t nv2_atsd_current; int num; /* number of non empty (i.e. tgt!=0) entries in slots[] */ SpaprPhbPciNvGpuSlot slots[NVGPU_MAX_NUM]; - Error *errp; + Error *err; }; static SpaprPhbPciNvGpuSlot * @@ -153,7 +153,7 @@ static void spapr_phb_pci_collect_nvgpu(PCIBus *bus, PCIDevice *pdev, spapr_pci_collect_nvnpu(nvgpus, pdev, tgt, MEMORY_REGION(mr_npu), &local_err); } - error_propagate(&nvgpus->errp, local_err); + error_propagate(&nvgpus->err, local_err); } if ((pci_default_read_config(pdev, PCI_HEADER_TYPE, 1) != PCI_HEADER_TYPE_BRIDGE)) { @@ -187,9 +187,9 @@ void spapr_phb_nvgpu_setup(SpaprPhbState *sphb, Error **errp) pci_for_each_device(bus, pci_bus_num(bus), spapr_phb_pci_collect_nvgpu, sphb->nvgpus); - if (sphb->nvgpus->errp) { - error_propagate(errp, sphb->nvgpus->errp); - sphb->nvgpus->errp = NULL; + if (sphb->nvgpus->err) { + error_propagate(errp, sphb->nvgpus->err); + sphb->nvgpus->err = NULL; goto cleanup_exit; } |