[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 21/24] hw/pci/pci_host: Remove redundant PCI_DPRINTF()
From: |
Michael S. Tsirkin |
Subject: |
[PULL 21/24] hw/pci/pci_host: Remove redundant PCI_DPRINTF() |
Date: |
Thu, 19 Dec 2019 08:28:46 -0500 |
From: Philippe Mathieu-Daudé <address@hidden>
In commit 3bf4dfdd111 we introduced the pci_cfg_[read/write]
trace events in pci_host_config_[read/write]_common().
We have the following call trace:
pci_host_data_[read/write]()
- PCI_DPRINTF()
- pci_data_[read/write]()
- PCI_DPRINTF()
- pci_host_config_[read/write]_common()
trace_pci_cfg_[read/write]()
Since the PCI_DPRINTF() calls are redundant with the trace
events, remove them.
Signed-off-by: Philippe Mathieu-Daudé <address@hidden>
Message-Id: <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>
---
hw/pci/pci_host.c | 21 +++++----------------
1 file changed, 5 insertions(+), 16 deletions(-)
diff --git a/hw/pci/pci_host.c b/hw/pci/pci_host.c
index c5f9244934..0958d157de 100644
--- a/hw/pci/pci_host.c
+++ b/hw/pci/pci_host.c
@@ -115,8 +115,6 @@ void pci_data_write(PCIBus *s, uint32_t addr, uint32_t val,
int len)
return;
}
- PCI_DPRINTF("%s: %s: addr=%02" PRIx32 " val=%08" PRIx32 " len=%d\n",
- __func__, pci_dev->name, config_addr, val, len);
pci_host_config_write_common(pci_dev, config_addr, PCI_CONFIG_SPACE_SIZE,
val, len);
}
@@ -125,18 +123,13 @@ uint32_t pci_data_read(PCIBus *s, uint32_t addr, int len)
{
PCIDevice *pci_dev = pci_dev_find_by_addr(s, addr);
uint32_t config_addr = addr & (PCI_CONFIG_SPACE_SIZE - 1);
- uint32_t val;
if (!pci_dev) {
return ~0x0;
}
- val = pci_host_config_read_common(pci_dev, config_addr,
- PCI_CONFIG_SPACE_SIZE, len);
- PCI_DPRINTF("%s: %s: addr=%02"PRIx32" val=%08"PRIx32" len=%d\n",
- __func__, pci_dev->name, config_addr, val, len);
-
- return val;
+ return pci_host_config_read_common(pci_dev, config_addr,
+ PCI_CONFIG_SPACE_SIZE, len);
}
static void pci_host_config_write(void *opaque, hwaddr addr,
@@ -167,8 +160,7 @@ static void pci_host_data_write(void *opaque, hwaddr addr,
uint64_t val, unsigned len)
{
PCIHostState *s = opaque;
- PCI_DPRINTF("write addr " TARGET_FMT_plx " len %d val %x\n",
- addr, len, (unsigned)val);
+
if (s->config_reg & (1u << 31))
pci_data_write(s->bus, s->config_reg | (addr & 3), val, len);
}
@@ -177,14 +169,11 @@ static uint64_t pci_host_data_read(void *opaque,
hwaddr addr, unsigned len)
{
PCIHostState *s = opaque;
- uint32_t val;
+
if (!(s->config_reg & (1U << 31))) {
return 0xffffffff;
}
- val = pci_data_read(s->bus, s->config_reg | (addr & 3), len);
- PCI_DPRINTF("read addr " TARGET_FMT_plx " len %d val %x\n",
- addr, len, val);
- return val;
+ return pci_data_read(s->bus, s->config_reg | (addr & 3), len);
}
const MemoryRegionOps pci_host_conf_le_ops = {
--
MST
- [PULL 10/24] virtio: don't enable notifications during polling, (continued)
- [PULL 10/24] virtio: don't enable notifications during polling, Michael S. Tsirkin, 2019/12/19
- [PULL 12/24] numa: Extend CLI to provide memory latency and bandwidth information, Michael S. Tsirkin, 2019/12/19
- [PULL 13/24] numa: Extend CLI to provide memory side cache information, Michael S. Tsirkin, 2019/12/19
- [PULL 14/24] hmat acpi: Build Memory Proximity Domain Attributes Structure(s), Michael S. Tsirkin, 2019/12/19
- [PULL 15/24] hmat acpi: Build System Locality Latency and Bandwidth Information Structure(s), Michael S. Tsirkin, 2019/12/19
- [PULL 16/24] hmat acpi: Build Memory Side Cache Information Structure(s), Michael S. Tsirkin, 2019/12/19
- [PULL 17/24] tests/numa: Add case for QMP build HMAT, Michael S. Tsirkin, 2019/12/19
- [PULL 18/24] tests/bios-tables-test: add test cases for ACPI HMAT, Michael S. Tsirkin, 2019/12/19
- [PULL 19/24] ACPI: add expected files for HMAT tests (acpihmat), Michael S. Tsirkin, 2019/12/19
- [PULL 20/24] virtio-mmio: Clear v2 transport state on soft reset, Michael S. Tsirkin, 2019/12/19
- [PULL 21/24] hw/pci/pci_host: Remove redundant PCI_DPRINTF(),
Michael S. Tsirkin <=
- [PULL 22/24] hw/pci/pci_host: Let pci_data_[read/write] use unsigned 'size' argument, Michael S. Tsirkin, 2019/12/19
- [PULL 23/24] vhost-user: add VHOST_USER_RESET_DEVICE to reset devices, Michael S. Tsirkin, 2019/12/19
- [PULL 24/24] vhost-user-scsi: reset the device if supported, Michael S. Tsirkin, 2019/12/19
- [PULL 08/24] virtio-pci: disable vring processing when bus-mastering is disabled, Michael S. Tsirkin, 2019/12/19
- [PULL 11/24] numa: Extend CLI to provide initiator information for numa nodes, Michael S. Tsirkin, 2019/12/19
- Re: [PULL 00/24] virtio, pci, pc: fixes, features, Peter Maydell, 2019/12/20
- Re: [PULL 00/24] virtio, pci, pc: fixes, features, Michael S. Tsirkin, 2019/12/22
- Re: [PULL 00/24] virtio, pci, pc: fixes, features, Michael S. Tsirkin, 2019/12/22