Skip to contentSkip to conversation

pcie: consistent names for function args

PATCH In review Michael S. Tsirkin 2 participants 2 messages Jul 11, 2019 – Jul 12, 2019

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 pcie: consistent names for function args

The function declarations for pci_cap_slot_get and pci_cap_slot_write_config call the argument "slot_ctl", but the function definitions and all the call sites drop the 'o' and call it "slt_ctl". Let's be consistent.

---

Fix pcie_cap_slot_write_config too.

 include/hw/pci/pcie.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
include/hw/pci/pcie.h +2 -2
index 34f277735c..8cf3361fc4 100644
@@ -107,9 +107,9 @@ void pcie_cap_lnkctl_reset(PCIDevice *dev);
 
 void pcie_cap_slot_init(PCIDevice *dev, uint16_t slot);
 void pcie_cap_slot_reset(PCIDevice *dev);
-void pcie_cap_slot_get(PCIDevice *dev, uint16_t *slot_ctl, uint16_t *slt_sta);
+void pcie_cap_slot_get(PCIDevice *dev, uint16_t *slt_ctl, uint16_t *slt_sta);
 void pcie_cap_slot_write_config(PCIDevice *dev,
-                                uint16_t old_slot_ctl, uint16_t old_slt_sta,
+                                uint16_t old_slt_ctl, uint16_t old_slt_sta,
                                 uint32_t addr, uint32_t val, int len);
 int pcie_cap_slot_post_load(void *opaque, int version_id);
 void pcie_cap_slot_push_attention_button(PCIDevice *dev);
Signature · 1 line
MST
Reviewed-by on v2 1/1
#1 lore raw
Quoted 20 lines · Michael S. Tsirkin

The function declarations for pci_cap_slot_get and pci_cap_slot_write_config call the argument "slot_ctl", but the function definitions and all the call sites drop the 'o' and call it "slt_ctl". Let's be consistent.

---

Fix pcie_cap_slot_write_config too.

  include/hw/pci/pcie.h | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
include/hw/pci/pcie.h +0 -0
index 34f277735c..8cf3361fc4 100644
@@ -107,9 +107,9 @@ void pcie_cap_lnkctl_reset(PCIDevice *dev);
 

include/hw/pci/pcie.h void pcie_cap_lnkctl_reset(PCIDevice *dev); · line 115

Quoted 10 lines
include/hw/pci/pcie.h +2 -2
  void pcie_cap_slot_init(PCIDevice *dev, uint16_t slot);
  void pcie_cap_slot_reset(PCIDevice *dev);
-void pcie_cap_slot_get(PCIDevice *dev, uint16_t *slot_ctl, uint16_t *slt_sta);
+void pcie_cap_slot_get(PCIDevice *dev, uint16_t *slt_ctl, uint16_t *slt_sta);
  void pcie_cap_slot_write_config(PCIDevice *dev,
-                                uint16_t old_slot_ctl, uint16_t old_slt_sta,
+                                uint16_t old_slt_ctl, uint16_t old_slt_sta,
                                  uint32_t addr, uint32_t val, int len);
  int pcie_cap_slot_post_load(void *opaque, int version_id);
  void pcie_cap_slot_push_attention_button(PCIDevice *dev);

Thanks,
Marcel