All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Philippe Mathieu-Daudé" <f4bug@amsat.org>
To: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>,
	kraxel@redhat.com, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH 05/14] tcx: alter tcx_set_dirty() to accept address and length parameters
Date: Sat, 15 Apr 2017 11:27:55 -0300	[thread overview]
Message-ID: <46f6de36-7e4a-046c-b9c0-21b873422cb5@amsat.org> (raw)
In-Reply-To: <1491381329-3995-6-git-send-email-mark.cave-ayland@ilande.co.uk>

Hi Mark,

On 04/05/2017 05:35 AM, Mark Cave-Ayland wrote:
> Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
> ---
>  hw/display/tcx.c |   12 ++++++------
>  1 file changed, 6 insertions(+), 6 deletions(-)
>
> diff --git a/hw/display/tcx.c b/hw/display/tcx.c
> index 8e26aae..d24466f 100644
> --- a/hw/display/tcx.c
> +++ b/hw/display/tcx.c
> @@ -93,9 +93,9 @@ typedef struct TCXState {
>      uint16_t cursy;
>  } TCXState;
>
> -static void tcx_set_dirty(TCXState *s)
> +static void tcx_set_dirty(TCXState *s, ram_addr_t addr, int len)

len is uint64_t

with this change:
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>

This function can also be inlined.

>  {
> -    memory_region_set_dirty(&s->vram_mem, 0, MAXX * MAXY);
> +    memory_region_set_dirty(&s->vram_mem, addr, len);
>  }
>
>  static inline int tcx24_check_dirty(TCXState *s, ram_addr_t page,
> @@ -156,7 +156,7 @@ static void update_palette_entries(TCXState *s, int start, int end)
>              break;
>          }
>      }
> -    tcx_set_dirty(s);
> +    tcx_set_dirty(s, 0, memory_region_size(&s->vram_mem));
>  }
>
>  static void tcx_draw_line32(TCXState *s1, uint8_t *d,
> @@ -526,7 +526,7 @@ static void tcx_invalidate_display(void *opaque)
>  {
>      TCXState *s = opaque;
>
> -    tcx_set_dirty(s);
> +    tcx_set_dirty(s, 0, memory_region_size(&s->vram_mem));
>      qemu_console_resize(s->con, s->width, s->height);
>  }
>
> @@ -534,7 +534,7 @@ static void tcx24_invalidate_display(void *opaque)
>  {
>      TCXState *s = opaque;
>
> -    tcx_set_dirty(s);
> +    tcx_set_dirty(s, 0, memory_region_size(&s->vram_mem));
>      qemu_console_resize(s->con, s->width, s->height);
>  }
>
> @@ -543,7 +543,7 @@ static int vmstate_tcx_post_load(void *opaque, int version_id)
>      TCXState *s = opaque;
>
>      update_palette_entries(s, 0, 256);
> -    tcx_set_dirty(s);
> +    tcx_set_dirty(s, 0, memory_region_size(&s->vram_mem));
>      return 0;
>  }
>
>

  reply	other threads:[~2017-04-15 14:28 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-05  8:35 [Qemu-devel] [PATCH 00/14] TCX/CG3 adapter cleanups Mark Cave-Ayland
2017-04-05  8:35 ` [Qemu-devel] [PATCH 01/14] cg3: remove TARGET_PAGE_SIZE rounding on dirty page detection Mark Cave-Ayland
2017-04-05  8:35 ` [Qemu-devel] [PATCH 02/14] cg3: fix up size parameter for memory_region_get_dirty() Mark Cave-Ayland
2017-04-05  8:35 ` [Qemu-devel] [PATCH 03/14] cg3: remove unused width and height variables Mark Cave-Ayland
2017-04-07 19:25   ` Philippe Mathieu-Daudé
2017-04-15 10:54   ` Richard Henderson
2017-04-18 14:38     ` Mark Cave-Ayland
2017-04-18 14:55       ` Richard Henderson
2017-04-21  7:00         ` Mark Cave-Ayland
2017-04-05  8:35 ` [Qemu-devel] [PATCH 04/14] cg3: switch to load_image_mr() and remove prom-addr hack Mark Cave-Ayland
2017-04-15 14:39   ` Philippe Mathieu-Daudé
2017-04-05  8:35 ` [Qemu-devel] [PATCH 05/14] tcx: alter tcx_set_dirty() to accept address and length parameters Mark Cave-Ayland
2017-04-15 14:27   ` Philippe Mathieu-Daudé [this message]
2017-04-18 14:46     ` Mark Cave-Ayland
2017-04-05  8:35 ` [Qemu-devel] [PATCH 06/14] tcx: ensure tcx_set_dirty() also invalidates the 24-bit plane and cplane Mark Cave-Ayland
2017-04-05  8:35 ` [Qemu-devel] [PATCH 07/14] tcx: alter tcx24_check_dirty() to accept address and length parameters Mark Cave-Ayland
2017-04-05  8:35 ` [Qemu-devel] [PATCH 08/14] tcx: alter tcx24_reset_dirty() " Mark Cave-Ayland
2017-04-05  8:35 ` [Qemu-devel] [PATCH 09/14] tcx: remove page24 and cpage from tcx24_update_display() Mark Cave-Ayland
2017-04-05  8:35 ` [Qemu-devel] [PATCH 10/14] tcx: remove TARGET_PAGE_SIZE from tcx_update_display() Mark Cave-Ayland
2017-04-05  8:35 ` [Qemu-devel] [PATCH 11/14] tcx: remove TARGET_PAGE_SIZE from tcx24_update_display() Mark Cave-Ayland
2017-04-05  8:35 ` [Qemu-devel] [PATCH 12/14] tcx: remove primitives for non-32-bit surfaces Mark Cave-Ayland
2017-04-05  8:35 ` [Qemu-devel] [PATCH 13/14] tcx: use tcx_set_dirty() for accelerated ops Mark Cave-Ayland
2017-04-05  8:35 ` [Qemu-devel] [PATCH 14/14] tcx: switch to load_image_mr() and remove prom_addr hack Mark Cave-Ayland
2017-04-15 14:38   ` Philippe Mathieu-Daudé
2017-04-07 10:28 ` [Qemu-devel] [PATCH 00/14] TCX/CG3 adapter cleanups Gerd Hoffmann
2017-04-07 10:37   ` Mark Cave-Ayland
2017-04-07 11:00     ` Gerd Hoffmann

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=46f6de36-7e4a-046c-b9c0-21b873422cb5@amsat.org \
    --to=f4bug@amsat.org \
    --cc=kraxel@redhat.com \
    --cc=mark.cave-ayland@ilande.co.uk \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.