Browse Source

qcacld-3.0: Add new PLD PCI FW sim API

Add new pld pci fw sim api to read pci configuration header from
host.

Change-Id: Ie1820065f23c7fdf220a4abb9d6975270c2d1766
CRs-Fixed: 2657797
Karthik Kantamneni 5 years ago
parent
commit
16b1553717
2 changed files with 13 additions and 0 deletions
  1. 1 0
      core/pld/src/pld_common.c
  2. 12 0
      core/pld/src/pld_pcie_fw_sim.h

+ 1 - 0
core/pld/src/pld_common.c

@@ -2134,6 +2134,7 @@ int pld_pci_read_config_word(struct pci_dev *pdev, int offset, uint16_t *val)
 		break;
 	case PLD_BUS_TYPE_PCIE_FW_SIM:
 	case PLD_BUS_TYPE_IPCI_FW_SIM:
+		ret = pld_pcie_fw_sim_read_config_word(&pdev->dev, offset, val);
 		break;
 	case PLD_BUS_TYPE_IPCI:
 		break;

+ 12 - 0
core/pld/src/pld_pcie_fw_sim.h

@@ -97,6 +97,12 @@ static inline int pld_pcie_fw_sim_request_irq(struct device *dev, int irq,
 	return 0;
 }
 
+static inline int pld_pcie_fw_sim_read_config_word(struct device *dev,
+						   int offset, uint16_t *val)
+{
+	return 0;
+}
+
 static inline int pld_pcie_fw_sim_free_irq(struct device *dev,
 					   unsigned int ce_id, void *ctx)
 {
@@ -169,6 +175,12 @@ static inline int pld_pcie_fw_sim_request_irq(struct device *dev, int irq,
 				       irqflags, devname, dev_data);
 }
 
+static inline int pld_pcie_fw_sim_read_config_word(struct device *dev,
+						   int offset, uint16_t *val)
+{
+	return cnss_fw_sim_read_config_word(dev, offset, val);
+}
+
 static inline int pld_pcie_fw_sim_free_irq(struct device *dev,
 					   int irq, void *dev_data)
 {