* drivers/gpu/drm/i915/gt/intel_engine.h:320:25: error: dereference of NULL 'engine' [CWE-476]
@ 2022-08-05 5:38 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2022-08-05 5:38 UTC (permalink / raw)
To: kbuild
[-- Attachment #1: Type: text/plain, Size: 6744 bytes --]
::::::
:::::: Manual check reason: "low confidence bisect report"
::::::
BCC: lkp(a)intel.com
CC: kbuild-all(a)lists.01.org
CC: linux-kernel(a)vger.kernel.org
TO: Matthew Brost <matthew.brost@intel.com>
CC: John Harrison <John.C.Harrison@Intel.com>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: b2a88c212e652e94f1e4b635910972ac57ba4e97
commit: 573ba126aef37c8315e5bb68d2dad515efa96994 drm/i915/guc: Capture error state on context reset
date: 1 year ago
:::::: branch date: 2 hours ago
:::::: commit date: 1 year ago
config: x86_64-randconfig-c001-20220801 (https://download.01.org/0day-ci/archive/20220805/202208051316.FPB75l1Y-lkp(a)intel.com/config)
compiler: gcc-11 (Debian 11.3.0-3) 11.3.0
reproduce (this is a W=1 build):
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=573ba126aef37c8315e5bb68d2dad515efa96994
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 573ba126aef37c8315e5bb68d2dad515efa96994
# save the config file
make
If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@intel.com>
All errors (new ones prefixed by >>):
In file included from drivers/gpu/drm/i915/i915_drv.h:84,
from drivers/gpu/drm/i915/gt/intel_context.h:14,
from drivers/gpu/drm/i915/gem/i915_gem_context.h:12,
from drivers/gpu/drm/i915/gt/uc/intel_guc_submission.c:8:
drivers/gpu/drm/i915/gt/intel_engine.h: In function 'capture_error_state':
>> drivers/gpu/drm/i915/gt/intel_engine.h:320:25: error: dereference of NULL 'engine' [CWE-476] [-Werror=analyzer-null-dereference]
320 | engine->hung_ce = ce;
| ~~~~~~~~~~~~~~~~^~~~
'capture_error_state': events 1-2
|
|drivers/gpu/drm/i915/gt/uc/intel_guc_submission.c:2186:13:
| 2186 | static void capture_error_state(struct intel_guc *guc,
| | ^~~~~~~~~~~~~~~~~~~
| | |
| | (1) entry to 'capture_error_state'
|......
| 2191 | struct intel_engine_cs *engine = __context_to_physical_engine(ce);
| | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| | |
| | (2) calling '__context_to_physical_engine' from 'capture_error_state'
|
+--> '__context_to_physical_engine': events 3-6
|
| 650 | __context_to_physical_engine(struct intel_context *ce)
| | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
| | |
| | (3) entry to '__context_to_physical_engine'
|......
| 654 | if (intel_engine_is_virtual(engine))
| | ~
| | |
| | (4) following 'true' branch...
| 655 | engine = guc_virtual_get_sibling(engine, 0);
| | ~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| | | |
| | | (6) calling 'guc_virtual_get_sibling' from '__context_to_physical_engine'
| | (5) ...to here
|
+--> 'guc_virtual_get_sibling': event 7
|
| 636 | guc_virtual_get_sibling(struct intel_engine_cs *ve, unsigned int sibling)
| | ^~~~~~~~~~~~~~~~~~~~~~~
| | |
| | (7) entry to 'guc_virtual_get_sibling'
|
'guc_virtual_get_sibling': event 8
|
|drivers/gpu/drm/i915/i915_drv.h:1248:14:
| 1248 | (tmp__) ? \
| | ^
| | |
| | (8) following 'false' branch...
drivers/gpu/drm/i915/gt/uc/intel_guc_submission.c:642:9: note: in expansion of macro 'for_each_engine_masked'
| 642 | for_each_engine_masked(engine, ve->gt, mask, tmp)
| | ^~~~~~~~~~~~~~~~~~~~~~
|
'guc_virtual_get_sibling': event 9
|
|cc1:
| (9): ...to here
|
<------+
|
'__context_to_physical_engine': event 10
|
| 655 | engine = guc_virtual_get_sibling(engine, 0);
| | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| | |
| | (10) return of NULL to '__context_to_physical_engine' from 'guc_virtual_get_sibling'
|
<------+
|
'capture_error_state': event 11
|
| 2191 | struct intel_engine_cs *engine = __context_to_physical_engine(ce);
| | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| | |
| | (11) return of NULL to 'capture_error_state' from '__context_to_physical_engine'
|
'capture_error_state': event 12
|
|drivers/gpu/drm/i915/gt/intel_engine.h:320:25:
| 320 | engine->hung_ce = ce;
| | ~~~~~~~~~~~~~~~~^~~~
| | |
| | (12) dereference of NULL 'engine'
|
cc1: all warnings being treated as errors
vim +/engine +320 drivers/gpu/drm/i915/gt/intel_engine.h
556120256ecd25 Matthew Brost 2021-07-26 315
573ba126aef37c Matthew Brost 2021-07-26 316 static inline void
573ba126aef37c Matthew Brost 2021-07-26 317 intel_engine_set_hung_context(struct intel_engine_cs *engine,
573ba126aef37c Matthew Brost 2021-07-26 318 struct intel_context *ce)
573ba126aef37c Matthew Brost 2021-07-26 319 {
573ba126aef37c Matthew Brost 2021-07-26 @320 engine->hung_ce = ce;
573ba126aef37c Matthew Brost 2021-07-26 321 }
573ba126aef37c Matthew Brost 2021-07-26 322
--
0-DAY CI Kernel Test Service
https://01.org/lkp
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2022-08-05 5:38 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-08-05 5:38 drivers/gpu/drm/i915/gt/intel_engine.h:320:25: error: dereference of NULL 'engine' [CWE-476] kernel test robot
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.