Le 18/08/2026 à 11:23 PM, Yury Norov a écrit :
> The continuation-record KUnit tests are currently built whenever both
> Nova Core and KUnit are enabled, providing no way to select the tests
> independently.
> 
> Add CONFIG_NOVA_CORE_KUNIT_TEST and use it to guard the test suite.
> Follow the usual KUnit convention of enabling the option through
> CONFIG_KUNIT_ALL_TESTS.
> 
> Assisted-by: Codex:gpt-5.6-sol
> Signed-off-by: Yury Norov <[email protected]>
> ---


Thanks. I imagine this should go in via drm, rather than the KUnit tree.
I'm not totally convinced by patch #2, but let's get this patch in
regardless. Maybe it even should have a Fixes tag:

Fixes: 0499a3826c2f ("gpu: nova-core: gsp: add tests for continuation records")
Acked-by: David Gow <[email protected]>

Cheers,
-- David

>  drivers/gpu/nova-core/Kconfig                  | 12 ++++++++++++
>  drivers/gpu/nova-core/gsp/cmdq/continuation.rs |  1 +
>  2 files changed, 13 insertions(+)
> 
> diff --git a/drivers/gpu/nova-core/Kconfig b/drivers/gpu/nova-core/Kconfig
> index f918f69e0599..d05c2c1d46d9 100644
> --- a/drivers/gpu/nova-core/Kconfig
> +++ b/drivers/gpu/nova-core/Kconfig
> @@ -15,3 +15,15 @@ config NOVA_CORE
>         This driver is work in progress and may not be functional.
>  
>         If M is selected, the module will be called nova-core.
> +
> +config NOVA_CORE_KUNIT_TEST
> +     bool "KUnit tests for Nova Core" if !KUNIT_ALL_TESTS
> +     depends on NOVA_CORE && KUNIT
> +     default KUNIT_ALL_TESTS
> +     help
> +       This option enables KUnit tests for internal components of the Nova
> +       Core driver. The tests currently do not require GPU hardware. These
> +       are only for development and testing, not for regular kernel use
> +       cases.
> +
> +       If unsure, say N.
> diff --git a/drivers/gpu/nova-core/gsp/cmdq/continuation.rs 
> b/drivers/gpu/nova-core/gsp/cmdq/continuation.rs
> index 05e904f18097..c0aa16c8fbf4 100644
> --- a/drivers/gpu/nova-core/gsp/cmdq/continuation.rs
> +++ b/drivers/gpu/nova-core/gsp/cmdq/continuation.rs
> @@ -167,6 +167,7 @@ fn init_variable_payload(
>      }
>  }
>  
> +#[cfg(CONFIG_NOVA_CORE_KUNIT_TEST)]
>  #[kunit_tests(nova_core_gsp_continuation)]
>  mod tests {
>      use super::*;


Reply via email to