Skip to content

Commit

Permalink
drm/tests: helpers: Add atomic helpers
Browse files Browse the repository at this point in the history
The mock device we were creating was missing any of the driver-wide
helpers. That was fine before since we weren't testing the atomic state
path, but we're going to start, so let's use the default
implementations.

Reviewed-by: Maíra Canal <mcanal@igalia.com>
Signed-off-by: Maxime Ripard <mripard@kernel.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20240222-kms-hdmi-connector-state-v7-2-8f4af575fce2@kernel.org
  • Loading branch information
Maxime Ripard committed Feb 28, 2024
1 parent 73984da commit 6667194
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions drivers/gpu/drm/tests/drm_kunit_helpers.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
// SPDX-License-Identifier: GPL-2.0

#include <drm/drm_atomic.h>
#include <drm/drm_atomic_helper.h>
#include <drm/drm_drv.h>
#include <drm/drm_kunit_helpers.h>
#include <drm/drm_managed.h>
Expand All @@ -14,6 +15,8 @@
#define KUNIT_DEVICE_NAME "drm-kunit-mock-device"

static const struct drm_mode_config_funcs drm_mode_config_funcs = {
.atomic_check = drm_atomic_helper_check,
.atomic_commit = drm_atomic_helper_commit,
};

/**
Expand Down

0 comments on commit 6667194

Please sign in to comment.