From: kernel test robot <lkp@intel.com>
To: Nick Desaulniers <ndesaulniers@google.com>
Cc: oe-kbuild-all@lists.linux.dev
Subject: [clangbuiltlinux:question_mark_operator 5/5] drivers/gpu/drm/drm_atomic.c:1305:1: warning: control reaches end of non-void function
Date: Sat, 12 Sep 2026 11:48:52 +0800 [thread overview]
Message-ID: <202609121119.nj8F5jyV-lkp@intel.com> (raw)
tree: https://github.com/ClangBuiltLinux/linux question_mark_operator
head: 532a7ac2d57bb5674f5feffb4ba378f8a32f3bcf
commit: 532a7ac2d57bb5674f5feffb4ba378f8a32f3bcf [5/5] drm: atomic: use try operator ('?') and member access chaining
config: i386-randconfig-r132-20260912 (https://download.01.org/0day-ci/archive/20260912/202609121119.nj8F5jyV-lkp@intel.com/config)
compiler: gcc-14 (Debian 14.2.0-19) 14.2.0
sparse: v0.6.5-rc1
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260912/202609121119.nj8F5jyV-lkp@intel.com/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 <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202609121119.nj8F5jyV-lkp@intel.com/
All warnings (new ones prefixed by >>):
drivers/gpu/drm/drm_atomic.c: In function 'drm_atomic_get_old_crtc_for_encoder':
drivers/gpu/drm/drm_atomic.c:1302:78: error: expected expression before ';' token
1302 | connector = drm_atomic_get_old_connector_for_encoder(state, encoder)?;
| ^
drivers/gpu/drm/drm_atomic.c:1304:69: error: expected expression before '->' token
1304 | return drm_atomic_get_old_connector_state(state, connector)?->crtc;
| ^~
drivers/gpu/drm/drm_atomic.c: In function 'drm_atomic_get_new_crtc_for_encoder':
drivers/gpu/drm/drm_atomic.c:1325:78: error: expected expression before ';' token
1325 | connector = drm_atomic_get_new_connector_for_encoder(state, encoder)?;
| ^
drivers/gpu/drm/drm_atomic.c:1327:69: error: expected expression before '->' token
1327 | return drm_atomic_get_new_connector_state(state, connector)?->crtc;
| ^~
drivers/gpu/drm/drm_atomic.c: In function 'drm_atomic_get_old_crtc_for_encoder':
>> drivers/gpu/drm/drm_atomic.c:1305:1: warning: control reaches end of non-void function [-Wreturn-type]
1305 | }
| ^
drivers/gpu/drm/drm_atomic.c: In function 'drm_atomic_get_new_crtc_for_encoder':
drivers/gpu/drm/drm_atomic.c:1328:1: warning: control reaches end of non-void function [-Wreturn-type]
1328 | }
| ^
vim +1305 drivers/gpu/drm/drm_atomic.c
a7e4886e06f723 Maxime Ripard 2025-03-13 1283
a7e4886e06f723 Maxime Ripard 2025-03-13 1284
7b9a9e35e45def Vinod Polimera 2023-03-02 1285 /**
7b9a9e35e45def Vinod Polimera 2023-03-02 1286 * drm_atomic_get_old_crtc_for_encoder - Get old crtc for an encoder
7b9a9e35e45def Vinod Polimera 2023-03-02 1287 * @state: Atomic state
7b9a9e35e45def Vinod Polimera 2023-03-02 1288 * @encoder: The encoder to fetch the crtc state for
7b9a9e35e45def Vinod Polimera 2023-03-02 1289 *
7b9a9e35e45def Vinod Polimera 2023-03-02 1290 * This function finds and returns the crtc that was connected to @encoder
7b9a9e35e45def Vinod Polimera 2023-03-02 1291 * as specified by the @state.
7b9a9e35e45def Vinod Polimera 2023-03-02 1292 *
7b9a9e35e45def Vinod Polimera 2023-03-02 1293 * Returns: The old crtc connected to @encoder, or NULL if the encoder is
7b9a9e35e45def Vinod Polimera 2023-03-02 1294 * not connected.
7b9a9e35e45def Vinod Polimera 2023-03-02 1295 */
7b9a9e35e45def Vinod Polimera 2023-03-02 1296 struct drm_crtc *
5164f7e7ff8ec7 Maxime Ripard 2026-04-27 1297 drm_atomic_get_old_crtc_for_encoder(struct drm_atomic_commit *state,
7b9a9e35e45def Vinod Polimera 2023-03-02 1298 struct drm_encoder *encoder)
7b9a9e35e45def Vinod Polimera 2023-03-02 1299 {
7b9a9e35e45def Vinod Polimera 2023-03-02 1300 struct drm_connector *connector;
7b9a9e35e45def Vinod Polimera 2023-03-02 1301
532a7ac2d57bb5 Nick Desaulniers 2026-09-10 1302 connector = drm_atomic_get_old_connector_for_encoder(state, encoder)?;
7b9a9e35e45def Vinod Polimera 2023-03-02 1303
532a7ac2d57bb5 Nick Desaulniers 2026-09-10 1304 return drm_atomic_get_old_connector_state(state, connector)?->crtc;
7b9a9e35e45def Vinod Polimera 2023-03-02 @1305 }
7b9a9e35e45def Vinod Polimera 2023-03-02 1306 EXPORT_SYMBOL(drm_atomic_get_old_crtc_for_encoder);
7b9a9e35e45def Vinod Polimera 2023-03-02 1307
:::::: The code at line 1305 was first introduced by commit
:::::: 7b9a9e35e45def496b0a5b3f206bb4efa712ea4a drm: add helper functions to retrieve old and new crtc
:::::: TO: Vinod Polimera <quic_vpolimer@quicinc.com>
:::::: CC: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
reply other threads:[~2026-09-12 3:49 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=202609121119.nj8F5jyV-lkp@intel.com \
--to=lkp@intel.com \
--cc=ndesaulniers@google.com \
--cc=oe-kbuild-all@lists.linux.dev \
/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 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.