qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Michael S. Tsirkin" <mst@redhat.com>
To: Avi Kivity <avi@redhat.com>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] pci: simplify memory region registration
Date: Sun, 25 Sep 2011 16:30:31 +0300	[thread overview]
Message-ID: <20110925133030.GA32070@redhat.com> (raw)
In-Reply-To: <1316956977-30466-1-git-send-email-avi@redhat.com>

On Sun, Sep 25, 2011 at 04:22:57PM +0300, Avi Kivity wrote:
> The two code paths (for ADDRESS_SPACE_IO and ADDRESS_SPACE_MEM) are
> identical.  Unify them.
> 
> Signed-off-by: Avi Kivity <avi@redhat.com>

Applied, thanks

> ---
>  hw/pci.c |   13 ++-----------
>  1 files changed, 2 insertions(+), 11 deletions(-)
> 
> diff --git a/hw/pci.c b/hw/pci.c
> index 749e8d8..e8cc1b0 100644
> --- a/hw/pci.c
> +++ b/hw/pci.c
> @@ -998,17 +998,8 @@ static void pci_update_mappings(PCIDevice *d)
>          }
>          r->addr = new_addr;
>          if (r->addr != PCI_BAR_UNMAPPED) {
> -            if (r->type & PCI_BASE_ADDRESS_SPACE_IO) {
> -                memory_region_add_subregion_overlap(r->address_space,
> -                                                    r->addr,
> -                                                    r->memory,
> -                                                    1);
> -            } else {
> -                memory_region_add_subregion_overlap(r->address_space,
> -                                                    r->addr,
> -                                                    r->memory,
> -                                                    1);
> -            }
> +            memory_region_add_subregion_overlap(r->address_space,
> +                                                r->addr, r->memory, 1);
>          }
>      }
>  }
> -- 
> 1.7.6.3

      reply	other threads:[~2011-09-25 13:29 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-25 13:22 [Qemu-devel] [PATCH] pci: simplify memory region registration Avi Kivity
2011-09-25 13:30 ` Michael S. Tsirkin [this message]

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=20110925133030.GA32070@redhat.com \
    --to=mst@redhat.com \
    --cc=avi@redhat.com \
    --cc=qemu-devel@nongnu.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).