Den 29.08.2022 15.11, skrev Maxime Ripard:
> Since we've recently added a ton of tests, the list starts to be a bit
>
> of a mess and creates unneeded conflicts.
>
>
>
> Let's order it alphabetically.
>
>
>
> Signed-off-by: Maxime Ripard
>
>
>
Something has gone wrong with this patch
Den 29.08.2022 15.11, skrev Maxime Ripard:
> The mode_fixup hooks are deprecated, and the behaviour we implement is the
>
> default one anyway. Let's remove it.
>
>
>
> Signed-off-by: Maxime Ripard
>
Reviewed-by: Noralf Trønnes
Den 29.08.2022 15.11, skrev Maxime Ripard:
> The VC4 VEC driver still uses legacy enable and disable hook
>
> implementation. Let's convert to the atomic variants.
>
>
>
> Signed-off-by: Maxime Ripard
>
Reviewed-by: Noralf Trønnes
vec_pal_mode_set,
>
> + .config0 = VEC_CONFIG0_PAL_BDGHI_STD,
>
> + .config1 = VEC_CONFIG1_C_CVBS_CVBS,
>
> },
>
> [VC4_VEC_TV_MODE_PAL_M] = {
>
> .mode = &pal_mode,
>
> -
- (vec->tv_mode->custom_freq >> 16) &
>
> - 0x);
>
> + (tv_mode->custom_freq >> 16) & 0x);
>
> VEC_WRITE(VEC_FREQ1_0,
>
> - vec-&g
ards.
>
>
>
> Previous timings were actually defined as 502 and 601 lines, resulting
>
> in non-standard 62.69 Hz and 52 Hz signals being generated,
>
> respectively.
>
>
>
> Signed-off-by: Mateusz Kwiatkowski
>
> Signed-off-by: Maxime Ripard
>
>
Acked-by: Noralf Trønnes
Den 29.08.2022 15.11, skrev Maxime Ripard:
> Now that the core has a definition for the 525 and 625 lines analog TV
>
> modes, let's switch to it for vc4.
>
>
>
> Signed-off-by: Maxime Ripard
>
>
>
> diff --git a/drivers/gpu/drm/vc4/vc4_vec.c b/drivers/gpu/drm/vc4/vc4_vec.c
>
> index d1
;
>
>
> Let's create a helper that will take care of it.
>
>
>
> Signed-off-by: Maxime Ripard
>
Reviewed-by: Noralf Trønnes
gt;tv.contrast ||
old_conn_state->tv.flicker_reduction !=
new_conn_state->tv.flicker_reduction ||
old_conn_state->tv.overscan != new_conn_state->tv.overscan ||
old_conn_state->tv.saturation != new_conn_state->tv.saturation ||
old_conn_state->
gt; Signed-off-by: Maxime Ripard
>
Reviewed-by: Noralf Trønnes
Den 29.08.2022 15.11, skrev Maxime Ripard:
> Now that the core can deal fine with analog TV modes, let's convert the vc4
>
> VEC driver to leverage those new features.
>
>
>
> We've added some backward compatibility to support the old TV mode property
>
> and translate it into the new TV no
Den 29.08.2022 15.11, skrev Maxime Ripard:
> The current tv_mode has driver-specific values that don't allow to
>
> easily share code using it, either at the userspace or kernel level.
>
>
>
> Since we're going to introduce a new, generic, property that fit the
>
> same purpose, let's renam
Den 29.08.2022 15.11, skrev Maxime Ripard:
> As part of the command line parsing rework coming in the next patches,
>
> we'll need to lookup drm_connector_tv_mode values by their name, already
>
> defined in drm_tv_mode_enum_list.
>
>
>
> In order to avoid any code duplication, let's do a f
Den 29.08.2022 15.11, skrev Maxime Ripard:
> Multiple drivers (meson, vc4, sun4i) define analog TV 525-lines and
>
> 625-lines modes in their drivers.
>
>
>
> Since those modes are fairly standard, and that we'll need to use them
>
> in more places in the future, it makes sense to move thei
Den 29.08.2022 15.11, skrev Maxime Ripard:
> Hi,
>
>
>
> Here's a series aiming at improving the command line named modes support,
>
> and more importantly how we deal with all the analog TV variants.
>
>
>
> The named modes support were initially introduced to allow to specify the
>
> a
Den 01.09.2022 21.35, skrev Noralf Trønnes:
>
>
> I have finally found a workaround for my kernel hangs.
>
> Dom had a look at my kernel and found that the VideoCore was fine, and
> he said this:
>
>> That suggests cause of lockup was on arm side rather than VC s
Den 29.08.2022 15.11, skrev Maxime Ripard:
> The TV mode property has been around for a while now to select and get the
>
> current TV mode output on an analog TV connector.
>
>
>
> Despite that property name being generic, its content isn't and has been
>
> driver-specific which makes it h
Den 05.09.2022 16.57, skrev Maxime Ripard:
> On Fri, Sep 02, 2022 at 01:28:16PM +0200, Noralf Trønnes wrote:
>>
>>
>> Den 01.09.2022 21.35, skrev Noralf Trønnes:
>>>
>>>
>>> I have finally found a workaround for my kernel hangs.
>>>
>
Den 07.09.2022 11.58, skrev Maxime Ripard:
> On Mon, Sep 05, 2022 at 05:17:18PM +0200, Noralf Trønnes wrote:
>> Den 05.09.2022 16.57, skrev Maxime Ripard:
>>> On Fri, Sep 02, 2022 at 01:28:16PM +0200, Noralf Trønnes wrote:
>>>>
>>>>
>&
Den 07.09.2022 12.36, skrev Stefan Wahren:
> Hi Maxime,
>
> Am 05.09.22 um 16:57 schrieb Maxime Ripard:
>> On Fri, Sep 02, 2022 at 01:28:16PM +0200, Noralf Trønnes wrote:
>>>
>>> Den 01.09.2022 21.35, skrev Noralf Trønnes:
>>>>
>>>&
Den 08.09.2022 13.23, skrev Maxime Ripard:
> Hi Noralf,
>
> On Tue, Aug 30, 2022 at 09:01:08PM +0200, Noralf Trønnes wrote:
>>> +static const struct drm_prop_enum_list tv_mode_names[] = {
>>
>> Maybe call it legacy_tv_mode_enums?
>>
>&
Den 07.09.2022 18.44, skrev Noralf Trønnes:
>
>
> Den 07.09.2022 12.36, skrev Stefan Wahren:
>> Hi Maxime,
>>
>> Am 05.09.22 um 16:57 schrieb Maxime Ripard:
>>> On Fri, Sep 02, 2022 at 01:28:16PM +0200, Noralf Trønnes wrote:
>>>>
>>>&g
Den 21.09.2022 16.03, skrev Maxime Ripard:
> On Wed, Sep 07, 2022 at 06:44:53PM +0200, Noralf Trønnes wrote:
>>
>>
>> Den 07.09.2022 12.36, skrev Stefan Wahren:
>>> Hi Maxime,
>>>
>>> Am 05.09.22 um 16:57 schrieb Maxime Ripard:
>>>> On
se, let's rename this one to legacy_tv_mode to make it
> obvious we should move away from it.
>
> Signed-off-by: Maxime Ripard
>
Reviewed-by: Noralf Trønnes
27;s rename that
> function to mention it's deprecated. We'll introduce a new variant of
> that function creating the property superseeding it in a later patch.
>
> Signed-off-by: Maxime Ripard
>
Reviewed-by: Noralf Trønnes
Den 22.09.2022 16.25, skrev Maxime Ripard:
> The TV mode property has been around for a while now to select and get the
> current TV mode output on an analog TV connector.
>
> Despite that property name being generic, its content isn't and has been
> driver-specific which makes it hard to build
r removing the display
mode check. It's only about detecting changes now.
Noralf.
>
> Let's create an atomic_check helper for those use cases.
>
> Reviewed-by: Noralf Trønnes
> Signed-off-by: Maxime Ripard
>
> diff --git a/drivers/gpu/drm/drm_atomic_state_helper.c
preset for this
> mode instead of just changing PAL subcarrier frequency.
>
> Signed-off-by: Mateusz Kwiatkowski
> Signed-off-by: Maxime Ripard
>
Acked-by: Noralf Trønnes
n't end up accepting a non-functional mode.
>
> Signed-off-by: Mateusz Kwiatkowski
> Signed-off-by: Maxime Ripard
>
Acked-by: Noralf Trønnes
> - vc4_vec_tv_modes[state->tv.legacy_mode].mode);
> + mode = drm_mode_analog_ntsc_480i(connector->dev);
> if (!mode) {
> DRM_ERROR("Failed to create a new display mode\n");
> return -ENOMEM;
>
sters.
>
> Signed-off-by: Mateusz Kwiatkowski
> Signed-off-by: Maxime Ripard
>
Acked-by: Noralf Trønnes
Den 22.09.2022 16.25, skrev Maxime Ripard:
> Since we've recently added a ton of tests, the list starts to be a bit
> of a mess and creates unneeded conflicts.
>
> Let's order it alphabetically.
>
> Signed-off-by: Maxime Ripard
>
Reviewed-by: Noralf Trønnes
Den 22.09.2022 16.25, skrev Maxime Ripard:
> As the number of kunit tests in KMS grows further, we start to have
> multiple test suites that, for example, need to register a mock DRM
> driver to interact with the KMS function they are supposed to test.
>
> Let's add a file meant to provide thos
Den 24.09.2022 19.56, skrev Noralf Trønnes:
>
>
> Den 22.09.2022 16.25, skrev Maxime Ripard:
>> As the number of kunit tests in KMS grows further, we start to have
>> multiple test suites that, for example, need to register a mock DRM
>> driver to interact wit
Den 22.09.2022 16.25, skrev Maxime Ripard:
> Hi,
>
> Here's a series aiming at improving the command line named modes support,
> and more importantly how we deal with all the analog TV variants.
>
> The named modes support were initially introduced to allow to specify the
> analog TV mode to b
Den 26.09.2022 11.36, skrev Maxime Ripard:
> Hi Noralf,
>
> On Sat, Sep 24, 2022 at 08:06:17PM +0200, Noralf Trønnes wrote:
>> Den 24.09.2022 19.56, skrev Noralf Trønnes:
>>>
>>>
>>> Den 22.09.2022 16.25, skrev Maxime Ripard:
>>>> As the n
Den 26.09.2022 12.01, skrev Maxime Ripard:
> On Sat, Sep 24, 2022 at 05:52:29PM +0200, Noralf Trønnes wrote:
>> Den 22.09.2022 16.25, skrev Maxime Ripard:
>>> The TV mode property has been around for a while now to select and get the
>>> current TV mode outpu
Den 29.09.2022 18.30, skrev Maxime Ripard:
> That property is not used or exposed by any driver in the kernel. Remove
> it from the documentation.
>
> Signed-off-by: Maxime Ripard
>
> ---
> Changes in v4:
> - New patch
> ---
> Documentation/gpu/kms-properties.csv | 1 -
> 1 file changed, 1 d
Den 29.09.2022 18.31, skrev Maxime Ripard:
> The TV mode property has been around for a while now to select and get the
> current TV mode output on an analog TV connector.
>
> Despite that property name being generic, its content isn't and has been
> driver-specific which makes it hard to build
ile meant to provide those kind of helpers to avoid
> duplication.
>
> Signed-off-by: Maxime Ripard
>
Reviewed-by: Noralf Trønnes
> + mode = drm_mode_analog_pal_576i(connector->dev);
> + if (!mode) {
> + DRM_ERROR("Failed to create a new display mode\n");
> + return -ENOMEM;
> }
>
> - return i;
> + drm_mode_probed_add(connector, mode);
> + count += 1;
> +
>
Den 29.09.2022 18.31, skrev Maxime Ripard:
> Multiple drivers (meson, vc4, sun4i) define analog TV 525-lines and
> 625-lines modes in their drivers.
>
> Since those modes are fairly standard, and that we'll need to use them
> in more places in the future, it makes sense to move their definition
Den 29.09.2022 18.30, skrev Maxime Ripard:
> Hi,
>
> Here's a series aiming at improving the command line named modes support,
> and more importantly how we deal with all the analog TV variants.
>
> The named modes support were initially introduced to allow to specify the
> analog TV mode to b
Den 13.10.2022 10.36, skrev Maxime Ripard:
> Hi Noralf,
>
> On Sat, Oct 01, 2022 at 02:52:06PM +0200, Noralf Trønnes wrote:
>> Den 29.09.2022 18.31, skrev Maxime Ripard:
>>> Multiple drivers (meson, vc4, sun4i) define analog TV 525-lines and
>>> 625-lines mode
ile meant to provide those kind of helpers to avoid
> duplication.
>
> Signed-off-by: Maxime Ripard
>
> ---
Reviewed-by: Noralf Trønnes
t; *client, int mode)
> return ret;
> }
> EXPORT_SYMBOL(drm_client_modeset_dpms);
> +
> +#ifdef CONFIG_DRM_KUNIT_TEST
> +#include "tests/drm_client_modeset_test.c"
> +#endif
I can't say I like including the file like this, but exporting the
static function for testing isn't attractive either and doing it like
this is shown in the kunit docs, so:
Acked-by: Noralf Trønnes
Den 13.10.2022 15.18, skrev Maxime Ripard:
> The current construction of the named mode parsing doesn't allow to extend
> it easily. Let's move it to a separate function so we can add more
> parameters and modes.
>
> In order for the tests to still pass, some extra checks are needed, so
> it's
Den 16.10.2022 19.51, skrev Mateusz Kwiatkowski:
> Hi Maxime, Noralf & everyone,
>
> I'd like to address Noralf here in particular, and refer to these discussions
> from the past:
>
> -
> https://lore.kernel.org/linux-arm-kernel/2f607c7d-6da1-c8df-1c02-8dd344a92...@gmail.com/
> -
> https://l
Den 16.10.2022 20.52, skrev Mateusz Kwiatkowski:
> Hi Maxime,
>
>> static int vc4_vec_connector_get_modes(struct drm_connector *connector)
>> {
>> -struct drm_connector_state *state = connector->state;
>> struct drm_display_mode *mode;
>>
>> -mode = drm_mode_duplicate(connector
et's create a helper that will take care of it.
>
> Reviewed-by: Noralf Trønnes
> Signed-off-by: Maxime Ripard
> ---
> drivers/gpu/drm/drm_atomic_state_helper.c | 75
> +++
> include/drm/drm_atomic_state_helper.h | 1 +
> 2 files change
Den 13.10.2022 15.18, skrev Maxime Ripard:
> As part of the command line parsing rework coming in the next patches,
> we'll need to lookup drm_connector_tv_mode values by their name, already
> defined in drm_tv_mode_enum_list.
>
> In order to avoid any code duplication, let's do a function that
the new TV norm property. We're also making use of
> the new analog TV atomic_check helper to make sure we trigger a modeset
> whenever the TV mode is updated.
>
> Acked-by: Noralf Trønnes
> Signed-off-by: Maxime Ripard
>
> ---
> @@ -276,19 +292,96 @@ stati
Den 18.10.2022 11.33, skrev Maxime Ripard:
> On Mon, Oct 17, 2022 at 12:44:45PM +0200, Noralf Trønnes wrote:
>> Den 13.10.2022 15.18, skrev Maxime Ripard:
>>> As part of the command line parsing rework coming in the next patches,
>>> we'll need to lookup drm_c
Den 19.10.2022 10.48, skrev Maxime Ripard:
> On Tue, Oct 18, 2022 at 02:29:00PM +0200, Noralf Trønnes wrote:
>>
>>
>> Den 18.10.2022 11.33, skrev Maxime Ripard:
>>> On Mon, Oct 17, 2022 at 12:44:45PM +0200, Noralf Trønnes wrote:
>>>> Den 13.10.2022 15
tra checks are needed, so
> it's not a 1:1 move.
>
> Signed-off-by: Maxime Ripard
>
> ---
Reviewed-by: Noralf Trønnes
> hold the name and some additional parameters in the future.
>
> Signed-off-by: Maxime Ripard
> ---
Reviewed-by: Noralf Trønnes
Den 26.10.2022 17.33, skrev max...@cerno.tech:
> The framework will get the drm_display_mode from the drm_cmdline_mode it
> got by parsing the video command line argument by calling
> drm_connector_pick_cmdline_mode().
>
> The heavy lifting will then be done by the drm_mode_create_from_cmdline_
all I could find that cares
about named modes are drm_client. Did I miss something here?
Apart from that:
Reviewed-by: Noralf Trønnes
> The plan is to remove that need and move the named mode handling out of
> drivers and into the core, and only rely on modes and properties. Let
gt; ---
I would just squash this with the previous patch, either way:
Reviewed-by: Noralf Trønnes
> drivers/gpu/drm/drm_modes.c | 9 ++---
> include/drm/drm_connector.h | 7 +++
> 2 files changed, 13 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/drm_mo
d some code to allow it, and some unit tests to exercise that code.
>
> Signed-off-by: Maxime Ripard
>
> ---
I would have just squashed the named mode part of this patch together
with the 2 other named mode patches and keep just the video= option part
here, but up to you:
Reviewed-by: Noralf Trønnes
Den 26.10.2022 17.33, skrev max...@cerno.tech:
> Most of the TV connectors will need a similar get_modes implementation
> that will, depending on the drivers' capabilities, register the 480i and
> 576i modes.
>
> That implementation will also need to set the preferred flag and order
> the modes
Den 27.10.2022 00.02, skrev Mateusz Kwiatkowski:
> Hi Maxime,
>
> First of all, nice idea with the helper function that can be reused by
> different
> drivers. This is neat!
>
> But looking at this function, it feels a bit overcomplicated. You're creating
> the two modes, then checking which
Den 07.11.2022 11.07, skrev Maxime Ripard:
> Hi Noralf,
>
> On Sun, Nov 06, 2022 at 05:59:23PM +0100, Noralf Trønnes wrote:
>>
>>
>> Den 27.10.2022 00.02, skrev Mateusz Kwiatkowski:
>>> Hi Maxime,
>>>
>>> First of all, nice idea with th
Den 07.11.2022 11.21, skrev Maxime Ripard:
> Hi Noralf,
>
> I'll leave aside your comments on the code, since we'll use your
> implementation.
>
> On Sun, Nov 06, 2022 at 05:33:48PM +0100, Noralf Trønnes wrote:
>> Den 26.10.2022 17.33, skrev max...@cer
named_mode->flags &
> DRM_MODE_FLAG_INTERLACE);
> + if (!mode)
> + return NULL;
> +
> + return mode;
You can just return the result from drm_analog_tv_mode() directly.
With those considered:
Rev
Den 07.11.2022 15.16, skrev Maxime Ripard:
> Now that we can easily extend the named modes list, let's add a few more
> analog TV modes that were used in the wild, and some unit tests to make
> sure it works as intended.
>
> Signed-off-by: Maxime Ripard
>
> ---
> Changes in v6:
> - Renamed th
Den 07.11.2022 15.16, skrev Maxime Ripard:
> From: Noralf Trønnes
>
> Most of the TV connectors will need a similar get_modes implementation
> that will, depending on the drivers' capabilities, register the 480i and
> 576i modes.
>
> That implementation will also
Den 07.11.2022 19.03, skrev Noralf Trønnes:
>
>
> Den 07.11.2022 15.16, skrev Maxime Ripard:
>> Now that we can easily extend the named modes list, let's add a few more
>> analog TV modes that were used in the wild, and some unit tests to make
>> sure it works
Den 07.11.2022 18.49, skrev Noralf Trønnes:
>
>
> Den 07.11.2022 15.16, skrev Maxime Ripard:
>> The framework will get the drm_display_mode from the drm_cmdline_mode it
>> got by parsing the video command line argument by calling
>> drm_connector_pick_cmdline_mode
1920, 1080);
> + mutex_unlock(&drm->mode_config.mutex);
> + KUNIT_ASSERT_GT(test, ret, 0);
> +
> + mode = drm_connector_pick_cmdline_mode(connector);
> + KUNIT_ASSERT_NOT_NULL(test, mode);
> +
> + KUNIT_EXPECT_TRUE(test, drm_mo
te the
> drm_display_mode we mean when passing a named mode.
>
> Tested-by: Mateusz Kwiatkowski
> Signed-off-by: Maxime Ripard
>
> ---
Reviewed-by: Noralf Trønnes
e a proper mode, and we
> thus can use the usual matching algo on timings, and can simply drop the
> name match.
>
> Suggested-by: Noralf Trønnes
> Signed-off-by: Maxime Ripard
>
> ---
Reviewed-by: Noralf Trønnes
t_test.c | 54
> +
> 2 files changed, 56 insertions(+)
>
This needs an entry in modedb.rst so people know named modes exist, with
that:
Reviewed-by: Noralf Trønnes
Den 14.11.2022 14.00, skrev Maxime Ripard:
> KMS supports a number of named modes already, but it's never been
> documented anywhere, let's fix that.
>
> Signed-off-by: Maxime Ripard
>
> ---
Reviewed-by: Noralf Trønnes
Den 17.11.2022 10.28, skrev Maxime Ripard:
> That file is included directly, so we can't use any MODULE macro. Let's
> leave a comment to avoid any future mistake.
>
> Signed-off-by: Maxime Ripard
> ---
Reviewed-by: Noralf Trønnes
SC-443" },
> + { DRM_MODE_TV_MODE_NTSC_J, "NTSC-J" },
> + { DRM_MODE_TV_MODE_PAL, "PAL" },
> + { DRM_MODE_TV_MODE_PAL_M, "PAL-M" },
> + { DRM_MODE_TV_MODE_PAL_N, "PAL-N" },
> + { DRM_MODE_TV_MODE_SECAM, "SECAM
solution for these NTSC and PAL modes, but AIUI this is part of a
grander plan to support devices with other timings.
Acked-by: Noralf Trønnes
On 8/16/24 14:22, Thomas Zimmermann wrote:
> Call drm_client_setup() to run the kernel's default client setup
> for DRM. Set fbdev_probe in struct drm_driver, so that the client
> setup can start the common fbdev client.
>
> Signed-off-by: Thomas Zimmermann
&
On 8/16/24 14:22, Thomas Zimmermann wrote:
> Call drm_client_setup() to run the kernel's default client setup
> for DRM. Set fbdev_probe in struct drm_driver, so that the client
> setup can start the common fbdev client.
>
> Signed-off-by: Thomas Zimmermann
&
On 8/16/24 14:22, Thomas Zimmermann wrote:
> Call drm_client_setup() to run the kernel's default client setup
> for DRM. Set fbdev_probe in struct drm_driver, so that the client
> setup can start the common fbdev client.
>
> Signed-off-by: Thomas Zimmermann
&
On 8/16/24 14:23, Thomas Zimmermann wrote:
> Call drm_client_setup() to run the kernel's default client setup
> for DRM. Set fbdev_probe in struct drm_driver, so that the client
> setup can start the common fbdev client.
>
> Signed-off-by: Thomas Zimmermann
&
On 8/16/24 14:23, Thomas Zimmermann wrote:
> Call drm_client_setup() to run the kernel's default client setup
> for DRM. Set fbdev_probe in struct drm_driver, so that the client
> setup can start the common fbdev client.
>
> Signed-off-by: Thomas Zimmermann
&
evil calling contexts.
>
> v2: Rebase
>
> Signed-off-by: Daniel Vetter
> Cc: Ben Skeggs
> Cc: nouveau@lists.freedesktop.org
> ---
Acked-by: Noralf Trønnes
___
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau
reset,
.detect = tinydrm_connector_detect,
.fill_modes = drm_helper_probe_single_connector_modes,
Acked-by: Noralf Trønnes
___
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau
Den 09.08.2017 01.42, skrev Joe Kniss:
Because all drivers currently use gem objects for framebuffer planes,
the virtual create_handle() is not required. This change adds a
struct drm_gem_object *gems[4] field to drm_framebuffer and removes
create_handle() function pointer from drm_framebuffer_
85 matches
Mail list logo