From: kernel test robot <lkp@intel.com>
To: kbuild@lists.01.org
Subject: drivers/net/ethernet/huawei/hinic/hinic_ethtool.c:193 hinic_add_ethtool_link_mode() warn: should '1 << be a 64 bit
Date: Tue, 24 Nov 2020 15:15:44 +0800 [thread overview]
Message-ID: <202011241540.4vmap8b9-lkp@intel.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 2876 bytes --]
CC: kbuild-all(a)lists.01.org
CC: linux-kernel(a)vger.kernel.org
TO: Luo bin <luobin9@huawei.com>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: d5beb3140f91b1c8a3d41b14d729aefa4dcc58bc
commit: 01f2b3dac8c4bebeb0ec15c4b7b59993766493cc hinic: add link_ksettings ethtool_ops support
date: 7 months ago
:::::: branch date: 8 hours ago
:::::: commit date: 7 months ago
config: i386-randconfig-m021-20201124 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
New smatch warnings:
drivers/net/ethernet/huawei/hinic/hinic_ethtool.c:193 hinic_add_ethtool_link_mode() warn: should '1 << hw_to_ethtool_link_mode_table[idx]->link_mode_bit' be a 64 bit type?
Old smatch warnings:
drivers/net/ethernet/huawei/hinic/hinic_ethtool.c:196 hinic_add_ethtool_link_mode() warn: should '1 << hw_to_ethtool_link_mode_table[idx]->link_mode_bit' be a 64 bit type?
vim +193 drivers/net/ethernet/huawei/hinic/hinic_ethtool.c
01f2b3dac8c4beb Luo bin 2020-05-11 178
01f2b3dac8c4beb Luo bin 2020-05-11 179 static void hinic_add_ethtool_link_mode(struct cmd_link_settings *link_settings,
01f2b3dac8c4beb Luo bin 2020-05-11 180 enum hinic_link_mode hw_link_mode,
01f2b3dac8c4beb Luo bin 2020-05-11 181 u32 name)
01f2b3dac8c4beb Luo bin 2020-05-11 182 {
01f2b3dac8c4beb Luo bin 2020-05-11 183 enum hinic_link_mode link_mode;
01f2b3dac8c4beb Luo bin 2020-05-11 184 int idx = 0;
01f2b3dac8c4beb Luo bin 2020-05-11 185
01f2b3dac8c4beb Luo bin 2020-05-11 186 for (link_mode = 0; link_mode < HINIC_LINK_MODE_NUMBERS; link_mode++) {
01f2b3dac8c4beb Luo bin 2020-05-11 187 if (hw_link_mode & ((u32)1 << link_mode)) {
01f2b3dac8c4beb Luo bin 2020-05-11 188 idx = hinic_get_link_mode_index(link_mode);
01f2b3dac8c4beb Luo bin 2020-05-11 189 if (idx >= HINIC_LINK_MODE_NUMBERS)
01f2b3dac8c4beb Luo bin 2020-05-11 190 continue;
01f2b3dac8c4beb Luo bin 2020-05-11 191
01f2b3dac8c4beb Luo bin 2020-05-11 192 if (name == GET_SUPPORTED_MODE)
01f2b3dac8c4beb Luo bin 2020-05-11 @193 ETHTOOL_ADD_SUPPORTED_SPEED_LINK_MODE
01f2b3dac8c4beb Luo bin 2020-05-11 194 (link_settings, idx);
01f2b3dac8c4beb Luo bin 2020-05-11 195 else
01f2b3dac8c4beb Luo bin 2020-05-11 196 ETHTOOL_ADD_ADVERTISED_SPEED_LINK_MODE
01f2b3dac8c4beb Luo bin 2020-05-11 197 (link_settings, idx);
01f2b3dac8c4beb Luo bin 2020-05-11 198 }
01f2b3dac8c4beb Luo bin 2020-05-11 199 }
01f2b3dac8c4beb Luo bin 2020-05-11 200 }
01f2b3dac8c4beb Luo bin 2020-05-11 201
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 37273 bytes --]
next reply other threads:[~2020-11-24 7:15 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-24 7:15 kernel test robot [this message]
-- strict thread matches above, loose matches on Subject: below --
2020-10-13 5:58 drivers/net/ethernet/huawei/hinic/hinic_ethtool.c:193 hinic_add_ethtool_link_mode() warn: should '1 << be a 64 bit kernel test robot
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=202011241540.4vmap8b9-lkp@intel.com \
--to=lkp@intel.com \
--cc=kbuild@lists.01.org \
/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.