dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
From: Daniel Latypov <dlatypov@google.com>
To: "José Expósito" <jose.exposito89@gmail.com>
Cc: airlied@linux.ie, javierm@redhat.com,
	dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org,
	Maxime Ripard <maxime@cerno.tech>,
	tzimmermann@suse.de, kunit-dev@googlegroups.com
Subject: Re: [RFC PATCH 1/1] drm/format-helper: Add KUnit tests for drm_fb_xrgb8888_to_rgb332()
Date: Tue, 31 May 2022 13:42:36 -0700	[thread overview]
Message-ID: <CAGS_qxoWTo+TqAMOaoD=XEQhFp0K0QN4LS4XRQxFR9aTv=XmfA@mail.gmail.com> (raw)
In-Reply-To: <20220531184454.GA237621@elementary>

On Tue, May 31, 2022 at 11:45 AM José Expósito
<jose.exposito89@gmail.com> wrote:
> >
> > From above, a)
> > Specifically here, it'd be encouraged to instead do
> >   depends on DRM && KUNIT=y && DRM_KMS_HELPER
>
> My first attempt was to go with:
>
>         depends on KUNIT=y && DRM && DRM_KMS_HELPER
>
> However, when I try to run the tests I get this error:
>
>         $ ./tools/testing/kunit/kunit.py run --kunitconfig=drivers/gpu/drm --arch=x86_64
>         Regenerating .config ...
>         Populating config with:
>         $ make ARCH=x86_64 olddefconfig O=.kunit
>         ERROR:root:Not all Kconfig options selected in kunitconfig were in the generated .config.
>         This is probably due to unsatisfied dependencies.
>         Missing: CONFIG_DRM_KMS_HELPER=y, CONFIG_DRM_FORMAR_HELPER_TEST=y
>
> I wasn't able to figure out why that was happening, so I decided to use
> "select", which seems to solve the problem.
>
> Do you know why this could be happening?

Ah, you should probably ignore my suggestion then.

Looking at the Kconfig file, it's defined as
  config DRM_KMS_HELPER
  tristate
  depends on DRM
  help
    CRTC helpers for KMS drivers.

Notably, the config lacks a description string.
IIUC, this makes it a "hidden" kconfig option, i.e. you can't directly
select it yourself in a .config, it must be selected by another
kconfig option.

E.g. you can try selecting it manually and see it fail via:
$ ./tools/testing/kunit/kunit.py config --arch=x86_64
--kconfig_add=CONFIG_DRM=y --kconfig_add=CONFIG_DRM_KMS_HELPER=y
...
Missing: CONFIG_DRM_KMS_HELPER=y

So having the test select it makes the most sense, unless there's a
better kconfig option to automatically select it (I have no idea,
someone with knowledge of the DRM code might though).

Daniel

  reply	other threads:[~2022-05-31 20:42 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-30 10:20 [RFC PATCH 0/1] KUnit tests for drm_format_helper José Expósito
2022-05-30 10:20 ` [RFC PATCH 1/1] drm/format-helper: Add KUnit tests for drm_fb_xrgb8888_to_rgb332() José Expósito
2022-05-30 13:11   ` Maxime Ripard
2022-05-30 16:29     ` José Expósito
2022-05-30 22:57       ` Daniel Latypov
2022-05-31 18:44         ` José Expósito
2022-05-31 20:42           ` Daniel Latypov [this message]
2022-06-02 17:12       ` David Gow
2022-06-02 17:29         ` Javier Martinez Canillas
2022-06-02 17:45           ` Daniel Latypov
2022-06-02 16:26   ` Javier Martinez Canillas
2022-06-02 16:53     ` Daniel Latypov
2022-06-02 17:07     ` David Gow
2022-06-02 17:21       ` Javier Martinez Canillas
2022-06-06  9:43         ` José Expósito

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAGS_qxoWTo+TqAMOaoD=XEQhFp0K0QN4LS4XRQxFR9aTv=XmfA@mail.gmail.com' \
    --to=dlatypov@google.com \
    --cc=airlied@linux.ie \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=javierm@redhat.com \
    --cc=jose.exposito89@gmail.com \
    --cc=kunit-dev@googlegroups.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maxime@cerno.tech \
    --cc=tzimmermann@suse.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).