[linux-next:master 3548/14447] drivers/gpu/drm/i915/display/tests/intel_dp_link_test.c:72:59: sparse: sparse: not a function init

kernel test robot <[email protected]>
Newsgroups dev.linux.lists.oe-kbuild
Message-ID <[email protected]>
:::::: 
:::::: Manual check reason: "low confidence static check warning: drivers/gpu/drm/i915/display/tests/intel_dp_link_test.c:72:59: sparse: sparse: not a function init"
:::::: 

BCC: [email protected]
CC: [email protected]
TO: Imre Deak <[email protected]>
CC: "Michał Grzelak" <[email protected]>

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   5e6de6a2b522f659defacb1551d0465ba6ce13cf
commit: 2eb9982ff179e648675b6c5b345b9ed509fc3361 [3548/14447] drm/i915/kunit: Export link training and caps funcs for testing
:::::: branch date: 33 hours ago
:::::: commit date: 5 weeks ago
config: i386-randconfig-063-20260812 (https://download.01.org/0day-ci/archive/20260813/[email protected]/config)
compiler: clang version 22.1.3 (https://github.com/llvm/llvm-project e9846648fd6183ee6d8cbdb4502213fcf902a211)
sparse: v0.6.5-rc1
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260813/[email protected]/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <[email protected]>
| Closes: https://lore.kernel.org/r/[email protected]/

sparse warnings: (new ones prefixed by >>)
>> drivers/gpu/drm/i915/display/tests/intel_dp_link_test.c:72:59: sparse: sparse: not a function init
>> drivers/gpu/drm/i915/display/tests/intel_dp_link_test.c:83:36: sparse: sparse: not a function cleanup

vim +72 drivers/gpu/drm/i915/display/tests/intel_dp_link_test.c

d3340e92be326c Imre Deak 2026-07-01  46  
d3340e92be326c Imre Deak 2026-07-01  47  static int intel_dp_link_test_init(struct kunit *test)
d3340e92be326c Imre Deak 2026-07-01  48  {
df152476d00a46 Imre Deak 2026-07-01  49  	struct intel_digital_port *dig_port;
df152476d00a46 Imre Deak 2026-07-01  50  	struct intel_encoder *encoder;
df152476d00a46 Imre Deak 2026-07-01  51  	struct intel_dp *intel_dp;
df152476d00a46 Imre Deak 2026-07-01  52  
df152476d00a46 Imre Deak 2026-07-01  53  	/* Reset the dev state for each test. */
df152476d00a46 Imre Deak 2026-07-01  54  	memset(&test_ctx.dev, 0, sizeof(test_ctx.dev));
df152476d00a46 Imre Deak 2026-07-01  55  
df152476d00a46 Imre Deak 2026-07-01  56  	test_ctx.dev.generic_device.drm.dev = &test_ctx.dev.device;
df152476d00a46 Imre Deak 2026-07-01  57  
df152476d00a46 Imre Deak 2026-07-01  58  	test_ctx.dev.display.drm = &test_ctx.dev.generic_device.drm;
df152476d00a46 Imre Deak 2026-07-01  59  	test_ctx.dev.generic_device.display = &test_ctx.dev.display;
df152476d00a46 Imre Deak 2026-07-01  60  
df152476d00a46 Imre Deak 2026-07-01  61  	encoder = &test_ctx.dev.dig_port.base;
df152476d00a46 Imre Deak 2026-07-01  62  	encoder->base.dev = &test_ctx.dev.generic_device.drm;
df152476d00a46 Imre Deak 2026-07-01  63  
df152476d00a46 Imre Deak 2026-07-01  64  	dig_port = &test_ctx.dev.dig_port;
df152476d00a46 Imre Deak 2026-07-01  65  	dig_port->base.type = INTEL_OUTPUT_DP;
df152476d00a46 Imre Deak 2026-07-01  66  
df152476d00a46 Imre Deak 2026-07-01  67  	test_ctx.dev.connector.encoder = encoder;
df152476d00a46 Imre Deak 2026-07-01  68  
df152476d00a46 Imre Deak 2026-07-01  69  	intel_dp = &dig_port->dp;
df152476d00a46 Imre Deak 2026-07-01  70  	intel_dp->attached_connector = &test_ctx.dev.connector;
df152476d00a46 Imre Deak 2026-07-01  71  
2eb9982ff179e6 Imre Deak 2026-07-01 @72  	intel_dp->link.caps = test_ctx.link_caps_ops->init(intel_dp);
2eb9982ff179e6 Imre Deak 2026-07-01  73  
d3340e92be326c Imre Deak 2026-07-01  74  	test->priv = &test_ctx;
d3340e92be326c Imre Deak 2026-07-01  75  
d3340e92be326c Imre Deak 2026-07-01  76  	return 0;
d3340e92be326c Imre Deak 2026-07-01  77  }
d3340e92be326c Imre Deak 2026-07-01  78  
d3340e92be326c Imre Deak 2026-07-01  79  static void intel_dp_link_test_exit(struct kunit *test)
d3340e92be326c Imre Deak 2026-07-01  80  {
2eb9982ff179e6 Imre Deak 2026-07-01  81  	struct test_ctx *ctx = test->priv;
2eb9982ff179e6 Imre Deak 2026-07-01  82  
2eb9982ff179e6 Imre Deak 2026-07-01 @83  	ctx->link_caps_ops->cleanup(ctx->dev.dig_port.dp.link.caps);
d3340e92be326c Imre Deak 2026-07-01  84  }
d3340e92be326c Imre Deak 2026-07-01  85  

--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.