qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Philippe Mathieu-Daudé" <philmd@linaro.org>
To: qemu-devel@nongnu.org
Cc: "Michael S. Tsirkin" <mst@redhat.com>,
	Richard Henderson <richard.henderson@linaro.org>,
	Marcel Apfelbaum <marcel.apfelbaum@gmail.com>,
	Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>,
	Helge Deller <deller@gmx.de>
Subject: Re: [PATCH v2 6/7] hw/pci-host/sabre: Re-use generic pci_host_data_le_ops MemoryRegionOps
Date: Mon, 27 Oct 2025 18:00:16 +0100	[thread overview]
Message-ID: <b6881d44-f198-47ef-9c74-e3bb83f51660@linaro.org> (raw)
In-Reply-To: <20251027165304.98296-7-philmd@linaro.org>

On 27/10/25 17:53, Philippe Mathieu-Daudé wrote:
> Avoid duplicating code, re-use the generic generic
> pci_host_data_le_ops MemoryRegionOps.
> 
> Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
> ---
>   hw/pci-host/sabre.c      | 34 +++-------------------------------
>   hw/pci-host/trace-events |  2 --
>   2 files changed, 3 insertions(+), 33 deletions(-)
> 
> diff --git a/hw/pci-host/sabre.c b/hw/pci-host/sabre.c
> index 669191b6c7e..eb3dbe3361f 100644
> --- a/hw/pci-host/sabre.c
> +++ b/hw/pci-host/sabre.c
> @@ -246,28 +246,6 @@ static const MemoryRegionOps sabre_host_config_ops = {
>       .endianness = DEVICE_BIG_ENDIAN,
>   };
>   
> -static void sabre_pci_config_write(void *opaque, hwaddr addr,
> -                                   uint64_t val, unsigned size)
> -{
> -    SabreState *s = opaque;
> -    PCIHostState *phb = PCI_HOST_BRIDGE(s);
> -
> -    trace_sabre_pci_config_write(addr, val);
> -    pci_data_write(phb->bus, addr, val, size);
> -}
> -
> -static uint64_t sabre_pci_config_read(void *opaque, hwaddr addr,
> -                                      unsigned size)
> -{
> -    uint32_t ret;
> -    SabreState *s = opaque;
> -    PCIHostState *phb = PCI_HOST_BRIDGE(s);
> -
> -    ret = pci_data_read(phb->bus, addr, size);

Likely incorrect, please ignore.

> -    trace_sabre_pci_config_read(addr, ret);
> -    return ret;
> -}


  reply	other threads:[~2025-10-27 17:00 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-27 16:52 [PATCH v2 0/7] hw/pci-host: Re-use generic pci_host_data_le_ops MemoryRegionOps Philippe Mathieu-Daudé
2025-10-27 16:52 ` [PATCH v2 1/7] hw/pci/pci_host: Add 'config-reg-check-high-bit' property Philippe Mathieu-Daudé
2025-10-27 17:28   ` Peter Maydell
2025-10-28  7:35     ` Marc-André Lureau
2025-10-27 16:52 ` [PATCH v2 2/7] hw/pci-host/astro: Re-use generic pci_host_data_le_ops MemoryRegionOps Philippe Mathieu-Daudé
2025-10-27 16:52 ` [PATCH v2 3/7] hw/pci-host/dino: " Philippe Mathieu-Daudé
2025-10-27 16:53 ` [PATCH v2 4/7] hw/pci-host/sabre: Remove pointless OBJECT() cast Philippe Mathieu-Daudé
2025-10-27 16:53 ` [PATCH v2 5/7] hw/pci-host/sabre: Include 'host' in host bridge method names Philippe Mathieu-Daudé
2025-10-27 16:53 ` [PATCH v2 6/7] hw/pci-host/sabre: Re-use generic pci_host_data_le_ops MemoryRegionOps Philippe Mathieu-Daudé
2025-10-27 17:00   ` Philippe Mathieu-Daudé [this message]
2025-10-27 16:53 ` [PATCH v2 7/7] hw/pci-host/typhoon: " Philippe Mathieu-Daudé
2025-10-27 16:59   ` Philippe Mathieu-Daudé

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=b6881d44-f198-47ef-9c74-e3bb83f51660@linaro.org \
    --to=philmd@linaro.org \
    --cc=deller@gmx.de \
    --cc=marcel.apfelbaum@gmail.com \
    --cc=mark.cave-ayland@ilande.co.uk \
    --cc=mst@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=richard.henderson@linaro.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).