{
u32 reg;
unsigned int devfn;
+ int ret;
devfn = PCI_DEVFN(PCI_SLOT(pdev->devfn), 0);
- pci_bus_read_config_dword(pdev->bus, devfn, PCI_CFG_HFS_2, ®);
- trace_mei_pci_cfg_read(&pdev->dev, "PCI_CFG_HFS_2", PCI_CFG_HFS_2, reg);
+ ret = pci_bus_read_config_dword(pdev->bus, devfn, PCI_CFG_HFS_2, ®);
+ trace_mei_pci_cfg_read(&pdev->dev, "PCI_CFG_HFS_2", PCI_CFG_HFS_2, reg, ret);
/* make sure that bit 9 (NM) is up and bit 10 (DM) is down */
return (reg & 0x600) == 0x200;
}
{
u32 reg;
unsigned int devfn;
+ int ret;
devfn = PCI_DEVFN(PCI_SLOT(pdev->devfn), 0);
- pci_bus_read_config_dword(pdev->bus, devfn, PCI_CFG_HFS_1, ®);
- trace_mei_pci_cfg_read(&pdev->dev, "PCI_CFG_HFS_1", PCI_CFG_HFS_1, reg);
+ ret = pci_bus_read_config_dword(pdev->bus, devfn, PCI_CFG_HFS_1, ®);
+ trace_mei_pci_cfg_read(&pdev->dev, "PCI_CFG_HFS_1", PCI_CFG_HFS_1, reg, ret);
return (reg & PCI_CFG_HFS_1_OPMODE_MSK) == PCI_CFG_HFS_1_OPMODE_SPS;
}
u32 reg;
u32 fw_type;
unsigned int devfn;
+ int ret;
devfn = PCI_DEVFN(PCI_SLOT(pdev->devfn), 0);
- pci_bus_read_config_dword(pdev->bus, devfn, PCI_CFG_HFS_3, ®);
- trace_mei_pci_cfg_read(&pdev->dev, "PCI_CFG_HFS_3", PCI_CFG_HFS_3, reg);
+ ret = pci_bus_read_config_dword(pdev->bus, devfn, PCI_CFG_HFS_3, ®);
+ trace_mei_pci_cfg_read(&pdev->dev, "PCI_CFG_HFS_3", PCI_CFG_HFS_3, reg, ret);
fw_type = (reg & PCI_CFG_HFS_3_FW_SKU_MSK);
dev_dbg(&pdev->dev, "fw type is %d\n", fw_type);
);
TRACE_EVENT(mei_pci_cfg_read,
- TP_PROTO(const struct device *dev, const char *reg, u32 offs, u32 val),
- TP_ARGS(dev, reg, offs, val),
+ TP_PROTO(const struct device *dev, const char *reg, u32 offs, u32 val, int ret),
+ TP_ARGS(dev, reg, offs, val, ret),
TP_STRUCT__entry(
__string(dev, dev_name(dev))
__string(reg, reg)
__field(u32, offs)
__field(u32, val)
+ __field(int, ret)
),
TP_fast_assign(
__assign_str(dev);
__assign_str(reg);
__entry->offs = offs;
__entry->val = val;
+ __entry->ret = ret;
),
- TP_printk("[%s] pci cfg read %s:[%#x] = %#x",
- __get_str(dev), __get_str(reg), __entry->offs, __entry->val)
+ TP_printk("[%s] pci cfg read %s:[%#x] = %#x, ret = %d",
+ __get_str(dev), __get_str(reg), __entry->offs, __entry->val, __entry->ret)
);
#endif /* _MEI_TRACE_H_ */