* [igt-dev] [PATCH i-g-t] Revert "tests/amdgpu: Add test for ODM combine"
@ 2023-08-22 20:31 Kamil Konieczny
2023-08-22 20:46 ` Aurabindo Pillai
2023-08-22 23:04 ` [igt-dev] ✗ Fi.CI.BUILD: failure for " Patchwork
0 siblings, 2 replies; 5+ messages in thread
From: Kamil Konieczny @ 2023-08-22 20:31 UTC (permalink / raw)
To: igt-dev
This reverts commit a609e0493580c9626fd93dabcf417a41640dcd58.
This commit breaks compilation on debian images in GitLab CI:
build:tests-debian-meson has failed (https://gitlab.freedesktop.org/gfx-ci/igt-ci-tags/-/jobs/47853345):
^~~~~~~~
/usr/include/xf86drmMode.h:533:2: error: unknown type name ‘uint32_t’
uint32_t lessees[0];
^~~~~~~~
/usr/include/xf86drmMode.h:539:2: error: unknown type name ‘uint32_t’
uint32_t count;
^~~~~~~~
Instead of including <xf86drmMode.h> in test, there should be
used igt_kms.h library or added <stdint.h>.
Cc: Aurabindo Pillai <aurabindo.pillai@amd.com>
Cc: Petri Latvala <adrinael@adrinael.net>
Cc: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
Cc: Ashutosh Dixit <ashutosh.dixit@intel.com>
Signed-off-by: Kamil Konieczny <kamil.konieczny@linux.intel.com>
---
tests/amdgpu/amd_odm.c | 189 ---------------------------------------
tests/amdgpu/meson.build | 1 -
2 files changed, 190 deletions(-)
delete mode 100644 tests/amdgpu/amd_odm.c
diff --git a/tests/amdgpu/amd_odm.c b/tests/amdgpu/amd_odm.c
deleted file mode 100644
index 2781ad1c2..000000000
--- a/tests/amdgpu/amd_odm.c
+++ /dev/null
@@ -1,189 +0,0 @@
-// SPDX-License-Identifier: MIT
-/*
- * Copyrights 2023 Advanced Micro Devices, Inc.
- */
-
-#include <fcntl.h>
-#include <stdio.h>
-#include <xf86drmMode.h>
-
-#include "igt.h"
-#include "igt_amd.h"
-#include "igt_edid.h"
-
-IGT_TEST_DESCRIPTION("Test whether ODM Combine mode is triggered when timings with high refresh "
- "rate is committed");
-
-enum odmc_mode {
- ODMC_2_TO_1,
- ODMC_4_TO_1,
-};
-
-/* Common test data. */
-struct data {
- igt_display_t display;
- igt_plane_t *primary;
- igt_output_t *output;
- igt_pipe_t *pipe;
- drmModeModeInfoPtr mode;
- enum pipe pipe_id;
- int fd;
-};
-
-static const drmModeModeInfo test_mode[] = {
- { 1278720,
- 3840, 3952, 3984, 4000, 0,
- 2160, 2210, 2215, 2220, 0,
- 30,
- DRM_MODE_FLAG_NHSYNC,
- 0x40,
- "4k144\0",
- }, /* from HP Omen 27c */
-
-};
-
-#define TEST_MODE_IDX_ODMC_2_TO_1 0
-
-static void test_init(struct data *data)
-{
- igt_display_t *display = &data->display;
-
- /* It doesn't matter which pipe we choose on amdpgu. */
- data->pipe_id = PIPE_A;
- data->pipe = &data->display.pipes[data->pipe_id];
-
- igt_display_reset(display);
-
- /* find a connected non-HDMI output */
- data->output = NULL;
- for (int i = 0; i < data->display.n_outputs; ++i) {
- drmModeConnector *connector = data->display.outputs[i].config.connector;
-
- if (connector->connection == DRM_MODE_CONNECTED)
- data->output = &data->display.outputs[i];
- }
- igt_require_f(data->output, "Requires a connected output\n");
-
- data->mode = igt_output_get_mode(data->output);
- igt_assert(data->mode);
-
- igt_skip_on_f(!igt_amd_output_has_odm_combine_segments(data->fd, data->output->name),
- "ASIC does not support reading ODM combine segments\n");
-
- igt_skip_on_f(!is_dp_dsc_supported(data->fd, data->output->name),
- "The monitor must be DSC capable\n");
-
- igt_skip_on_f(data->output->config.connector->connector_type == DRM_MODE_CONNECTOR_HDMIA ||
- data->output->config.connector->connector_type == DRM_MODE_CONNECTOR_HDMIB,
- "ODM Combine isn't supported on HDMI 1.x\n");
-
- data->primary = igt_pipe_get_plane_type(data->pipe, DRM_PLANE_TYPE_PRIMARY);
- igt_output_set_pipe(data->output, data->pipe_id);
-
- igt_display_reset(display);
-}
-
-static void test_fini(struct data *data)
-{
- igt_display_reset(&data->display);
- igt_display_commit_atomic(&data->display, DRM_MODE_ATOMIC_ALLOW_MODESET, 0);
-}
-
-/* Forces a mode for a connector. */
-static void force_output_mode(struct data *d, igt_output_t *output,
- const drmModeModeInfo *mode)
-{
- /* This allows us to create a virtual sink. */
- if (!igt_output_is_connected(output)) {
- kmstest_force_edid(d->fd, output->config.connector,
- igt_kms_get_4k_edid());
-
- kmstest_force_connector(d->fd, output->config.connector,
- FORCE_CONNECTOR_DIGITAL);
- }
-
- igt_output_override_mode(output, mode);
-}
-
-static void run_test_odmc(struct data *data, enum odmc_mode m, const drmModeModeInfo *mode)
-{
- igt_display_t *display = &data->display;
- struct igt_fb buffer;
- char buf[256];
- int ret, seg, fd;
- int i = 0;
-
- test_init(data);
-
- force_output_mode(data, data->output, mode);
-
- igt_create_color_fb(display->drm_fd, mode->hdisplay,
- mode->vdisplay, DRM_FORMAT_XRGB8888,
- DRM_FORMAT_MOD_LINEAR, 1.f, 0.f, 0.f,
- &buffer);
-
- igt_output_set_pipe(data->output, i);
-
- igt_plane_set_fb(data->primary, &buffer);
-
- ret = igt_display_try_commit_atomic(display,
- DRM_MODE_ATOMIC_ALLOW_MODESET |
- DRM_MODE_ATOMIC_TEST_ONLY,
- NULL);
- igt_skip_on_f(ret != 0, "Unsupported mode\n");
-
- igt_display_commit_atomic(display, DRM_MODE_ATOMIC_ALLOW_MODESET, NULL);
-
- fd = igt_debugfs_connector_dir(data->fd, data->output->name, O_RDONLY);
- igt_assert(fd >= 0);
-
- ret = igt_debugfs_simple_read(fd, "odm_combine_segments", buf, sizeof(buf));
- close(fd);
- igt_require(ret > 0);
-
- seg = strtol(buf, NULL, 0);
-
- switch (m) {
- case ODMC_2_TO_1:
- igt_assert_f(seg == 2,
- "ODM Combine uses %d segments for connector %s, expected 2\n",
- seg, data->output->name);
- break;
- case ODMC_4_TO_1:
- igt_assert_f(seg == 4,
- "ODM Combine uses %d segments for connector %s, expected 4\n",
- seg, data->output->name);
- break;
- }
-
- igt_remove_fb(display->drm_fd, &buffer);
-
- test_fini(data);
-}
-
-igt_main
-{
- struct data data;
-
- memset(&data, 0, sizeof(data));
-
- igt_fixture
- {
- data.fd = drm_open_driver_master(DRIVER_ANY);
-
- kmstest_set_vt_graphics_mode();
-
- igt_display_require(&data.display, data.fd);
- igt_require(&data.display.is_atomic);
- igt_display_require_output(&data.display);
-
- }
-
- igt_subtest_f("odm-combine-2-to-1-%s", test_mode[TEST_MODE_IDX_ODMC_2_TO_1].name)
- run_test_odmc(&data, ODMC_2_TO_1, &test_mode[TEST_MODE_IDX_ODMC_2_TO_1]);
-
- igt_fixture
- {
- igt_display_fini(&data.display);
- }
-}
diff --git a/tests/amdgpu/meson.build b/tests/amdgpu/meson.build
index 6032a38e8..6c6166167 100644
--- a/tests/amdgpu/meson.build
+++ b/tests/amdgpu/meson.build
@@ -35,7 +35,6 @@ if libdrm_amdgpu.found()
'amd_vm',
'amd_vrr_range',
'amd_mall',
- 'amd_odm',
]
amdgpu_deps += libdrm_amdgpu
endif
--
2.39.2
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [igt-dev] [PATCH i-g-t] Revert "tests/amdgpu: Add test for ODM combine"
2023-08-22 20:31 [igt-dev] [PATCH i-g-t] Revert "tests/amdgpu: Add test for ODM combine" Kamil Konieczny
@ 2023-08-22 20:46 ` Aurabindo Pillai
2023-08-22 20:52 ` Kamil Konieczny
2023-08-22 23:04 ` [igt-dev] ✗ Fi.CI.BUILD: failure for " Patchwork
1 sibling, 1 reply; 5+ messages in thread
From: Aurabindo Pillai @ 2023-08-22 20:46 UTC (permalink / raw)
To: Kamil Konieczny, igt-dev
Hi Kamil,
You could merge the one liner I sent to the list as well (tests/amdgpu:
Fix build error due to external file include), to fix the build failure.
If you'd rather have the test reverted, feel free to add my Ack and merge:
Acked-by: Aurabindo Pillai <aurabindo.pillai@amd.com>
On 2023-08-22 16:31, Kamil Konieczny wrote:
> This reverts commit a609e0493580c9626fd93dabcf417a41640dcd58.
>
> This commit breaks compilation on debian images in GitLab CI:
>
> build:tests-debian-meson has failed (https://gitlab.freedesktop.org/gfx-ci/igt-ci-tags/-/jobs/47853345):
> ^~~~~~~~
> /usr/include/xf86drmMode.h:533:2: error: unknown type name ‘uint32_t’
> uint32_t lessees[0];
> ^~~~~~~~
> /usr/include/xf86drmMode.h:539:2: error: unknown type name ‘uint32_t’
> uint32_t count;
> ^~~~~~~~
>
> Instead of including <xf86drmMode.h> in test, there should be
> used igt_kms.h library or added <stdint.h>.
>
> Cc: Aurabindo Pillai <aurabindo.pillai@amd.com>
> Cc: Petri Latvala <adrinael@adrinael.net>
> Cc: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
> Cc: Ashutosh Dixit <ashutosh.dixit@intel.com>
> Signed-off-by: Kamil Konieczny <kamil.konieczny@linux.intel.com>
> ---
> tests/amdgpu/amd_odm.c | 189 ---------------------------------------
> tests/amdgpu/meson.build | 1 -
> 2 files changed, 190 deletions(-)
> delete mode 100644 tests/amdgpu/amd_odm.c
>
> diff --git a/tests/amdgpu/amd_odm.c b/tests/amdgpu/amd_odm.c
> deleted file mode 100644
> index 2781ad1c2..000000000
> --- a/tests/amdgpu/amd_odm.c
> +++ /dev/null
> @@ -1,189 +0,0 @@
> -// SPDX-License-Identifier: MIT
> -/*
> - * Copyrights 2023 Advanced Micro Devices, Inc.
> - */
> -
> -#include <fcntl.h>
> -#include <stdio.h>
> -#include <xf86drmMode.h>
> -
> -#include "igt.h"
> -#include "igt_amd.h"
> -#include "igt_edid.h"
> -
> -IGT_TEST_DESCRIPTION("Test whether ODM Combine mode is triggered when timings with high refresh "
> - "rate is committed");
> -
> -enum odmc_mode {
> - ODMC_2_TO_1,
> - ODMC_4_TO_1,
> -};
> -
> -/* Common test data. */
> -struct data {
> - igt_display_t display;
> - igt_plane_t *primary;
> - igt_output_t *output;
> - igt_pipe_t *pipe;
> - drmModeModeInfoPtr mode;
> - enum pipe pipe_id;
> - int fd;
> -};
> -
> -static const drmModeModeInfo test_mode[] = {
> - { 1278720,
> - 3840, 3952, 3984, 4000, 0,
> - 2160, 2210, 2215, 2220, 0,
> - 30,
> - DRM_MODE_FLAG_NHSYNC,
> - 0x40,
> - "4k144\0",
> - }, /* from HP Omen 27c */
> -
> -};
> -
> -#define TEST_MODE_IDX_ODMC_2_TO_1 0
> -
> -static void test_init(struct data *data)
> -{
> - igt_display_t *display = &data->display;
> -
> - /* It doesn't matter which pipe we choose on amdpgu. */
> - data->pipe_id = PIPE_A;
> - data->pipe = &data->display.pipes[data->pipe_id];
> -
> - igt_display_reset(display);
> -
> - /* find a connected non-HDMI output */
> - data->output = NULL;
> - for (int i = 0; i < data->display.n_outputs; ++i) {
> - drmModeConnector *connector = data->display.outputs[i].config.connector;
> -
> - if (connector->connection == DRM_MODE_CONNECTED)
> - data->output = &data->display.outputs[i];
> - }
> - igt_require_f(data->output, "Requires a connected output\n");
> -
> - data->mode = igt_output_get_mode(data->output);
> - igt_assert(data->mode);
> -
> - igt_skip_on_f(!igt_amd_output_has_odm_combine_segments(data->fd, data->output->name),
> - "ASIC does not support reading ODM combine segments\n");
> -
> - igt_skip_on_f(!is_dp_dsc_supported(data->fd, data->output->name),
> - "The monitor must be DSC capable\n");
> -
> - igt_skip_on_f(data->output->config.connector->connector_type == DRM_MODE_CONNECTOR_HDMIA ||
> - data->output->config.connector->connector_type == DRM_MODE_CONNECTOR_HDMIB,
> - "ODM Combine isn't supported on HDMI 1.x\n");
> -
> - data->primary = igt_pipe_get_plane_type(data->pipe, DRM_PLANE_TYPE_PRIMARY);
> - igt_output_set_pipe(data->output, data->pipe_id);
> -
> - igt_display_reset(display);
> -}
> -
> -static void test_fini(struct data *data)
> -{
> - igt_display_reset(&data->display);
> - igt_display_commit_atomic(&data->display, DRM_MODE_ATOMIC_ALLOW_MODESET, 0);
> -}
> -
> -/* Forces a mode for a connector. */
> -static void force_output_mode(struct data *d, igt_output_t *output,
> - const drmModeModeInfo *mode)
> -{
> - /* This allows us to create a virtual sink. */
> - if (!igt_output_is_connected(output)) {
> - kmstest_force_edid(d->fd, output->config.connector,
> - igt_kms_get_4k_edid());
> -
> - kmstest_force_connector(d->fd, output->config.connector,
> - FORCE_CONNECTOR_DIGITAL);
> - }
> -
> - igt_output_override_mode(output, mode);
> -}
> -
> -static void run_test_odmc(struct data *data, enum odmc_mode m, const drmModeModeInfo *mode)
> -{
> - igt_display_t *display = &data->display;
> - struct igt_fb buffer;
> - char buf[256];
> - int ret, seg, fd;
> - int i = 0;
> -
> - test_init(data);
> -
> - force_output_mode(data, data->output, mode);
> -
> - igt_create_color_fb(display->drm_fd, mode->hdisplay,
> - mode->vdisplay, DRM_FORMAT_XRGB8888,
> - DRM_FORMAT_MOD_LINEAR, 1.f, 0.f, 0.f,
> - &buffer);
> -
> - igt_output_set_pipe(data->output, i);
> -
> - igt_plane_set_fb(data->primary, &buffer);
> -
> - ret = igt_display_try_commit_atomic(display,
> - DRM_MODE_ATOMIC_ALLOW_MODESET |
> - DRM_MODE_ATOMIC_TEST_ONLY,
> - NULL);
> - igt_skip_on_f(ret != 0, "Unsupported mode\n");
> -
> - igt_display_commit_atomic(display, DRM_MODE_ATOMIC_ALLOW_MODESET, NULL);
> -
> - fd = igt_debugfs_connector_dir(data->fd, data->output->name, O_RDONLY);
> - igt_assert(fd >= 0);
> -
> - ret = igt_debugfs_simple_read(fd, "odm_combine_segments", buf, sizeof(buf));
> - close(fd);
> - igt_require(ret > 0);
> -
> - seg = strtol(buf, NULL, 0);
> -
> - switch (m) {
> - case ODMC_2_TO_1:
> - igt_assert_f(seg == 2,
> - "ODM Combine uses %d segments for connector %s, expected 2\n",
> - seg, data->output->name);
> - break;
> - case ODMC_4_TO_1:
> - igt_assert_f(seg == 4,
> - "ODM Combine uses %d segments for connector %s, expected 4\n",
> - seg, data->output->name);
> - break;
> - }
> -
> - igt_remove_fb(display->drm_fd, &buffer);
> -
> - test_fini(data);
> -}
> -
> -igt_main
> -{
> - struct data data;
> -
> - memset(&data, 0, sizeof(data));
> -
> - igt_fixture
> - {
> - data.fd = drm_open_driver_master(DRIVER_ANY);
> -
> - kmstest_set_vt_graphics_mode();
> -
> - igt_display_require(&data.display, data.fd);
> - igt_require(&data.display.is_atomic);
> - igt_display_require_output(&data.display);
> -
> - }
> -
> - igt_subtest_f("odm-combine-2-to-1-%s", test_mode[TEST_MODE_IDX_ODMC_2_TO_1].name)
> - run_test_odmc(&data, ODMC_2_TO_1, &test_mode[TEST_MODE_IDX_ODMC_2_TO_1]);
> -
> - igt_fixture
> - {
> - igt_display_fini(&data.display);
> - }
> -}
> diff --git a/tests/amdgpu/meson.build b/tests/amdgpu/meson.build
> index 6032a38e8..6c6166167 100644
> --- a/tests/amdgpu/meson.build
> +++ b/tests/amdgpu/meson.build
> @@ -35,7 +35,6 @@ if libdrm_amdgpu.found()
> 'amd_vm',
> 'amd_vrr_range',
> 'amd_mall',
> - 'amd_odm',
> ]
> amdgpu_deps += libdrm_amdgpu
> endif
--
--
Thanks & Regards,
Jay
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [igt-dev] [PATCH i-g-t] Revert "tests/amdgpu: Add test for ODM combine"
2023-08-22 20:46 ` Aurabindo Pillai
@ 2023-08-22 20:52 ` Kamil Konieczny
2023-08-22 20:56 ` Aurabindo Pillai
0 siblings, 1 reply; 5+ messages in thread
From: Kamil Konieczny @ 2023-08-22 20:52 UTC (permalink / raw)
To: igt-dev
Hi Aurabindo,
On 2023-08-22 at 16:46:05 -0400, Aurabindo Pillai wrote:
> Hi Kamil,
>
> You could merge the one liner I sent to the list as well (tests/amdgpu: Fix
> build error due to external file include), to fix the build failure. If
> you'd rather have the test reverted, feel free to add my Ack and merge:
>
> Acked-by: Aurabindo Pillai <aurabindo.pillai@amd.com>
>
Please merge your fix.
Regards,
Kamil
> On 2023-08-22 16:31, Kamil Konieczny wrote:
> > This reverts commit a609e0493580c9626fd93dabcf417a41640dcd58.
> >
> > This commit breaks compilation on debian images in GitLab CI:
> >
> > build:tests-debian-meson has failed (https://gitlab.freedesktop.org/gfx-ci/igt-ci-tags/-/jobs/47853345):
> > ^~~~~~~~
> > /usr/include/xf86drmMode.h:533:2: error: unknown type name ‘uint32_t’
> > uint32_t lessees[0];
> > ^~~~~~~~
> > /usr/include/xf86drmMode.h:539:2: error: unknown type name ‘uint32_t’
> > uint32_t count;
> > ^~~~~~~~
> >
> > Instead of including <xf86drmMode.h> in test, there should be
> > used igt_kms.h library or added <stdint.h>.
> >
> > Cc: Aurabindo Pillai <aurabindo.pillai@amd.com>
> > Cc: Petri Latvala <adrinael@adrinael.net>
> > Cc: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
> > Cc: Ashutosh Dixit <ashutosh.dixit@intel.com>
> > Signed-off-by: Kamil Konieczny <kamil.konieczny@linux.intel.com>
> > ---
> > tests/amdgpu/amd_odm.c | 189 ---------------------------------------
> > tests/amdgpu/meson.build | 1 -
> > 2 files changed, 190 deletions(-)
> > delete mode 100644 tests/amdgpu/amd_odm.c
> >
> > diff --git a/tests/amdgpu/amd_odm.c b/tests/amdgpu/amd_odm.c
> > deleted file mode 100644
> > index 2781ad1c2..000000000
> > --- a/tests/amdgpu/amd_odm.c
> > +++ /dev/null
> > @@ -1,189 +0,0 @@
> > -// SPDX-License-Identifier: MIT
> > -/*
> > - * Copyrights 2023 Advanced Micro Devices, Inc.
> > - */
> > -
> > -#include <fcntl.h>
> > -#include <stdio.h>
> > -#include <xf86drmMode.h>
> > -
> > -#include "igt.h"
> > -#include "igt_amd.h"
> > -#include "igt_edid.h"
> > -
> > -IGT_TEST_DESCRIPTION("Test whether ODM Combine mode is triggered when timings with high refresh "
> > - "rate is committed");
> > -
> > -enum odmc_mode {
> > - ODMC_2_TO_1,
> > - ODMC_4_TO_1,
> > -};
> > -
> > -/* Common test data. */
> > -struct data {
> > - igt_display_t display;
> > - igt_plane_t *primary;
> > - igt_output_t *output;
> > - igt_pipe_t *pipe;
> > - drmModeModeInfoPtr mode;
> > - enum pipe pipe_id;
> > - int fd;
> > -};
> > -
> > -static const drmModeModeInfo test_mode[] = {
> > - { 1278720,
> > - 3840, 3952, 3984, 4000, 0,
> > - 2160, 2210, 2215, 2220, 0,
> > - 30,
> > - DRM_MODE_FLAG_NHSYNC,
> > - 0x40,
> > - "4k144\0",
> > - }, /* from HP Omen 27c */
> > -
> > -};
> > -
> > -#define TEST_MODE_IDX_ODMC_2_TO_1 0
> > -
> > -static void test_init(struct data *data)
> > -{
> > - igt_display_t *display = &data->display;
> > -
> > - /* It doesn't matter which pipe we choose on amdpgu. */
> > - data->pipe_id = PIPE_A;
> > - data->pipe = &data->display.pipes[data->pipe_id];
> > -
> > - igt_display_reset(display);
> > -
> > - /* find a connected non-HDMI output */
> > - data->output = NULL;
> > - for (int i = 0; i < data->display.n_outputs; ++i) {
> > - drmModeConnector *connector = data->display.outputs[i].config.connector;
> > -
> > - if (connector->connection == DRM_MODE_CONNECTED)
> > - data->output = &data->display.outputs[i];
> > - }
> > - igt_require_f(data->output, "Requires a connected output\n");
> > -
> > - data->mode = igt_output_get_mode(data->output);
> > - igt_assert(data->mode);
> > -
> > - igt_skip_on_f(!igt_amd_output_has_odm_combine_segments(data->fd, data->output->name),
> > - "ASIC does not support reading ODM combine segments\n");
> > -
> > - igt_skip_on_f(!is_dp_dsc_supported(data->fd, data->output->name),
> > - "The monitor must be DSC capable\n");
> > -
> > - igt_skip_on_f(data->output->config.connector->connector_type == DRM_MODE_CONNECTOR_HDMIA ||
> > - data->output->config.connector->connector_type == DRM_MODE_CONNECTOR_HDMIB,
> > - "ODM Combine isn't supported on HDMI 1.x\n");
> > -
> > - data->primary = igt_pipe_get_plane_type(data->pipe, DRM_PLANE_TYPE_PRIMARY);
> > - igt_output_set_pipe(data->output, data->pipe_id);
> > -
> > - igt_display_reset(display);
> > -}
> > -
> > -static void test_fini(struct data *data)
> > -{
> > - igt_display_reset(&data->display);
> > - igt_display_commit_atomic(&data->display, DRM_MODE_ATOMIC_ALLOW_MODESET, 0);
> > -}
> > -
> > -/* Forces a mode for a connector. */
> > -static void force_output_mode(struct data *d, igt_output_t *output,
> > - const drmModeModeInfo *mode)
> > -{
> > - /* This allows us to create a virtual sink. */
> > - if (!igt_output_is_connected(output)) {
> > - kmstest_force_edid(d->fd, output->config.connector,
> > - igt_kms_get_4k_edid());
> > -
> > - kmstest_force_connector(d->fd, output->config.connector,
> > - FORCE_CONNECTOR_DIGITAL);
> > - }
> > -
> > - igt_output_override_mode(output, mode);
> > -}
> > -
> > -static void run_test_odmc(struct data *data, enum odmc_mode m, const drmModeModeInfo *mode)
> > -{
> > - igt_display_t *display = &data->display;
> > - struct igt_fb buffer;
> > - char buf[256];
> > - int ret, seg, fd;
> > - int i = 0;
> > -
> > - test_init(data);
> > -
> > - force_output_mode(data, data->output, mode);
> > -
> > - igt_create_color_fb(display->drm_fd, mode->hdisplay,
> > - mode->vdisplay, DRM_FORMAT_XRGB8888,
> > - DRM_FORMAT_MOD_LINEAR, 1.f, 0.f, 0.f,
> > - &buffer);
> > -
> > - igt_output_set_pipe(data->output, i);
> > -
> > - igt_plane_set_fb(data->primary, &buffer);
> > -
> > - ret = igt_display_try_commit_atomic(display,
> > - DRM_MODE_ATOMIC_ALLOW_MODESET |
> > - DRM_MODE_ATOMIC_TEST_ONLY,
> > - NULL);
> > - igt_skip_on_f(ret != 0, "Unsupported mode\n");
> > -
> > - igt_display_commit_atomic(display, DRM_MODE_ATOMIC_ALLOW_MODESET, NULL);
> > -
> > - fd = igt_debugfs_connector_dir(data->fd, data->output->name, O_RDONLY);
> > - igt_assert(fd >= 0);
> > -
> > - ret = igt_debugfs_simple_read(fd, "odm_combine_segments", buf, sizeof(buf));
> > - close(fd);
> > - igt_require(ret > 0);
> > -
> > - seg = strtol(buf, NULL, 0);
> > -
> > - switch (m) {
> > - case ODMC_2_TO_1:
> > - igt_assert_f(seg == 2,
> > - "ODM Combine uses %d segments for connector %s, expected 2\n",
> > - seg, data->output->name);
> > - break;
> > - case ODMC_4_TO_1:
> > - igt_assert_f(seg == 4,
> > - "ODM Combine uses %d segments for connector %s, expected 4\n",
> > - seg, data->output->name);
> > - break;
> > - }
> > -
> > - igt_remove_fb(display->drm_fd, &buffer);
> > -
> > - test_fini(data);
> > -}
> > -
> > -igt_main
> > -{
> > - struct data data;
> > -
> > - memset(&data, 0, sizeof(data));
> > -
> > - igt_fixture
> > - {
> > - data.fd = drm_open_driver_master(DRIVER_ANY);
> > -
> > - kmstest_set_vt_graphics_mode();
> > -
> > - igt_display_require(&data.display, data.fd);
> > - igt_require(&data.display.is_atomic);
> > - igt_display_require_output(&data.display);
> > -
> > - }
> > -
> > - igt_subtest_f("odm-combine-2-to-1-%s", test_mode[TEST_MODE_IDX_ODMC_2_TO_1].name)
> > - run_test_odmc(&data, ODMC_2_TO_1, &test_mode[TEST_MODE_IDX_ODMC_2_TO_1]);
> > -
> > - igt_fixture
> > - {
> > - igt_display_fini(&data.display);
> > - }
> > -}
> > diff --git a/tests/amdgpu/meson.build b/tests/amdgpu/meson.build
> > index 6032a38e8..6c6166167 100644
> > --- a/tests/amdgpu/meson.build
> > +++ b/tests/amdgpu/meson.build
> > @@ -35,7 +35,6 @@ if libdrm_amdgpu.found()
> > 'amd_vm',
> > 'amd_vrr_range',
> > 'amd_mall',
> > - 'amd_odm',
> > ]
> > amdgpu_deps += libdrm_amdgpu
> > endif
>
> --
> --
>
> Thanks & Regards,
> Jay
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [igt-dev] [PATCH i-g-t] Revert "tests/amdgpu: Add test for ODM combine"
2023-08-22 20:52 ` Kamil Konieczny
@ 2023-08-22 20:56 ` Aurabindo Pillai
0 siblings, 0 replies; 5+ messages in thread
From: Aurabindo Pillai @ 2023-08-22 20:56 UTC (permalink / raw)
To: Kamil Konieczny, igt-dev, Petri Latvala,
Zbigniew Kempczyński, Ashutosh Dixit
On 2023-08-22 16:52, Kamil Konieczny wrote:
> Hi Aurabindo,
>
> On 2023-08-22 at 16:46:05 -0400, Aurabindo Pillai wrote:
>> Hi Kamil,
>>
>> You could merge the one liner I sent to the list as well (tests/amdgpu: Fix
>> build error due to external file include), to fix the build failure. If
>> you'd rather have the test reverted, feel free to add my Ack and merge:
>>
>> Acked-by: Aurabindo Pillai <aurabindo.pillai@amd.com>
>>
>
> Please merge your fix.
>
Merged.
--
Thanks & Regards,
Jay
^ permalink raw reply [flat|nested] 5+ messages in thread
* [igt-dev] ✗ Fi.CI.BUILD: failure for Revert "tests/amdgpu: Add test for ODM combine"
2023-08-22 20:31 [igt-dev] [PATCH i-g-t] Revert "tests/amdgpu: Add test for ODM combine" Kamil Konieczny
2023-08-22 20:46 ` Aurabindo Pillai
@ 2023-08-22 23:04 ` Patchwork
1 sibling, 0 replies; 5+ messages in thread
From: Patchwork @ 2023-08-22 23:04 UTC (permalink / raw)
To: Kamil Konieczny; +Cc: igt-dev
== Series Details ==
Series: Revert "tests/amdgpu: Add test for ODM combine"
URL : https://patchwork.freedesktop.org/series/122762/
State : failure
== Summary ==
Applying: Revert "tests/amdgpu: Add test for ODM combine"
Using index info to reconstruct a base tree...
M tests/amdgpu/amd_odm.c
Falling back to patching base and 3-way merge...
CONFLICT (modify/delete): tests/amdgpu/amd_odm.c deleted in Revert "tests/amdgpu: Add test for ODM combine" and modified in HEAD. Version HEAD of tests/amdgpu/amd_odm.c left in tree.
Patch failed at 0001 Revert "tests/amdgpu: Add test for ODM combine"
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2023-08-22 23:04 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-22 20:31 [igt-dev] [PATCH i-g-t] Revert "tests/amdgpu: Add test for ODM combine" Kamil Konieczny
2023-08-22 20:46 ` Aurabindo Pillai
2023-08-22 20:52 ` Kamil Konieczny
2023-08-22 20:56 ` Aurabindo Pillai
2023-08-22 23:04 ` [igt-dev] ✗ Fi.CI.BUILD: failure for " Patchwork
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox