[igt-dev] [PATCH i-g-t] tests/gem_mmap_offset: Fix invalid munmap
Petri Latvala
petri.latvala at intel.com
Wed Mar 24 08:47:37 UTC 2021
On Tue, Mar 23, 2021 at 07:03:47PM +0100, Zbigniew Kempczyński wrote:
> Fix nasty bug which leads to SIGSEGV in blt-coherency test.
> Instead of pointer unmap was done on intel_buf what was wrong.
>
> Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski at intel.com>
> Cc: Petri Latvala <petri.latvala at intel.com>
> Cc: Chris Wilson <chris at chris-wilson.co.uk>
Reviewed-by: Petri Latvala <petri.latvala at intel.com>
> ---
> tests/i915/gem_mmap_offset.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/tests/i915/gem_mmap_offset.c b/tests/i915/gem_mmap_offset.c
> index 8b29d0a0a..de927e32e 100644
> --- a/tests/i915/gem_mmap_offset.c
> +++ b/tests/i915/gem_mmap_offset.c
> @@ -591,7 +591,7 @@ static struct intel_buf *create_bo(struct buf_ops *bops, uint32_t value,
> for (int i = 0; i < 64 / sizeof(*v); i++)
> v[i] = value;
>
> - munmap(buf, size);
> + munmap(v, size);
>
> return buf;
> }
> --
> 2.26.0
>
More information about the igt-dev
mailing list