* [RFC i-g-t 1/6] tests/gem_pread: drop stolen memory related subtests
2017-10-02 23:00 [RFC i-g-t 0/6] Drop tests for object creation from stolen Daniele Ceraolo Spurio
@ 2017-10-02 23:00 ` Daniele Ceraolo Spurio
2017-10-03 11:08 ` Chris Wilson
2017-10-02 23:00 ` [RFC i-g-t 2/6] tests/gem_pwrite: " Daniele Ceraolo Spurio
` (7 subsequent siblings)
8 siblings, 1 reply; 22+ messages in thread
From: Daniele Ceraolo Spurio @ 2017-10-02 23:00 UTC (permalink / raw)
To: intel-gfx
The feature was never merged and there has been no progress in the
last year. The subtests are currently skipping on all platforms by
checking a field in the get_aperture ioctl structure that doesn't
exist in the kernel version of the struct.
Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
---
tests/gem_pread.c | 95 -------------------------------------------------------
1 file changed, 95 deletions(-)
diff --git a/tests/gem_pread.c b/tests/gem_pread.c
index f4cf472..39a46ed 100644
--- a/tests/gem_pread.c
+++ b/tests/gem_pread.c
@@ -40,10 +40,6 @@
#include "drm.h"
#define OBJECT_SIZE 16384
-#define LARGE_OBJECT_SIZE 1024 * 1024
-#define KGRN "\x1B[32m"
-#define KRED "\x1B[31m"
-#define KNRM "\x1B[0m"
static void do_gem_read(int fd, uint32_t handle, void *buf, int len, int loops)
{
@@ -79,8 +75,6 @@ static const char *bytes_per_sec(char *buf, double v)
uint32_t *src, dst;
-uint32_t *dst_user, src_stolen, large_stolen;
-uint32_t *stolen_pf_user, *stolen_nopf_user;
int fd, count;
int main(int argc, char **argv)
@@ -113,8 +107,6 @@ int main(int argc, char **argv)
dst = gem_create(fd, object_size);
src = malloc(object_size);
- src_stolen = gem_create_stolen(fd, object_size);
- dst_user = malloc(object_size);
}
igt_subtest("basic") {
@@ -151,96 +143,9 @@ int main(int argc, char **argv)
}
}
- igt_subtest("stolen-normal") {
- gem_require_stolen_support(fd);
- for (count = 1; count <= 1<<17; count <<= 1) {
- struct timeval start, end;
-
- gettimeofday(&start, NULL);
- do_gem_read(fd, src_stolen, dst_user, object_size, count);
- gettimeofday(&end, NULL);
- usecs = elapsed(&start, &end, count);
- bps = bytes_per_sec(buf, object_size/usecs*1e6);
- igt_info("Time to pread %d bytes x %6d: %7.3fµs, %s\n",
- object_size, count, usecs, bps);
- fflush(stdout);
- }
- }
- for (c = cache; c->level != -1; c++) {
- igt_subtest_f("stolen-%s", c->name) {
- gem_require_stolen_support(fd);
- gem_set_caching(fd, src_stolen, c->level);
-
- for (count = 1; count <= 1<<17; count <<= 1) {
- struct timeval start, end;
-
- gettimeofday(&start, NULL);
- do_gem_read(fd, src_stolen, dst_user,
- object_size, count);
- gettimeofday(&end, NULL);
- usecs = elapsed(&start, &end, count);
- bps = bytes_per_sec(buf, object_size/usecs*1e6);
- igt_info("Time to stolen-%s pread %d bytes x %6d: %7.3fµs, %s\n",
- c->name, object_size, count, usecs, bps);
- fflush(stdout);
- }
- }
- }
-
- /* List the time taken in pread operation for stolen objects, with
- * and without the overhead of page fault handling on accessing the
- * user space buffer
- */
- igt_subtest("pagefault-pread") {
- gem_require_stolen_support(fd);
- large_stolen = gem_create_stolen(fd, LARGE_OBJECT_SIZE);
- stolen_nopf_user = (uint32_t *) mmap(NULL, LARGE_OBJECT_SIZE,
- PROT_WRITE,
- MAP_ANONYMOUS|MAP_PRIVATE,
- -1, 0);
- igt_assert(stolen_nopf_user);
-
- for (count = 1; count <= 10; count ++) {
- struct timeval start, end;
- double t_elapsed = 0;
-
- gettimeofday(&start, NULL);
- do_gem_read(fd, large_stolen, stolen_nopf_user,
- LARGE_OBJECT_SIZE, 1);
- gettimeofday(&end, NULL);
- t_elapsed = elapsed(&start, &end, count);
- bps = bytes_per_sec(buf, object_size/t_elapsed*1e6);
- igt_info("Pagefault-N - Time to pread %d bytes: %7.3fµs, %s\n",
- LARGE_OBJECT_SIZE, t_elapsed, bps);
-
- stolen_pf_user = (uint32_t *) mmap(NULL, LARGE_OBJECT_SIZE,
- PROT_WRITE,
- MAP_ANONYMOUS|MAP_PRIVATE,
- -1, 0);
- igt_assert(stolen_pf_user);
-
- gettimeofday(&start, NULL);
- do_gem_read(fd, large_stolen, stolen_pf_user,
- LARGE_OBJECT_SIZE, 1);
- gettimeofday(&end, NULL);
- usecs = elapsed(&start, &end, count);
- bps = bytes_per_sec(buf, object_size/usecs*1e6);
- igt_info("Pagefault-Y - Time to pread %d bytes: %7.3fµs, %s%s%s\n",
- LARGE_OBJECT_SIZE, usecs,
- t_elapsed < usecs ? KGRN : KRED, bps, KNRM);
- fflush(stdout);
- munmap(stolen_pf_user, LARGE_OBJECT_SIZE);
- }
- munmap(stolen_nopf_user, LARGE_OBJECT_SIZE);
- gem_close(fd, large_stolen);
- }
-
-
igt_fixture {
free(src);
gem_close(fd, dst);
- free(dst_user);
- gem_close(fd, src_stolen);
close(fd);
}
--
1.9.1
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 22+ messages in thread* Re: [RFC i-g-t 1/6] tests/gem_pread: drop stolen memory related subtests
2017-10-02 23:00 ` [RFC i-g-t 1/6] tests/gem_pread: drop stolen memory related subtests Daniele Ceraolo Spurio
@ 2017-10-03 11:08 ` Chris Wilson
2017-10-03 15:36 ` Daniele Ceraolo Spurio
0 siblings, 1 reply; 22+ messages in thread
From: Chris Wilson @ 2017-10-03 11:08 UTC (permalink / raw)
To: Daniele Ceraolo Spurio, intel-gfx
Quoting Daniele Ceraolo Spurio (2017-10-03 00:00:13)
> The feature was never merged and there has been no progress in the
> last year. The subtests are currently skipping on all platforms by
> checking a field in the get_aperture ioctl structure that doesn't
> exist in the kernel version of the struct.
The interface for this is upstream, fix the test to exercise the kernel
code (hint dmabuf).
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: [RFC i-g-t 1/6] tests/gem_pread: drop stolen memory related subtests
2017-10-03 11:08 ` Chris Wilson
@ 2017-10-03 15:36 ` Daniele Ceraolo Spurio
2017-10-03 15:49 ` Chris Wilson
0 siblings, 1 reply; 22+ messages in thread
From: Daniele Ceraolo Spurio @ 2017-10-03 15:36 UTC (permalink / raw)
To: Chris Wilson, intel-gfx
On 03/10/17 04:08, Chris Wilson wrote:
> Quoting Daniele Ceraolo Spurio (2017-10-03 00:00:13)
>> The feature was never merged and there has been no progress in the
>> last year. The subtests are currently skipping on all platforms by
>> checking a field in the get_aperture ioctl structure that doesn't
>> exist in the kernel version of the struct.
>
> The interface for this is upstream, fix the test to exercise the kernel
> code (hint dmabuf).
> -Chris
>
I'm not very familiar with the dmabuf interface, but looking at it I
couldn't find any way of allocating and/or accessing an object in stolen
memory from userspace. A grep for "create_stolen" also didn't show
anything. Can you point me in the right direction?
Thanks,
Daniele
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: [RFC i-g-t 1/6] tests/gem_pread: drop stolen memory related subtests
2017-10-03 15:36 ` Daniele Ceraolo Spurio
@ 2017-10-03 15:49 ` Chris Wilson
2017-10-03 16:02 ` Daniele Ceraolo Spurio
0 siblings, 1 reply; 22+ messages in thread
From: Chris Wilson @ 2017-10-03 15:49 UTC (permalink / raw)
To: Daniele Ceraolo Spurio, intel-gfx
Quoting Daniele Ceraolo Spurio (2017-10-03 16:36:37)
>
>
> On 03/10/17 04:08, Chris Wilson wrote:
> > Quoting Daniele Ceraolo Spurio (2017-10-03 00:00:13)
> >> The feature was never merged and there has been no progress in the
> >> last year. The subtests are currently skipping on all platforms by
> >> checking a field in the get_aperture ioctl structure that doesn't
> >> exist in the kernel version of the struct.
> >
> > The interface for this is upstream, fix the test to exercise the kernel
> > code (hint dmabuf).
> > -Chris
> >
>
> I'm not very familiar with the dmabuf interface, but looking at it I
> couldn't find any way of allocating and/or accessing an object in stolen
> memory from userspace. A grep for "create_stolen" also didn't show
> anything. Can you point me in the right direction?
It's just that a dmabuf of a e.g. vgem bo will use the same pread paths
that we originally wrote for stolen support. (We need a bo that is not
backed by struct page.)
Something like
static uint32_t create_foreign_bo(int device, uint32_t sz, void *data)
{
struct vgem_bo scratch;
int vgem, dmabuf;
uint32_t handle;
vgem = drm_driver_open(DRIVER_VGEM);
scratch.width = 1024;
scratch.height = sz / 4096;
scratch.bpp = 32;
vgem_create(vgem, &scratch);
igt_assert_eq(sz, scratch.size);
if (data) {
void *ptr;
ptr = vgem_mmap(vgem, &scratch, PROT_WRITE);
memcpy(ptr, data, sz);
munmap(ptr, scratch.size);
}
dmabuf = prime_handle_to_fd(vgem, scratch.handle);
handle = prime_fd_to_handle(device, dmabuf);
close(dmabuf);
close(vgem);
return handle;
}
will create a handle that we can pass to pread to exercise the same
paths. For pwrite, we need to keep the vgem bo around so we can read
back from its mmapping.
We do have coverage in prime_vgem.c, but it's not the first place you
would go to exercise i915_gem_pread_ioctl().
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 22+ messages in thread* Re: [RFC i-g-t 1/6] tests/gem_pread: drop stolen memory related subtests
2017-10-03 15:49 ` Chris Wilson
@ 2017-10-03 16:02 ` Daniele Ceraolo Spurio
0 siblings, 0 replies; 22+ messages in thread
From: Daniele Ceraolo Spurio @ 2017-10-03 16:02 UTC (permalink / raw)
To: Chris Wilson, intel-gfx
On 03/10/17 08:49, Chris Wilson wrote:
> Quoting Daniele Ceraolo Spurio (2017-10-03 16:36:37)
>>
>>
>> On 03/10/17 04:08, Chris Wilson wrote:
>>> Quoting Daniele Ceraolo Spurio (2017-10-03 00:00:13)
>>>> The feature was never merged and there has been no progress in the
>>>> last year. The subtests are currently skipping on all platforms by
>>>> checking a field in the get_aperture ioctl structure that doesn't
>>>> exist in the kernel version of the struct.
>>>
>>> The interface for this is upstream, fix the test to exercise the kernel
>>> code (hint dmabuf).
>>> -Chris
>>>
>>
>> I'm not very familiar with the dmabuf interface, but looking at it I
>> couldn't find any way of allocating and/or accessing an object in stolen
>> memory from userspace. A grep for "create_stolen" also didn't show
>> anything. Can you point me in the right direction?
>
> It's just that a dmabuf of a e.g. vgem bo will use the same pread paths
> that we originally wrote for stolen support. (We need a bo that is not
> backed by struct page.)
>
> Something like
>
> static uint32_t create_foreign_bo(int device, uint32_t sz, void *data)
> {
> struct vgem_bo scratch;
> int vgem, dmabuf;
> uint32_t handle;
>
> vgem = drm_driver_open(DRIVER_VGEM);
>
> scratch.width = 1024;
> scratch.height = sz / 4096;
> scratch.bpp = 32;
> vgem_create(vgem, &scratch);
>
> igt_assert_eq(sz, scratch.size);
>
> if (data) {
> void *ptr;
>
> ptr = vgem_mmap(vgem, &scratch, PROT_WRITE);
> memcpy(ptr, data, sz);
> munmap(ptr, scratch.size);
> }
>
> dmabuf = prime_handle_to_fd(vgem, scratch.handle);
> handle = prime_fd_to_handle(device, dmabuf);
> close(dmabuf);
>
> close(vgem);
>
> return handle;
> }
>
> will create a handle that we can pass to pread to exercise the same
> paths. For pwrite, we need to keep the vgem bo around so we can read
> back from its mmapping.
>
> We do have coverage in prime_vgem.c, but it's not the first place you
> would go to exercise i915_gem_pread_ioctl().
> -Chris
>
Thanks for the clarification. I'll update the patch to replace the
stolen tests with the vgem ones.
Daniele
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 22+ messages in thread
* [RFC i-g-t 2/6] tests/gem_pwrite: drop stolen memory related subtests
2017-10-02 23:00 [RFC i-g-t 0/6] Drop tests for object creation from stolen Daniele Ceraolo Spurio
2017-10-02 23:00 ` [RFC i-g-t 1/6] tests/gem_pread: drop stolen memory related subtests Daniele Ceraolo Spurio
@ 2017-10-02 23:00 ` Daniele Ceraolo Spurio
2017-10-03 11:08 ` Chris Wilson
2017-10-02 23:00 ` [RFC i-g-t 3/6] tests/gem_create: drop stolen memory related subtest Daniele Ceraolo Spurio
` (6 subsequent siblings)
8 siblings, 1 reply; 22+ messages in thread
From: Daniele Ceraolo Spurio @ 2017-10-02 23:00 UTC (permalink / raw)
To: intel-gfx
The feature was never merged and there has been no progress in the
last year. The subtests are currently skipping on all platforms by
checking a field in the get_aperture ioctl structure that doesn't
exist in the kernel version of the struct.
Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
---
tests/gem_pwrite.c | 43 -------------------------------------------
1 file changed, 43 deletions(-)
diff --git a/tests/gem_pwrite.c b/tests/gem_pwrite.c
index b61b446..1c3d23d 100644
--- a/tests/gem_pwrite.c
+++ b/tests/gem_pwrite.c
@@ -206,7 +206,6 @@ static void test_big_gtt(int fd, int scale, unsigned flags)
}
uint32_t *src, dst;
-uint32_t *src_user, dst_stolen;
int fd;
int main(int argc, char **argv)
@@ -241,8 +240,6 @@ int main(int argc, char **argv)
dst = gem_create(fd, object_size);
src = malloc(object_size);
- dst_stolen = gem_create_stolen(fd, object_size);
- src_user = malloc(object_size);
}
igt_subtest("basic") {
@@ -279,49 +276,9 @@ int main(int argc, char **argv)
}
}
- igt_subtest("stolen-normal") {
- gem_require_stolen_support(fd);
- for (count = 1; count <= 1<<17; count <<= 1) {
- struct timeval start, end;
-
- gettimeofday(&start, NULL);
- do_gem_write(fd, dst_stolen, src_user,
- object_size, count);
- gettimeofday(&end, NULL);
- usecs = elapsed(&start, &end, count);
- bps = bytes_per_sec(buf, object_size/usecs*1e6);
- igt_info("Time to pwrite %d bytes x %6d: %7.3fµs, %s\n",
- object_size, count, usecs, bps);
- fflush(stdout);
- }
- }
-
- for (c = cache; c->level != -1; c++) {
- igt_subtest_f("stolen-%s", c->name) {
- gem_require_stolen_support(fd);
- gem_set_caching(fd, dst, c->level);
- for (count = 1; count <= 1<<17; count <<= 1) {
- struct timeval start, end;
-
- gettimeofday(&start, NULL);
- do_gem_write(fd, dst_stolen, src_user,
- object_size, count);
- gettimeofday(&end, NULL);
- bps = bytes_per_sec(buf,
- object_size/usecs*1e6);
- igt_info("Time to stolen-%s pwrite %d bytes x %6d: %7.3fµs, %s\n",
- c->name, object_size, count,
- usecs, bps);
- fflush(stdout);
- }
- }
- }
-
igt_fixture {
free(src);
gem_close(fd, dst);
- free(src_user);
- gem_close(fd, dst_stolen);
}
{
--
1.9.1
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 22+ messages in thread* [RFC i-g-t 3/6] tests/gem_create: drop stolen memory related subtest
2017-10-02 23:00 [RFC i-g-t 0/6] Drop tests for object creation from stolen Daniele Ceraolo Spurio
2017-10-02 23:00 ` [RFC i-g-t 1/6] tests/gem_pread: drop stolen memory related subtests Daniele Ceraolo Spurio
2017-10-02 23:00 ` [RFC i-g-t 2/6] tests/gem_pwrite: " Daniele Ceraolo Spurio
@ 2017-10-02 23:00 ` Daniele Ceraolo Spurio
2017-10-02 23:00 ` [RFC i-g-t 4/6] tests/gem_stolen: drop gem_stolen.c Daniele Ceraolo Spurio
` (5 subsequent siblings)
8 siblings, 0 replies; 22+ messages in thread
From: Daniele Ceraolo Spurio @ 2017-10-02 23:00 UTC (permalink / raw)
To: intel-gfx
The feature was never merged and there has been no progress in the
last year. The subtest is currently skipping on all platforms by checking
a field in the get_aperture ioctl structure that doesn't exist in the
kernel version of the struct.
Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
---
tests/gem_create.c | 37 ++-----------------------------------
1 file changed, 2 insertions(+), 35 deletions(-)
diff --git a/tests/gem_create.c b/tests/gem_create.c
index de7b820..a451816 100644
--- a/tests/gem_create.c
+++ b/tests/gem_create.c
@@ -27,8 +27,7 @@
/** @file gem_create.c
*
- * This is a test for the extended and old gem_create ioctl, that
- * includes allocation of object from stolen memory and shmem.
+ * This is a test for the gem_create ioctl.
*
* The goal is to simply ensure that basics work and invalid input
* combinations are rejected.
@@ -57,42 +56,13 @@
#include "drm.h"
#include "i915_drm.h"
-IGT_TEST_DESCRIPTION("This is a test for the extended & old gem_create ioctl,"
- " that includes allocation of object from stolen memory"
- " and shmem.");
+IGT_TEST_DESCRIPTION("This is a test for the gem_create ioctl");
#define CLEAR(s) memset(&s, 0, sizeof(s))
#define PAGE_SIZE 4096
-struct local_i915_gem_create_v2 {
- uint64_t size;
- uint32_t handle;
- uint32_t pad;
-#define I915_CREATE_PLACEMENT_STOLEN (1<<0)
- uint32_t flags;
-} create;
-
#define LOCAL_IOCTL_I915_GEM_CREATE DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_CREATE, struct local_i915_gem_create_v2)
-static void invalid_flag_test(int fd)
-{
- int ret;
-
- gem_require_stolen_support(fd);
-
- create.handle = 0;
- create.size = PAGE_SIZE;
- create.flags = ~I915_CREATE_PLACEMENT_STOLEN;
- ret = drmIoctl(fd, LOCAL_IOCTL_I915_GEM_CREATE, &create);
-
- igt_assert(ret <= 0);
-
- create.flags = ~0;
- ret = drmIoctl(fd, LOCAL_IOCTL_I915_GEM_CREATE, &create);
-
- igt_assert(ret <= 0);
-}
-
static void invalid_size_test(int fd)
{
int handle;
@@ -152,9 +122,6 @@ igt_main
fd = drm_open_driver(DRIVER_INTEL);
}
- igt_subtest("stolen-invalid-flag")
- invalid_flag_test(fd);
-
igt_subtest("create-invalid-size")
invalid_size_test(fd);
--
1.9.1
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 22+ messages in thread* [RFC i-g-t 4/6] tests/gem_stolen: drop gem_stolen.c
2017-10-02 23:00 [RFC i-g-t 0/6] Drop tests for object creation from stolen Daniele Ceraolo Spurio
` (2 preceding siblings ...)
2017-10-02 23:00 ` [RFC i-g-t 3/6] tests/gem_create: drop stolen memory related subtest Daniele Ceraolo Spurio
@ 2017-10-02 23:00 ` Daniele Ceraolo Spurio
2017-10-03 9:19 ` Petri Latvala
2017-10-02 23:00 ` [RFC i-g-t 5/6] tests/gem_concurrent_all: drop stolen memory related subtests Daniele Ceraolo Spurio
` (4 subsequent siblings)
8 siblings, 1 reply; 22+ messages in thread
From: Daniele Ceraolo Spurio @ 2017-10-02 23:00 UTC (permalink / raw)
To: intel-gfx
The feature was never merged and there has been no progress in the
last year. The subtests are currently skipping on all platforms by
checking a field in the get_aperture ioctl structure that doesn't
exist in the kernel version of the struct.
Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
---
tests/Makefile.sources | 1 -
tests/gem_stolen.c | 455 -------------------------------------------------
2 files changed, 456 deletions(-)
delete mode 100644 tests/gem_stolen.c
diff --git a/tests/Makefile.sources b/tests/Makefile.sources
index c4d320e..b2a9cfe 100644
--- a/tests/Makefile.sources
+++ b/tests/Makefile.sources
@@ -141,7 +141,6 @@ TESTS_progs = \
gem_shrink \
gem_softpin \
gem_spin_batch \
- gem_stolen \
gem_storedw_batches_loop \
gem_storedw_loop \
gem_streaming_writes \
diff --git a/tests/gem_stolen.c b/tests/gem_stolen.c
deleted file mode 100644
index 1d48997..0000000
--- a/tests/gem_stolen.c
+++ /dev/null
@@ -1,455 +0,0 @@
-/*
- * Copyright © 2015 Intel Corporation
- *
- * Permission is hereby granted, free of charge, to any person obtaining a
- * copy of this software and associated documentation files (the "Software"),
- * to deal in the Software without restriction, including without limitation
- * the rights to use, copy, modify, merge, publish, distribute, sublicense,
- * and/or sell copies of the Software, and to permit persons to whom the
- * Software is furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice (including the next
- * paragraph) shall be included in all copies or substantial portions of the
- * Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
- * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
- * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
- * IN THE SOFTWARE.
- *
- * Authors:
- * Ankitprasad Sharma <ankitprasad.r.sharma at intel.com>
- *
- */
-
-/** @file gem_create_stolen.c
- *
- * This is a test for the extended gem_create ioctl, that includes allocation
- * of object from stolen memory.
- *
- * The goal is to simply ensure the basics work, and invalid input combinations
- * are rejected.
- */
-
-#include <stdlib.h>
-#include <sys/ioctl.h>
-#include <stdio.h>
-#include <string.h>
-#include <fcntl.h>
-#include <inttypes.h>
-#include <errno.h>
-#include <sys/stat.h>
-#include <sys/time.h>
-#include <getopt.h>
-
-#include <drm.h>
-
-#include "ioctl_wrappers.h"
-#include "intel_bufmgr.h"
-#include "intel_batchbuffer.h"
-#include "intel_io.h"
-#include "intel_chipset.h"
-#include "igt_aux.h"
-#include "drmtest.h"
-#include "drm.h"
-#include "i915_drm.h"
-
-IGT_TEST_DESCRIPTION("This test verifies the exetended gem_create ioctl,"
- " that includes allocation of obj from stolen region");
-#define CLEAR(s) memset(&s, 0, sizeof(s))
-#define SIZE 1024*1024
-#define DWORD_SIZE 4
-#define DATA 0xdead
-#define LARGE_SIZE 0xffffffff
-#define MAX_OBJECTS 100
-
-static drm_intel_bufmgr *bufmgr;
-static struct intel_batchbuffer *batch;
-
-static void verify_copy_op(drm_intel_bo *src, drm_intel_bo *dest)
-{
- uint32_t *virt, i, ret;
- /* Fill the src BO with dwords */
- ret = drm_intel_gem_bo_map_gtt(src);
- igt_assert(!ret);
-
- virt = src->virtual;
- for (i = 0; i < SIZE/DWORD_SIZE; i++)
- virt[i] = i;
-
- intel_copy_bo(batch, dest, src, SIZE);
-
- ret = drm_intel_gem_bo_map_gtt(dest);
- igt_assert(!ret);
-
- virt = dest->virtual;
- /* verify */
- for (i = 0; i < SIZE/DWORD_SIZE; i++)
- igt_assert_eq(virt[i], i);
-
- drm_intel_bo_unmap(src);
- drm_intel_bo_unmap(dest);
-}
-
-static void stolen_pwrite(int fd)
-{
- drm_intel_bo *bo;
- uint32_t buf[SIZE/DWORD_SIZE];
- uint32_t handle = 0;
- uint32_t *virt;
- int i, ret = 0;
-
- for (i = 0; i < SIZE/DWORD_SIZE; i++)
- buf[i] = DATA;
-
- gem_require_stolen_support(fd);
-
- handle = gem_create_stolen(fd, SIZE);
-
- gem_write(fd, handle, 0, buf, SIZE);
- bo = gem_handle_to_libdrm_bo(bufmgr, fd, "bo", handle);
-
- ret = drm_intel_gem_bo_map_gtt(bo);
- igt_assert(!ret);
-
- virt = bo->virtual;
-
- for (i = 0; i < SIZE/DWORD_SIZE; i++)
- igt_assert_eq(virt[i], DATA);
-
- drm_intel_bo_unmap(bo);
- drm_intel_bo_unreference(bo);
- gem_close(fd, handle);
-}
-
-static void stolen_pread(int fd)
-{
- drm_intel_bo *bo;
- uint32_t buf[SIZE/DWORD_SIZE];
- uint32_t handle = 0;
- uint32_t *virt;
- int i, ret = 0;
-
- CLEAR(buf);
-
- gem_require_stolen_support(fd);
-
- handle = gem_create_stolen(fd, SIZE);
-
- bo = gem_handle_to_libdrm_bo(bufmgr, fd, "bo", handle);
-
- ret = drm_intel_gem_bo_map_gtt(bo);
- igt_assert(!ret);
-
- virt = bo->virtual;
-
- for (i = 0; i < SIZE/DWORD_SIZE; i++)
- virt[i] = DATA;
-
- drm_intel_bo_unmap(bo);
- drm_intel_bo_unreference(bo);
-
- gem_read(fd, handle, 0, buf, SIZE);
-
- for (i = 0; i < SIZE/DWORD_SIZE; i++)
- igt_assert_eq(buf[i], DATA);
-
- gem_close(fd, handle);
-}
-
-static void copy_test(int fd)
-{
- drm_intel_bo *src, *dest;
- uint32_t src_handle = 0, dest_handle = 0;
-
- gem_require_stolen_support(fd);
-
- src_handle = gem_create_stolen(fd, SIZE);
- dest_handle = gem_create_stolen(fd, SIZE);
-
- src = gem_handle_to_libdrm_bo(bufmgr, fd, "src_bo", src_handle);
- dest = gem_handle_to_libdrm_bo(bufmgr, fd, "dst_bo", dest_handle);
-
- igt_assert(src != NULL);
- igt_assert(dest != NULL);
-
- verify_copy_op(src, dest);
-
- drm_intel_bo_unreference(src);
- drm_intel_bo_unreference(dest);
- gem_close(fd, src_handle);
- gem_close(fd, dest_handle);
-}
-
-static void verify_object_clear(int fd)
-{
- drm_intel_bo *bo;
- uint32_t handle = 0;
- uint32_t *virt;
- int i, ret;
-
- gem_require_stolen_support(fd);
-
- handle = gem_create_stolen(fd, SIZE);
-
- bo = gem_handle_to_libdrm_bo(bufmgr, fd, "verify_bo", handle);
- igt_assert(bo != NULL);
-
- ret = drm_intel_gem_bo_map_gtt(bo);
- igt_assert(!ret);
-
- /* Verify if the BO is zeroed */
- virt = bo->virtual;
- for (i = 0; i < SIZE / DWORD_SIZE; i++)
- igt_assert(!virt[i]);
-
- drm_intel_bo_unmap(bo);
- drm_intel_bo_unreference(bo);
- gem_close(fd, handle);
-}
-
-static void stolen_large_obj_alloc(int fd)
-{
- uint32_t handle = 0;
-
- gem_require_stolen_support(fd);
- handle = __gem_create_stolen(fd, (unsigned long long) LARGE_SIZE + 4096);
- igt_assert(!handle);
-}
-
-static void stolen_fill_purge_test(int fd)
-{
- drm_intel_bo *bo;
- int obj_count = 0, i = 0;
- int _ret = 0, j = 0;
- uint32_t handle[MAX_OBJECTS];
- uint32_t new_handle;
- uint32_t *virt;
- int retained;
-
- gem_require_stolen_support(fd);
-
- /* Exhaust Stolen space */
- do {
- handle[i] = __gem_create_stolen(fd, SIZE);
- if (handle[i] != 0) {
- bo = gem_handle_to_libdrm_bo(bufmgr, fd,
- "verify_bo", handle[i]);
- igt_assert(bo != NULL);
-
- _ret = drm_intel_gem_bo_map_gtt(bo);
- igt_assert(!_ret);
-
- virt = bo->virtual;
- for (j = 0; j < SIZE/DWORD_SIZE; j++)
- virt[j] = DATA;
-
- drm_intel_bo_unmap(bo);
- drm_intel_bo_unreference(bo);
-
- obj_count++;
- }
-
- i++;
- } while (handle[i-1] && i < MAX_OBJECTS);
-
- igt_assert(obj_count > 0);
-
- /* Mark all stolen objects purgeable */
- for (i = 0; i < obj_count; i++)
- retained = gem_madvise(fd, handle[i], I915_MADV_DONTNEED);
-
- /* Try to allocate one more object */
- new_handle = gem_create_stolen(fd, SIZE);
-
- /* Check if the retained object's memory contents are intact */
- for (i = 0; i < obj_count; i++) {
- retained = gem_madvise(fd, handle[i], I915_MADV_WILLNEED);
- if (retained) {
- bo = gem_handle_to_libdrm_bo(bufmgr, fd,
- "verify_bo", handle[i]);
- igt_assert(bo != NULL);
-
- _ret = drm_intel_gem_bo_map_gtt(bo);
- igt_assert(!_ret);
-
- virt = bo->virtual;
- for (j = 0; j < SIZE/DWORD_SIZE; j++)
- igt_assert_eq(virt[j], DATA);
-
- drm_intel_bo_unmap(bo);
- drm_intel_bo_unreference(bo);
- }
- }
-
- gem_close(fd, new_handle);
- for (i = 0; i < obj_count; i++)
- gem_close(fd, handle[i]);
-}
-
-static void stolen_hibernate(int fd)
-{
- drm_intel_bo *bo;
- drm_intel_bo *src, *dest;
- int obj_count = 0, i = 0;
- int ret, j;
- uint32_t handle[MAX_OBJECTS], src_handle;
- uint32_t *virt;
-
- gem_require_stolen_support(fd);
-
- src_handle = gem_create(fd, SIZE);
- src = gem_handle_to_libdrm_bo(bufmgr, fd,
- "bo", src_handle);
- igt_assert(src != NULL);
-
- ret = drm_intel_gem_bo_map_gtt(src);
- igt_assert_eq(ret, 0);
-
- virt = src->virtual;
- for (j = 0; j < SIZE/DWORD_SIZE; j++) {
- igt_assert_eq(virt[j], 0);
- virt[j] = j;
- }
-
- drm_intel_bo_unmap(src);
- /* Exhaust Stolen space */
- for (i = 0; i < MAX_OBJECTS; i++) {
- handle[i] = __gem_create_stolen(fd, SIZE);
- if (!handle[i])
- break;
-
- bo = gem_handle_to_libdrm_bo(bufmgr, fd,
- "verify_bo", handle[i]);
- igt_assert(bo != NULL);
- ret = drm_intel_gem_bo_map_gtt(bo);
- igt_assert_eq(ret, 0);
-
- virt = bo->virtual;
- for (j = 0; j < SIZE/DWORD_SIZE; j++)
- igt_assert_eq(virt[j], 0);
-
- drm_intel_bo_unmap(bo);
- drm_intel_bo_unreference(bo);
-
- obj_count++;
- }
-
- /* Assert if atleast one object is allocated from stolen, that
- * is good enough to verify the content preservation across
- * hibernation.
- */
- igt_assert(obj_count > 0);
-
- /* Copy data to all stolen backed objects */
- for (i = 0; i < obj_count; i++) {
- dest = gem_handle_to_libdrm_bo(bufmgr, fd,
- "dst_bo", handle[i]);
- igt_assert(dest != NULL);
- /* Copy contents to stolen backed objects via blt and
- * verify post-hibernation, this also helps in identifying
- * that the operation was completed before going to
- * hibernation.
- */
- intel_copy_bo(batch, dest, src, SIZE);
- }
-
- drm_intel_bo_unreference(src);
-
- igt_system_suspend_autoresume(SUSPEND_STATE_DISK, SUSPEND_TEST_NONE);
- /* Check if the object's memory contents are intact
- * across hibernation.
- */
- for (i = 0; i < obj_count; i++) {
- bo = gem_handle_to_libdrm_bo(bufmgr, fd,
- "verify_bo", handle[i]);
- igt_assert(bo != NULL);
- ret = drm_intel_gem_bo_map_gtt(bo);
- igt_assert_eq(ret, 0);
- virt = bo->virtual;
- for (j = 0; j < SIZE/DWORD_SIZE; j++)
- igt_assert_eq(virt[j], j);
-
- drm_intel_bo_unmap(bo);
- drm_intel_bo_unreference(bo);
- }
-
- gem_close(fd, src_handle);
- for (i = 0; i < obj_count; i++)
- gem_close(fd, handle[i]);
-}
-
-static void
-stolen_no_mmap(int fd)
-{
- void *addr;
- uint32_t handle = 0;
-
- gem_require_stolen_support(fd);
-
- handle = gem_create_stolen(fd, SIZE);
-
- addr = __gem_mmap__cpu(fd, handle, 0, SIZE, PROT_READ | PROT_WRITE);
- igt_assert(addr == NULL);
-
- gem_close(fd, handle);
-}
-
-igt_main
-{
- int fd;
- uint32_t devid;
-
- igt_skip_on_simulation();
-
- igt_fixture {
- fd = drm_open_driver(DRIVER_INTEL);
- devid = intel_get_drm_devid(fd);
-
- bufmgr = drm_intel_bufmgr_gem_init(fd, 4096);
- batch = intel_batchbuffer_alloc(bufmgr, devid);
- }
-
- igt_subtest("stolen-clear")
- verify_object_clear(fd);
-
- /*
- * stolen mem special cases - checking for non cpu mappable
- */
- igt_subtest("stolen-no-mmap")
- stolen_no_mmap(fd);
-
- /* checking for pread/pwrite interfaces */
- igt_subtest("stolen-pwrite")
- stolen_pwrite(fd);
-
- igt_subtest("stolen-pread")
- stolen_pread(fd);
-
- /* Functional Test - blt copy */
- igt_subtest("stolen-copy")
- copy_test(fd);
-
- igt_subtest("large-object-alloc")
- stolen_large_obj_alloc(fd);
-
- /* Filling stolen completely and marking all the objects
- * purgeable. Then trying to add one more object, to verify
- * the purging logic.
- * Again marking all objects WILLNEED and verifying the
- * contents of the retained objects.
- */
- igt_subtest("stolen-fill-purge")
- stolen_fill_purge_test(fd);
-
- igt_subtest("stolen-hibernate")
- stolen_hibernate(fd);
-
- igt_fixture {
- intel_batchbuffer_free(batch);
- drm_intel_bufmgr_destroy(bufmgr);
- }
-}
--
1.9.1
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 22+ messages in thread* Re: [RFC i-g-t 4/6] tests/gem_stolen: drop gem_stolen.c
2017-10-02 23:00 ` [RFC i-g-t 4/6] tests/gem_stolen: drop gem_stolen.c Daniele Ceraolo Spurio
@ 2017-10-03 9:19 ` Petri Latvala
0 siblings, 0 replies; 22+ messages in thread
From: Petri Latvala @ 2017-10-03 9:19 UTC (permalink / raw)
To: Daniele Ceraolo Spurio; +Cc: intel-gfx
On Mon, Oct 02, 2017 at 04:00:16PM -0700, Daniele Ceraolo Spurio wrote:
> The feature was never merged and there has been no progress in the
> last year. The subtests are currently skipping on all platforms by
> checking a field in the get_aperture ioctl structure that doesn't
> exist in the kernel version of the struct.
>
> Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
> ---
> tests/Makefile.sources | 1 -
> tests/gem_stolen.c | 455 -------------------------------------------------
> 2 files changed, 456 deletions(-)
> delete mode 100644 tests/gem_stolen.c
>
> diff --git a/tests/Makefile.sources b/tests/Makefile.sources
> index c4d320e..b2a9cfe 100644
> --- a/tests/Makefile.sources
> +++ b/tests/Makefile.sources
> @@ -141,7 +141,6 @@ TESTS_progs = \
> gem_shrink \
> gem_softpin \
> gem_spin_batch \
> - gem_stolen \
> gem_storedw_batches_loop \
> gem_storedw_loop \
> gem_streaming_writes \
Same change for meson.build needed:
diff --git a/tests/meson.build b/tests/meson.build
index 6cb3584a..5db3b39f 100644
--- a/tests/meson.build
+++ b/tests/meson.build
@@ -121,7 +121,6 @@ test_progs = [
'gem_shrink',
'gem_softpin',
'gem_spin_batch',
- 'gem_stolen',
'gem_storedw_batches_loop',
'gem_storedw_loop',
'gem_streaming_writes',
--
Petri Latvala
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 22+ messages in thread
* [RFC i-g-t 5/6] tests/gem_concurrent_all: drop stolen memory related subtests
2017-10-02 23:00 [RFC i-g-t 0/6] Drop tests for object creation from stolen Daniele Ceraolo Spurio
` (3 preceding siblings ...)
2017-10-02 23:00 ` [RFC i-g-t 4/6] tests/gem_stolen: drop gem_stolen.c Daniele Ceraolo Spurio
@ 2017-10-02 23:00 ` Daniele Ceraolo Spurio
2017-10-03 11:11 ` Chris Wilson
2017-10-02 23:00 ` [RFC i-g-t 6/6] lib/ioctl_wrappers: drop stolen memory related wrappers Daniele Ceraolo Spurio
` (3 subsequent siblings)
8 siblings, 1 reply; 22+ messages in thread
From: Daniele Ceraolo Spurio @ 2017-10-02 23:00 UTC (permalink / raw)
To: intel-gfx
The feature was never merged and there has been no progress in the
last year. The tests are currently excluded from compilation with and
ifdef.
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
---
tests/gem_concurrent_all.c | 35 -----------------------------------
1 file changed, 35 deletions(-)
diff --git a/tests/gem_concurrent_all.c b/tests/gem_concurrent_all.c
index 201b491..87f2129 100644
--- a/tests/gem_concurrent_all.c
+++ b/tests/gem_concurrent_all.c
@@ -170,36 +170,6 @@ static void can_create_private(const struct create *create, unsigned count)
}
#endif
-#if HAVE_CREATE_STOLEN
-static drm_intel_bo *
-create_stolen_bo(drm_intel_bufmgr *bufmgr, uint64_t size)
-{
- drm_intel_bo *bo;
- uint32_t handle;
-
- /* XXX gem_create_with_flags(fd, size, I915_CREATE_STOLEN); */
-
- handle = gem_create(fd, size);
- bo = gem_handle_to_libdrm_bo(bufmgr, fd, "stolen", handle);
- gem_close(fd, handle);
-
- return bo;
-}
-
-static void can_create_stolen(const struct create *create, unsigned count)
-{
- /* XXX check num_buffers against available stolen */
- igt_require(0);
-}
-#endif
-
-static void create_cpu_require(const struct create *create, unsigned count)
-{
-#if HAVE_CREATE_STOLEN
- igt_require(create->create != create_stolen_bo);
-#endif
-}
-
static drm_intel_bo *
unmapped_create_bo(const struct buffers *b)
{
@@ -208,7 +178,6 @@ unmapped_create_bo(const struct buffers *b)
static void create_snoop_require(const struct create *create, unsigned count)
{
- create_cpu_require(create, count);
igt_require(!gem_has_llc(fd));
}
@@ -1727,7 +1696,6 @@ igt_main
{
.name = "cpu",
.create_bo = unmapped_create_bo,
- .require = create_cpu_require,
.set_bo = cpu_set_bo,
.cmp_bo = cpu_cmp_bo,
.release_bo = nop_release_bo,
@@ -1807,9 +1775,6 @@ igt_main
#if HAVE_CREATE_PRIVATE
{ "private-", can_create_private, create_private_bo},
#endif
-#if HAVE_CREATE_STOLEN
- { "stolen-", can_create_stolen, create_stolen_bo},
-#endif
{ NULL, NULL }
};
const struct size sizes[] = {
--
1.9.1
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 22+ messages in thread* Re: [RFC i-g-t 5/6] tests/gem_concurrent_all: drop stolen memory related subtests
2017-10-02 23:00 ` [RFC i-g-t 5/6] tests/gem_concurrent_all: drop stolen memory related subtests Daniele Ceraolo Spurio
@ 2017-10-03 11:11 ` Chris Wilson
2017-10-03 16:14 ` Daniele Ceraolo Spurio
0 siblings, 1 reply; 22+ messages in thread
From: Chris Wilson @ 2017-10-03 11:11 UTC (permalink / raw)
To: Daniele Ceraolo Spurio, intel-gfx
Quoting Daniele Ceraolo Spurio (2017-10-03 00:00:17)
> The feature was never merged and there has been no progress in the
> last year. The tests are currently excluded from compilation with and
> ifdef.
>
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
> Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
> ---
> tests/gem_concurrent_all.c | 35 -----------------------------------
> 1 file changed, 35 deletions(-)
>
> diff --git a/tests/gem_concurrent_all.c b/tests/gem_concurrent_all.c
> index 201b491..87f2129 100644
> --- a/tests/gem_concurrent_all.c
> +++ b/tests/gem_concurrent_all.c
> @@ -170,36 +170,6 @@ static void can_create_private(const struct create *create, unsigned count)
> }
> #endif
>
> -#if HAVE_CREATE_STOLEN
> -static drm_intel_bo *
> -create_stolen_bo(drm_intel_bufmgr *bufmgr, uint64_t size)
> -{
> - drm_intel_bo *bo;
> - uint32_t handle;
> -
> - /* XXX gem_create_with_flags(fd, size, I915_CREATE_STOLEN); */
> -
> - handle = gem_create(fd, size);
> - bo = gem_handle_to_libdrm_bo(bufmgr, fd, "stolen", handle);
> - gem_close(fd, handle);
> -
> - return bo;
> -}
> -
> -static void can_create_stolen(const struct create *create, unsigned count)
> -{
> - /* XXX check num_buffers against available stolen */
> - igt_require(0);
> -}
> -#endif
> -
> -static void create_cpu_require(const struct create *create, unsigned count)
> -{
> -#if HAVE_CREATE_STOLEN
> - igt_require(create->create != create_stolen_bo);
> -#endif
> -}
> -
> static drm_intel_bo *
> unmapped_create_bo(const struct buffers *b)
> {
> @@ -208,7 +178,6 @@ unmapped_create_bo(const struct buffers *b)
>
> static void create_snoop_require(const struct create *create, unsigned count)
> {
> - create_cpu_require(create, count);
Pardon? It's about being descriptive of the requirements, for the snooping code paths,
the bo must be cpu accessible.
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 22+ messages in thread* Re: [RFC i-g-t 5/6] tests/gem_concurrent_all: drop stolen memory related subtests
2017-10-03 11:11 ` Chris Wilson
@ 2017-10-03 16:14 ` Daniele Ceraolo Spurio
2017-10-03 16:25 ` Chris Wilson
0 siblings, 1 reply; 22+ messages in thread
From: Daniele Ceraolo Spurio @ 2017-10-03 16:14 UTC (permalink / raw)
To: Chris Wilson, intel-gfx
On 03/10/17 04:11, Chris Wilson wrote:
> Quoting Daniele Ceraolo Spurio (2017-10-03 00:00:17)
>> The feature was never merged and there has been no progress in the
>> last year. The tests are currently excluded from compilation with and
>> ifdef.
>>
>> Cc: Chris Wilson <chris@chris-wilson.co.uk>
>> Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
>> ---
>> tests/gem_concurrent_all.c | 35 -----------------------------------
>> 1 file changed, 35 deletions(-)
>>
>> diff --git a/tests/gem_concurrent_all.c b/tests/gem_concurrent_all.c
>> index 201b491..87f2129 100644
>> --- a/tests/gem_concurrent_all.c
>> +++ b/tests/gem_concurrent_all.c
>> @@ -170,36 +170,6 @@ static void can_create_private(const struct create *create, unsigned count)
>> }
>> #endif
>>
>> -#if HAVE_CREATE_STOLEN
>> -static drm_intel_bo *
>> -create_stolen_bo(drm_intel_bufmgr *bufmgr, uint64_t size)
>> -{
>> - drm_intel_bo *bo;
>> - uint32_t handle;
>> -
>> - /* XXX gem_create_with_flags(fd, size, I915_CREATE_STOLEN); */
>> -
>> - handle = gem_create(fd, size);
>> - bo = gem_handle_to_libdrm_bo(bufmgr, fd, "stolen", handle);
>> - gem_close(fd, handle);
>> -
>> - return bo;
>> -}
>> -
>> -static void can_create_stolen(const struct create *create, unsigned count)
>> -{
>> - /* XXX check num_buffers against available stolen */
>> - igt_require(0);
>> -}
>> -#endif
>> -
>> -static void create_cpu_require(const struct create *create, unsigned count)
>> -{
>> -#if HAVE_CREATE_STOLEN
>> - igt_require(create->create != create_stolen_bo);
>> -#endif
>> -}
>> -
>> static drm_intel_bo *
>> unmapped_create_bo(const struct buffers *b)
>> {
>> @@ -208,7 +178,6 @@ unmapped_create_bo(const struct buffers *b)
>>
>> static void create_snoop_require(const struct create *create, unsigned count)
>> {
>> - create_cpu_require(create, count);
>
> Pardon? It's about being descriptive of the requirements, for the snooping code paths,
> the bo must be cpu accessible.
> -Chris
>
Would it be ok for you to just leave create_cpu_require() as an empty
function or do you have something else in mind?
Thanks,
Daniele
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 22+ messages in thread* Re: [RFC i-g-t 5/6] tests/gem_concurrent_all: drop stolen memory related subtests
2017-10-03 16:14 ` Daniele Ceraolo Spurio
@ 2017-10-03 16:25 ` Chris Wilson
0 siblings, 0 replies; 22+ messages in thread
From: Chris Wilson @ 2017-10-03 16:25 UTC (permalink / raw)
To: Daniele Ceraolo Spurio, intel-gfx
Quoting Daniele Ceraolo Spurio (2017-10-03 17:14:21)
>
>
> On 03/10/17 04:11, Chris Wilson wrote:
> > Quoting Daniele Ceraolo Spurio (2017-10-03 00:00:17)
> >> The feature was never merged and there has been no progress in the
> >> last year. The tests are currently excluded from compilation with and
> >> ifdef.
> >>
> >> Cc: Chris Wilson <chris@chris-wilson.co.uk>
> >> Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
> >> ---
> >> tests/gem_concurrent_all.c | 35 -----------------------------------
> >> 1 file changed, 35 deletions(-)
> >>
> >> diff --git a/tests/gem_concurrent_all.c b/tests/gem_concurrent_all.c
> >> index 201b491..87f2129 100644
> >> --- a/tests/gem_concurrent_all.c
> >> +++ b/tests/gem_concurrent_all.c
> >> @@ -170,36 +170,6 @@ static void can_create_private(const struct create *create, unsigned count)
> >> }
> >> #endif
> >>
> >> -#if HAVE_CREATE_STOLEN
> >> -static drm_intel_bo *
> >> -create_stolen_bo(drm_intel_bufmgr *bufmgr, uint64_t size)
> >> -{
> >> - drm_intel_bo *bo;
> >> - uint32_t handle;
> >> -
> >> - /* XXX gem_create_with_flags(fd, size, I915_CREATE_STOLEN); */
> >> -
> >> - handle = gem_create(fd, size);
> >> - bo = gem_handle_to_libdrm_bo(bufmgr, fd, "stolen", handle);
> >> - gem_close(fd, handle);
> >> -
> >> - return bo;
> >> -}
> >> -
> >> -static void can_create_stolen(const struct create *create, unsigned count)
> >> -{
> >> - /* XXX check num_buffers against available stolen */
> >> - igt_require(0);
> >> -}
> >> -#endif
> >> -
> >> -static void create_cpu_require(const struct create *create, unsigned count)
> >> -{
> >> -#if HAVE_CREATE_STOLEN
> >> - igt_require(create->create != create_stolen_bo);
> >> -#endif
> >> -}
> >> -
> >> static drm_intel_bo *
> >> unmapped_create_bo(const struct buffers *b)
> >> {
> >> @@ -208,7 +178,6 @@ unmapped_create_bo(const struct buffers *b)
> >>
> >> static void create_snoop_require(const struct create *create, unsigned count)
> >> {
> >> - create_cpu_require(create, count);
> >
> > Pardon? It's about being descriptive of the requirements, for the snooping code paths,
> > the bo must be cpu accessible.
> > -Chris
> >
>
> Would it be ok for you to just leave create_cpu_require() as an empty
> function or do you have something else in mind?
Leave it as empty. It's primary purpose is a placeholder for
restrictions as they come to light.
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 22+ messages in thread
* [RFC i-g-t 6/6] lib/ioctl_wrappers: drop stolen memory related wrappers
2017-10-02 23:00 [RFC i-g-t 0/6] Drop tests for object creation from stolen Daniele Ceraolo Spurio
` (4 preceding siblings ...)
2017-10-02 23:00 ` [RFC i-g-t 5/6] tests/gem_concurrent_all: drop stolen memory related subtests Daniele Ceraolo Spurio
@ 2017-10-02 23:00 ` Daniele Ceraolo Spurio
2017-10-02 23:37 ` ✓ Fi.CI.BAT: success for Drop tests for object creation from stolen Patchwork
` (2 subsequent siblings)
8 siblings, 0 replies; 22+ messages in thread
From: Daniele Ceraolo Spurio @ 2017-10-02 23:00 UTC (permalink / raw)
To: intel-gfx
The feature was never merged and there has been no progress in the
last year. The wrappers are using a wrong ioctl number (38 is
HAS_POOLED_EU and not CREATE_VERSION) and extensions of the
gem_create and get_aperture ioctl structures that never made it into
the kernel.
Tests that were using the wrappers have already been removed by previous
patches so it is now safe to remove the wrappers themselves.
Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
---
lib/ioctl_wrappers.c | 119 ---------------------------------------------------
lib/ioctl_wrappers.h | 16 -------
2 files changed, 135 deletions(-)
diff --git a/lib/ioctl_wrappers.c b/lib/ioctl_wrappers.c
index 51b6b7b..fdf6cc5 100644
--- a/lib/ioctl_wrappers.c
+++ b/lib/ioctl_wrappers.c
@@ -479,79 +479,6 @@ void gem_sync(int fd, uint32_t handle)
errno = 0;
}
-
-bool gem_create__has_stolen_support(int fd)
-{
- static int has_stolen_support = -1;
- struct drm_i915_getparam gp;
- int val = -1;
-
- if (has_stolen_support < 0) {
- memset(&gp, 0, sizeof(gp));
- gp.param = 38; /* CREATE_VERSION */
- gp.value = &val;
-
- /* Do we have the extended gem_create_ioctl? */
- ioctl(fd, DRM_IOCTL_I915_GETPARAM, &gp);
- has_stolen_support = val >= 2;
- }
-
- return has_stolen_support;
-}
-
-struct local_i915_gem_create_v2 {
- uint64_t size;
- uint32_t handle;
- uint32_t pad;
-#define I915_CREATE_PLACEMENT_STOLEN (1<<0)
- uint32_t flags;
-};
-
-#define LOCAL_IOCTL_I915_GEM_CREATE DRM_IOWR(DRM_COMMAND_BASE + DRM_I915_GEM_CREATE, struct local_i915_gem_create_v2)
-uint32_t __gem_create_stolen(int fd, uint64_t size)
-{
- struct local_i915_gem_create_v2 create;
- int ret;
-
- memset(&create, 0, sizeof(create));
- create.handle = 0;
- create.size = size;
- create.flags = I915_CREATE_PLACEMENT_STOLEN;
- ret = igt_ioctl(fd, LOCAL_IOCTL_I915_GEM_CREATE, &create);
-
- if (ret < 0)
- return 0;
-
- errno = 0;
- return create.handle;
-}
-
-/**
- * gem_create_stolen:
- * @fd: open i915 drm file descriptor
- * @size: desired size of the buffer
- *
- * This wraps the new GEM_CREATE ioctl, which allocates a new gem buffer
- * object of @size and placement in stolen memory region.
- *
- * Returns: The file-private handle of the created buffer object
- */
-
-uint32_t gem_create_stolen(int fd, uint64_t size)
-{
- struct local_i915_gem_create_v2 create;
-
- memset(&create, 0, sizeof(create));
- create.handle = 0;
- create.size = size;
- create.flags = I915_CREATE_PLACEMENT_STOLEN;
- do_ioctl(fd, LOCAL_IOCTL_I915_GEM_CREATE, &create);
- igt_assert(create.handle);
-
- return create.handle;
-}
-
-
uint32_t __gem_create(int fd, int size)
{
struct drm_i915_gem_create create;
@@ -1378,52 +1305,6 @@ bool gem_has_bsd2(int fd)
has_bsd2 = has_param(fd, LOCAL_I915_PARAM_HAS_BSD2);
return has_bsd2;
}
-
-struct local_i915_gem_get_aperture {
- __u64 aper_size;
- __u64 aper_available_size;
- __u64 version;
- __u64 map_total_size;
- __u64 stolen_total_size;
-};
-#define DRM_I915_GEM_GET_APERTURE 0x23
-#define LOCAL_IOCTL_I915_GEM_GET_APERTURE DRM_IOR (DRM_COMMAND_BASE + DRM_I915_GEM_GET_APERTURE, struct local_i915_gem_get_aperture)
-/**
- * gem_total_mappable_size:
- * @fd: open i915 drm file descriptor
- *
- * Feature test macro to query the kernel for the total mappable size.
- *
- * Returns: Total mappable address space size.
- */
-uint64_t gem_total_mappable_size(int fd)
-{
- struct local_i915_gem_get_aperture aperture;
-
- memset(&aperture, 0, sizeof(aperture));
- do_ioctl(fd, LOCAL_IOCTL_I915_GEM_GET_APERTURE, &aperture);
-
- return aperture.map_total_size;
-}
-
-/**
- * gem_total_stolen_size:
- * @fd: open i915 drm file descriptor
- *
- * Feature test macro to query the kernel for the total stolen size.
- *
- * Returns: Total stolen memory.
- */
-uint64_t gem_total_stolen_size(int fd)
-{
- struct local_i915_gem_get_aperture aperture;
-
- memset(&aperture, 0, sizeof(aperture));
- do_ioctl(fd, LOCAL_IOCTL_I915_GEM_GET_APERTURE, &aperture);
-
- return aperture.stolen_total_size;
-}
-
/**
* gem_available_aperture_size:
* @fd: open i915 drm file descriptor
diff --git a/lib/ioctl_wrappers.h b/lib/ioctl_wrappers.h
index 090c125..008747a 100644
--- a/lib/ioctl_wrappers.h
+++ b/lib/ioctl_wrappers.h
@@ -70,9 +70,6 @@ int __gem_set_domain(int fd, uint32_t handle, uint32_t read, uint32_t write);
void gem_set_domain(int fd, uint32_t handle, uint32_t read, uint32_t write);
int gem_wait(int fd, uint32_t handle, int64_t *timeout_ns);
void gem_sync(int fd, uint32_t handle);
-bool gem_create__has_stolen_support(int fd);
-uint32_t __gem_create_stolen(int fd, uint64_t size);
-uint32_t gem_create_stolen(int fd, uint64_t size);
uint32_t __gem_create(int fd, int size);
uint32_t gem_create(int fd, uint64_t size);
void gem_execbuf_wr(int fd, struct drm_i915_gem_execbuffer2 *execbuf);
@@ -97,17 +94,6 @@ void *__gem_mmap__wc(int fd, uint32_t handle, uint64_t offset, uint64_t size, un
int gem_munmap(void *ptr, uint64_t size);
/**
- * gem_require_stolen_support:
- * @fd: open i915 drm file descriptor
- *
- * Test macro to query whether support for allocating objects from stolen
- * memory is available. Automatically skips through igt_require() if not.
- */
-#define gem_require_stolen_support(fd) \
- igt_require(gem_create__has_stolen_support(fd) && \
- (gem_total_stolen_size(fd) > 0))
-
-/**
* gem_require_mmap_wc:
* @fd: open i915 drm file descriptor
*
@@ -171,8 +157,6 @@ int gem_gpu_reset_type(int fd);
bool gem_gpu_reset_enabled(int fd);
bool gem_engine_reset_enabled(int fd);
int gem_available_fences(int fd);
-uint64_t gem_total_mappable_size(int fd);
-uint64_t gem_total_stolen_size(int fd);
uint64_t gem_available_aperture_size(int fd);
uint64_t gem_aperture_size(int fd);
uint64_t gem_global_aperture_size(int fd);
--
1.9.1
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 22+ messages in thread* ✓ Fi.CI.BAT: success for Drop tests for object creation from stolen
2017-10-02 23:00 [RFC i-g-t 0/6] Drop tests for object creation from stolen Daniele Ceraolo Spurio
` (5 preceding siblings ...)
2017-10-02 23:00 ` [RFC i-g-t 6/6] lib/ioctl_wrappers: drop stolen memory related wrappers Daniele Ceraolo Spurio
@ 2017-10-02 23:37 ` Patchwork
2017-10-03 0:30 ` ✓ Fi.CI.IGT: " Patchwork
2017-10-03 8:31 ` [RFC i-g-t 0/6] " Daniel Vetter
8 siblings, 0 replies; 22+ messages in thread
From: Patchwork @ 2017-10-02 23:37 UTC (permalink / raw)
To: Daniele Ceraolo Spurio; +Cc: intel-gfx
== Series Details ==
Series: Drop tests for object creation from stolen
URL : https://patchwork.freedesktop.org/series/31290/
State : success
== Summary ==
IGT patchset tested on top of latest successful build
b5404f8435f828ca039a2e46be629b3d4c92465b meson: Follow suit with the renaming of kms_pipe_color
with latest DRM-Tip kernel build CI_DRM_3163
14f3207683e1 drm-tip: 2017y-10m-02d-20h-23m-38s UTC integration manifest
Testlist changes:
-igt@gem_create@stolen-invalid-flag
-igt@gem_pread@pagefault-pread
-igt@gem_pread@stolen-display
-igt@gem_pread@stolen-normal
-igt@gem_pread@stolen-snoop
-igt@gem_pread@stolen-uncached
-igt@gem_pwrite@stolen-display
-igt@gem_pwrite@stolen-normal
-igt@gem_pwrite@stolen-snoop
-igt@gem_pwrite@stolen-uncached
-igt@gem_stolen@large-object-alloc
-igt@gem_stolen@stolen-clear
-igt@gem_stolen@stolen-copy
-igt@gem_stolen@stolen-fill-purge
-igt@gem_stolen@stolen-hibernate
-igt@gem_stolen@stolen-no-mmap
-igt@gem_stolen@stolen-pread
-igt@gem_stolen@stolen-pwrite
fi-bdw-5557u total:289 pass:268 dwarn:0 dfail:0 fail:0 skip:21 time:458s
fi-bdw-gvtdvm total:289 pass:265 dwarn:0 dfail:0 fail:0 skip:24 time:472s
fi-blb-e6850 total:289 pass:224 dwarn:1 dfail:0 fail:0 skip:64 time:391s
fi-bsw-n3050 total:289 pass:243 dwarn:0 dfail:0 fail:0 skip:46 time:585s
fi-bwr-2160 total:289 pass:184 dwarn:0 dfail:0 fail:0 skip:105 time:291s
fi-bxt-dsi total:289 pass:259 dwarn:0 dfail:0 fail:0 skip:30 time:532s
fi-bxt-j4205 total:289 pass:260 dwarn:0 dfail:0 fail:0 skip:29 time:533s
fi-byt-j1900 total:289 pass:254 dwarn:1 dfail:0 fail:0 skip:34 time:555s
fi-byt-n2820 total:289 pass:250 dwarn:1 dfail:0 fail:0 skip:38 time:546s
fi-cfl-s total:289 pass:256 dwarn:1 dfail:0 fail:0 skip:32 time:567s
fi-cnl-y total:289 pass:261 dwarn:1 dfail:0 fail:0 skip:27 time:639s
fi-elk-e7500 total:289 pass:230 dwarn:0 dfail:0 fail:0 skip:59 time:441s
fi-glk-1 total:289 pass:258 dwarn:3 dfail:0 fail:0 skip:28 time:597s
fi-hsw-4770 total:289 pass:263 dwarn:0 dfail:0 fail:0 skip:26 time:442s
fi-hsw-4770r total:289 pass:263 dwarn:0 dfail:0 fail:0 skip:26 time:423s
fi-ilk-650 total:289 pass:229 dwarn:0 dfail:0 fail:0 skip:60 time:462s
fi-ivb-3520m total:289 pass:261 dwarn:0 dfail:0 fail:0 skip:28 time:505s
fi-ivb-3770 total:289 pass:261 dwarn:0 dfail:0 fail:0 skip:28 time:480s
fi-kbl-7500u total:289 pass:264 dwarn:1 dfail:0 fail:0 skip:24 time:509s
fi-kbl-7560u total:289 pass:270 dwarn:0 dfail:0 fail:0 skip:19 time:582s
fi-kbl-7567u total:289 pass:265 dwarn:4 dfail:0 fail:0 skip:20 time:491s
fi-kbl-r total:289 pass:262 dwarn:0 dfail:0 fail:0 skip:27 time:595s
fi-pnv-d510 total:289 pass:223 dwarn:1 dfail:0 fail:0 skip:65 time:661s
fi-skl-6260u total:289 pass:269 dwarn:0 dfail:0 fail:0 skip:20 time:499s
fi-skl-6700k total:289 pass:265 dwarn:0 dfail:0 fail:0 skip:24 time:537s
fi-skl-6770hq total:289 pass:269 dwarn:0 dfail:0 fail:0 skip:20 time:522s
fi-skl-gvtdvm total:289 pass:266 dwarn:0 dfail:0 fail:0 skip:23 time:479s
fi-snb-2520m total:289 pass:251 dwarn:0 dfail:0 fail:0 skip:38 time:593s
fi-snb-2600 total:289 pass:250 dwarn:0 dfail:0 fail:0 skip:39 time:446s
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_283/
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 22+ messages in thread* ✓ Fi.CI.IGT: success for Drop tests for object creation from stolen
2017-10-02 23:00 [RFC i-g-t 0/6] Drop tests for object creation from stolen Daniele Ceraolo Spurio
` (6 preceding siblings ...)
2017-10-02 23:37 ` ✓ Fi.CI.BAT: success for Drop tests for object creation from stolen Patchwork
@ 2017-10-03 0:30 ` Patchwork
2017-10-03 8:31 ` [RFC i-g-t 0/6] " Daniel Vetter
8 siblings, 0 replies; 22+ messages in thread
From: Patchwork @ 2017-10-03 0:30 UTC (permalink / raw)
To: Daniele Ceraolo Spurio; +Cc: intel-gfx
== Series Details ==
Series: Drop tests for object creation from stolen
URL : https://patchwork.freedesktop.org/series/31290/
State : success
== Summary ==
Test perf:
Subgroup blocking:
fail -> PASS (shard-hsw) fdo#102252
Test kms_flip:
Subgroup flip-vs-absolute-wf_vblank:
pass -> FAIL (shard-hsw) fdo#100368
Subgroup wf_vblank-vs-dpms-interruptible:
dmesg-warn -> PASS (shard-hsw)
fdo#102252 https://bugs.freedesktop.org/show_bug.cgi?id=102252
fdo#100368 https://bugs.freedesktop.org/show_bug.cgi?id=100368
shard-hsw total:2412 pass:1331 dwarn:7 dfail:0 fail:8 skip:1066 time:10058s
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_283/shards.html
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 22+ messages in thread* Re: [RFC i-g-t 0/6] Drop tests for object creation from stolen
2017-10-02 23:00 [RFC i-g-t 0/6] Drop tests for object creation from stolen Daniele Ceraolo Spurio
` (7 preceding siblings ...)
2017-10-03 0:30 ` ✓ Fi.CI.IGT: " Patchwork
@ 2017-10-03 8:31 ` Daniel Vetter
2017-10-03 9:30 ` Petri Latvala
2017-10-03 11:09 ` Joonas Lahtinen
8 siblings, 2 replies; 22+ messages in thread
From: Daniel Vetter @ 2017-10-03 8:31 UTC (permalink / raw)
To: Daniele Ceraolo Spurio; +Cc: Ankitprasad Sharma, intel-gfx
On Mon, Oct 02, 2017 at 04:00:12PM -0700, Daniele Ceraolo Spurio wrote:
> The tests were merged before the feature, which never made it to the
> driver; the last update I could find ([1]) is more than a year old.
> The tests are using a wrong getparam number and planned extensions
> to the gem_create and get_aperture ioctl structures that don't match
> what's currently in i915. Due to this all stolen-related subtests are
> skipping.
> Given the fact that there has been no traction behind the feature for
> a long time it doesn't look like we'll need those tests anytime soon
> and thus it makes sense to remove them.
>
> The patches didn't revert cleanly and also contained some improvements
> that are worth keeping, so instead of a revert I've organized the removal
> in a single patch per test file to drop only the unneeded code.
>
> [1] https://patchwork.freedesktop.org/series/659/
>
> Cc: Ankitprasad Sharma <ankitprasad.r.sharma@intel.com>
> Cc: Petri Latvala <petri.latvala@intel.com>
> Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
Ack from my side on the entire series. Merging stuff before the kernel
side has landed is a good way to piss of Dave Airlie. Yes CI right now
doesn't support testing both a kernel and an igt branch at the same time,
so not that useful for testing new features. It's on the list, but then CI
is primarily about preventing regressions, not so much about making sure
new stuff works perfectly out of the box (would be good too ofc).
-Daniel
>
> Daniele Ceraolo Spurio (6):
> tests/gem_pread: drop stolen memory related subtests
> tests/gem_pwrite: drop stolen memory related subtests
> tests/gem_create: drop stolen memory related subtest
> tests/gem_stolen: drop gem_stolen.c
> tests/gem_concurrent_all: drop stolen memory related subtests
> lib/ioctl_wrappers: drop stolen memory related wrappers
>
> lib/ioctl_wrappers.c | 119 ------------
> lib/ioctl_wrappers.h | 16 --
> tests/Makefile.sources | 1 -
> tests/gem_concurrent_all.c | 35 ----
> tests/gem_create.c | 37 +---
> tests/gem_pread.c | 95 ----------
> tests/gem_pwrite.c | 43 -----
> tests/gem_stolen.c | 455 ---------------------------------------------
> 8 files changed, 2 insertions(+), 799 deletions(-)
> delete mode 100644 tests/gem_stolen.c
>
> --
> 1.9.1
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
--
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 22+ messages in thread* Re: [RFC i-g-t 0/6] Drop tests for object creation from stolen
2017-10-03 8:31 ` [RFC i-g-t 0/6] " Daniel Vetter
@ 2017-10-03 9:30 ` Petri Latvala
2017-10-03 11:11 ` Tvrtko Ursulin
2017-10-03 11:09 ` Joonas Lahtinen
1 sibling, 1 reply; 22+ messages in thread
From: Petri Latvala @ 2017-10-03 9:30 UTC (permalink / raw)
To: Daniele Ceraolo Spurio, joonas.lahtinen; +Cc: Ankitprasad Sharma, intel-gfx
On Tue, Oct 03, 2017 at 10:31:10AM +0200, Daniel Vetter wrote:
> On Mon, Oct 02, 2017 at 04:00:12PM -0700, Daniele Ceraolo Spurio wrote:
> > The tests were merged before the feature, which never made it to the
> > driver; the last update I could find ([1]) is more than a year old.
> > The tests are using a wrong getparam number and planned extensions
> > to the gem_create and get_aperture ioctl structures that don't match
> > what's currently in i915. Due to this all stolen-related subtests are
> > skipping.
> > Given the fact that there has been no traction behind the feature for
> > a long time it doesn't look like we'll need those tests anytime soon
> > and thus it makes sense to remove them.
> >
> > The patches didn't revert cleanly and also contained some improvements
> > that are worth keeping, so instead of a revert I've organized the removal
> > in a single patch per test file to drop only the unneeded code.
> >
> > [1] https://patchwork.freedesktop.org/series/659/
> >
> > Cc: Ankitprasad Sharma <ankitprasad.r.sharma@intel.com>
> > Cc: Petri Latvala <petri.latvala@intel.com>
> > Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
> > Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> > Cc: Chris Wilson <chris@chris-wilson.co.uk>
>
> Ack from my side on the entire series. Merging stuff before the kernel
> side has landed is a good way to piss of Dave Airlie. Yes CI right now
> doesn't support testing both a kernel and an igt branch at the same time,
> so not that useful for testing new features. It's on the list, but then CI
> is primarily about preventing regressions, not so much about making sure
> new stuff works perfectly out of the box (would be good too ofc).
Series is
Acked-by: Petri Latvala <petri.latvala@intel.com>
as well, with an addition posted separately to patch 4. GEM people
could give their blessing as well before landing this, Joonas?
--
Petri Latvala
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: [RFC i-g-t 0/6] Drop tests for object creation from stolen
2017-10-03 9:30 ` Petri Latvala
@ 2017-10-03 11:11 ` Tvrtko Ursulin
0 siblings, 0 replies; 22+ messages in thread
From: Tvrtko Ursulin @ 2017-10-03 11:11 UTC (permalink / raw)
To: Petri Latvala, Daniele Ceraolo Spurio, joonas.lahtinen
Cc: Ankitprasad Sharma, intel-gfx
On 03/10/2017 10:30, Petri Latvala wrote:
> On Tue, Oct 03, 2017 at 10:31:10AM +0200, Daniel Vetter wrote:
>> On Mon, Oct 02, 2017 at 04:00:12PM -0700, Daniele Ceraolo Spurio wrote:
>>> The tests were merged before the feature, which never made it to the
>>> driver; the last update I could find ([1]) is more than a year old.
>>> The tests are using a wrong getparam number and planned extensions
>>> to the gem_create and get_aperture ioctl structures that don't match
>>> what's currently in i915. Due to this all stolen-related subtests are
>>> skipping.
>>> Given the fact that there has been no traction behind the feature for
>>> a long time it doesn't look like we'll need those tests anytime soon
>>> and thus it makes sense to remove them.
>>>
>>> The patches didn't revert cleanly and also contained some improvements
>>> that are worth keeping, so instead of a revert I've organized the removal
>>> in a single patch per test file to drop only the unneeded code.
>>>
>>> [1] https://patchwork.freedesktop.org/series/659/
>>>
>>> Cc: Ankitprasad Sharma <ankitprasad.r.sharma@intel.com>
>>> Cc: Petri Latvala <petri.latvala@intel.com>
>>> Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
>>> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
>>> Cc: Chris Wilson <chris@chris-wilson.co.uk>
>>
>> Ack from my side on the entire series. Merging stuff before the kernel
>> side has landed is a good way to piss of Dave Airlie. Yes CI right now
>> doesn't support testing both a kernel and an igt branch at the same time,
>> so not that useful for testing new features. It's on the list, but then CI
>> is primarily about preventing regressions, not so much about making sure
>> new stuff works perfectly out of the box (would be good too ofc).
>
> Series is
> Acked-by: Petri Latvala <petri.latvala@intel.com>
> as well, with an addition posted separately to patch 4. GEM people
> could give their blessing as well before landing this, Joonas?
Acked-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Regards,
Tvrtko
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: [RFC i-g-t 0/6] Drop tests for object creation from stolen
2017-10-03 8:31 ` [RFC i-g-t 0/6] " Daniel Vetter
2017-10-03 9:30 ` Petri Latvala
@ 2017-10-03 11:09 ` Joonas Lahtinen
1 sibling, 0 replies; 22+ messages in thread
From: Joonas Lahtinen @ 2017-10-03 11:09 UTC (permalink / raw)
To: Daniel Vetter, Daniele Ceraolo Spurio, Chris Wilson
Cc: Ankitprasad Sharma, intel-gfx
On Tue, 2017-10-03 at 10:31 +0200, Daniel Vetter wrote:
> On Mon, Oct 02, 2017 at 04:00:12PM -0700, Daniele Ceraolo Spurio wrote:
> > The tests were merged before the feature, which never made it to the
> > driver; the last update I could find ([1]) is more than a year old.
> > The tests are using a wrong getparam number and planned extensions
> > to the gem_create and get_aperture ioctl structures that don't match
> > what's currently in i915. Due to this all stolen-related subtests are
> > skipping.
> > Given the fact that there has been no traction behind the feature for
> > a long time it doesn't look like we'll need those tests anytime soon
> > and thus it makes sense to remove them.
> >
> > The patches didn't revert cleanly and also contained some improvements
> > that are worth keeping, so instead of a revert I've organized the removal
> > in a single patch per test file to drop only the unneeded code.
> >
> > [1] https://patchwork.freedesktop.org/series/659/
> >
> > Cc: Ankitprasad Sharma <ankitprasad.r.sharma@intel.com>
> > Cc: Petri Latvala <petri.latvala@intel.com>
> > Cc: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
> > Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> > Cc: Chris Wilson <chris@chris-wilson.co.uk>
>
> Ack from my side on the entire series. Merging stuff before the kernel
> side has landed is a good way to piss of Dave Airlie. Yes CI right now
> doesn't support testing both a kernel and an igt branch at the same time,
> so not that useful for testing new features. It's on the list, but then CI
> is primarily about preventing regressions, not so much about making sure
> new stuff works perfectly out of the box (would be good too ofc).
We can always bother Tomi/Arek to make a special run, but all that time
could be spent on adding the support for something along the lines
of "Depends-on: patchwork.freedesktop.org/XYZ"
Anyway this is,
Acked-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
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
^ permalink raw reply [flat|nested] 22+ messages in thread