From: Dan Carpenter <dan.carpenter@oracle.com>
To: kbuild@lists.01.org, Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: lkp@intel.com, kbuild-all@lists.01.org, linux-kernel@vger.kernel.org
Subject: [kbuild] drivers/gpu/drm/aspeed/aspeed_gfx_drv.c:80:9: warning: Identical condition 'ret', second condition is always false
Date: Tue, 27 Oct 2020 20:52:52 +0300 [thread overview]
Message-ID: <20201027175252.GN18329@kadam> (raw)
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 4525c8781ec0701ce824e8bd379ae1b129e26568
commit: c2c25c1cf96927a0b6ddb6aaa063f1fdcc90d749 drm/aspeed: Use managed drmm_mode_config_cleanup
compiler: nds32le-linux-gcc (GCC) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
cppcheck possible warnings: (new ones prefixed by >>, may not real problems)
>> drivers/gpu/drm/aspeed/aspeed_gfx_drv.c:80:9: warning: Identical condition 'ret', second condition is always false [identicalConditionAfterEarlyExit]
return ret;
^
drivers/gpu/drm/aspeed/aspeed_gfx_drv.c:71:6: note: first condition
if (ret)
^
drivers/gpu/drm/aspeed/aspeed_gfx_drv.c:80:9: note: second condition
return ret;
^
vim +/ret +80 drivers/gpu/drm/aspeed/aspeed_gfx_drv.c
c2c25c1cf96927a Daniel Vetter 2020-09-04 66 static int aspeed_gfx_setup_mode_config(struct drm_device *drm)
4f2a8f5898ecd80 Joel Stanley 2019-04-03 67 {
c2c25c1cf96927a Daniel Vetter 2020-09-04 68 int ret;
c2c25c1cf96927a Daniel Vetter 2020-09-04 69
c2c25c1cf96927a Daniel Vetter 2020-09-04 70 ret = drmm_mode_config_init(drm);
c2c25c1cf96927a Daniel Vetter 2020-09-04 71 if (ret)
c2c25c1cf96927a Daniel Vetter 2020-09-04 72 return ret;
4f2a8f5898ecd80 Joel Stanley 2019-04-03 73
4f2a8f5898ecd80 Joel Stanley 2019-04-03 74 drm->mode_config.min_width = 0;
4f2a8f5898ecd80 Joel Stanley 2019-04-03 75 drm->mode_config.min_height = 0;
4f2a8f5898ecd80 Joel Stanley 2019-04-03 76 drm->mode_config.max_width = 800;
4f2a8f5898ecd80 Joel Stanley 2019-04-03 77 drm->mode_config.max_height = 600;
4f2a8f5898ecd80 Joel Stanley 2019-04-03 78 drm->mode_config.funcs = &aspeed_gfx_mode_config_funcs;
c2c25c1cf96927a Daniel Vetter 2020-09-04 79
c2c25c1cf96927a Daniel Vetter 2020-09-04 @80 return ret;
This should just be "return 0;"
4f2a8f5898ecd80 Joel Stanley 2019-04-03 81 }
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
_______________________________________________
kbuild mailing list -- kbuild@lists.01.org
To unsubscribe send an email to kbuild-leave@lists.01.org
reply other threads:[~2020-10-27 17:53 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=20201027175252.GN18329@kadam \
--to=dan.carpenter@oracle.com \
--cc=daniel.vetter@ffwll.ch \
--cc=kbuild-all@lists.01.org \
--cc=kbuild@lists.01.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lkp@intel.com \
/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