From: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
To: Mika Kuoppala <mika.kuoppala@linux.intel.com>,
intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH 1/2] drm/i915/gtt: Fix pte clear range
Date: Tue, 01 Nov 2016 10:19:35 +0200 [thread overview]
Message-ID: <1477988375.3103.3.camel@linux.intel.com> (raw)
In-Reply-To: <1477929333-24459-1-git-send-email-mika.kuoppala@intel.com>
On ma, 2016-10-31 at 17:55 +0200, Mika Kuoppala wrote:
> @@ -712,13 +712,13 @@ static int gen8_48b_mm_switch(struct i915_hw_ppgtt *ppgtt,
> */
> static bool gen8_ppgtt_clear_pt(struct i915_address_space *vm,
> struct i915_page_table *pt,
> - uint64_t start,
> - uint64_t length)
> + const uint64_t start,
> + const uint64_t length)
> {
I think const for integers is bit much, with that logic we should make
the pointers const too (not the pointer destination).
> @@ -735,8 +737,8 @@ static bool gen8_ppgtt_clear_pt(struct i915_address_space *vm,
>
> pt_vaddr = kmap_px(pt);
>
> - for (pte = pte_start; pte < num_entries; pte++)
> - pt_vaddr[pte] = scratch_pte;
> + while (pte < pte_end)
> + pt_vaddr[pte++] = scratch_pte;
I'd prefer the for loop still. Just fix "pte < pte_end".
Regards, Joonas
--
Joonas Lahtinen
Open Source Technology Center
Intel Corporation
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2016-11-01 8:19 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-10-31 15:24 [PATCH 1/2] drm/i915/gtt: Fix pte clear range Mika Kuoppala
2016-10-31 15:24 ` [PATCH 2/2] drm/i915/gtt: Mark tlbs dirty on clear Mika Kuoppala
2016-10-31 15:49 ` Chris Wilson
2016-10-31 15:58 ` Mika Kuoppala
2016-10-31 17:14 ` Chris Wilson
2016-10-31 15:42 ` [PATCH 1/2] drm/i915/gtt: Fix pte clear range Chris Wilson
2016-10-31 15:46 ` ✗ Fi.CI.BAT: warning for series starting with [1/2] " Patchwork
2016-10-31 15:55 ` [PATCH 1/2] " Mika Kuoppala
2016-11-01 8:19 ` Joonas Lahtinen [this message]
2016-11-01 10:22 ` Mika Kuoppala
2016-11-01 10:28 ` Chris Wilson
2016-10-31 16:16 ` ✗ Fi.CI.BAT: warning for series starting with [1/2] drm/i915/gtt: Fix pte clear range (rev2) Patchwork
2016-11-01 13:27 ` [PATCH 1/2] drm/i915/gtt: Fix pte clear range Mika Kuoppala
2016-11-02 9:29 ` Joonas Lahtinen
2016-11-01 15:46 ` ✗ Fi.CI.BAT: warning for series starting with [1/2] drm/i915/gtt: Fix pte clear range (rev3) Patchwork
2016-11-01 16:28 ` Mika Kuoppala
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=1477988375.3103.3.camel@linux.intel.com \
--to=joonas.lahtinen@linux.intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=mika.kuoppala@linux.intel.com \
/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.