From: kernel test robot <lkp@intel.com>
To: Joseph CHAMG <josright123@gmail.com>
Cc: llvm@lists.linux.dev, kbuild-all@lists.01.org
Subject: Re: [PATCH v10, 2/2] net: Add dm9051 driver
Date: Thu, 6 Jan 2022 07:38:43 +0800 [thread overview]
Message-ID: <202201060738.5ZBat35r-lkp@intel.com> (raw)
In-Reply-To: <20220105081728.4289-3-josright123@gmail.com>
Hi Joseph,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on 9d922f5df53844228b9f7c62f2593f4f06c0b69b]
url: https://github.com/0day-ci/linux/commits/Joseph-CHAMG/ADD-DM9051-ETHERNET-DRIVER/20220105-162144
base: 9d922f5df53844228b9f7c62f2593f4f06c0b69b
config: hexagon-allyesconfig (https://download.01.org/0day-ci/archive/20220106/202201060738.5ZBat35r-lkp@intel.com/config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project d5b6e30ed3acad794dd0aec400e617daffc6cc3d)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://github.com/0day-ci/linux/commit/4a2b192e52a57fee2e5d3452eeb1f3764ef4086c
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Joseph-CHAMG/ADD-DM9051-ETHERNET-DRIVER/20220105-162144
git checkout 4a2b192e52a57fee2e5d3452eeb1f3764ef4086c
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=hexagon SHELL=/bin/bash drivers/media/platform/atmel/ drivers/media/platform/sti/bdisp/ drivers/media/platform/sti/delta/ drivers/media/platform/sti/hva/ drivers/mmc/host/ drivers/net/ethernet/davicom/ drivers/staging/rtl8723bs/ fs/xfs/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All warnings (new ones prefixed by >>):
>> drivers/net/ethernet/davicom/dm9051.c:153:52: warning: use of logical '&&' with constant operand [-Wconstant-logical-operand]
regmap_write(db->regmap, DM9051_EPDRH, (val >> 8) && 0xff);
^ ~~~~
drivers/net/ethernet/davicom/dm9051.c:153:52: note: use '&' for a bitwise operation
regmap_write(db->regmap, DM9051_EPDRH, (val >> 8) && 0xff);
^~
&
drivers/net/ethernet/davicom/dm9051.c:153:52: note: remove constant to silence this warning
regmap_write(db->regmap, DM9051_EPDRH, (val >> 8) && 0xff);
~^~~~~~~
1 warning generated.
vim +153 drivers/net/ethernet/davicom/dm9051.c
145
146 static int regmap_dm9051_phy_reg_write(void *context, unsigned int reg, unsigned int val)
147 {
148 struct board_info *db = context;
149 int ret;
150
151 regmap_write(db->regmap, DM9051_EPAR, DM9051_PHY | reg);
152 regmap_write(db->regmap, DM9051_EPDRL, val & 0xff);
> 153 regmap_write(db->regmap, DM9051_EPDRH, (val >> 8) && 0xff);
154 regmap_write(db->regmap, DM9051_EPCR, EPCR_EPOS | EPCR_ERPRW);
155 ret = dm9051_map_poll(db);
156 regmap_write(db->regmap, DM9051_EPCR, 0x0);
157
158 if (reg == MII_BMCR && !(val & 0x0800))
159 mdelay(1); /* need for if activate phyxcer */
160
161 return ret;
162 }
163
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
WARNING: multiple messages have this Message-ID (diff)
From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: Re: [PATCH v10, 2/2] net: Add dm9051 driver
Date: Thu, 06 Jan 2022 07:38:43 +0800 [thread overview]
Message-ID: <202201060738.5ZBat35r-lkp@intel.com> (raw)
In-Reply-To: <20220105081728.4289-3-josright123@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 3301 bytes --]
Hi Joseph,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on 9d922f5df53844228b9f7c62f2593f4f06c0b69b]
url: https://github.com/0day-ci/linux/commits/Joseph-CHAMG/ADD-DM9051-ETHERNET-DRIVER/20220105-162144
base: 9d922f5df53844228b9f7c62f2593f4f06c0b69b
config: hexagon-allyesconfig (https://download.01.org/0day-ci/archive/20220106/202201060738.5ZBat35r-lkp(a)intel.com/config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project d5b6e30ed3acad794dd0aec400e617daffc6cc3d)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://github.com/0day-ci/linux/commit/4a2b192e52a57fee2e5d3452eeb1f3764ef4086c
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Joseph-CHAMG/ADD-DM9051-ETHERNET-DRIVER/20220105-162144
git checkout 4a2b192e52a57fee2e5d3452eeb1f3764ef4086c
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=hexagon SHELL=/bin/bash drivers/media/platform/atmel/ drivers/media/platform/sti/bdisp/ drivers/media/platform/sti/delta/ drivers/media/platform/sti/hva/ drivers/mmc/host/ drivers/net/ethernet/davicom/ drivers/staging/rtl8723bs/ fs/xfs/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All warnings (new ones prefixed by >>):
>> drivers/net/ethernet/davicom/dm9051.c:153:52: warning: use of logical '&&' with constant operand [-Wconstant-logical-operand]
regmap_write(db->regmap, DM9051_EPDRH, (val >> 8) && 0xff);
^ ~~~~
drivers/net/ethernet/davicom/dm9051.c:153:52: note: use '&' for a bitwise operation
regmap_write(db->regmap, DM9051_EPDRH, (val >> 8) && 0xff);
^~
&
drivers/net/ethernet/davicom/dm9051.c:153:52: note: remove constant to silence this warning
regmap_write(db->regmap, DM9051_EPDRH, (val >> 8) && 0xff);
~^~~~~~~
1 warning generated.
vim +153 drivers/net/ethernet/davicom/dm9051.c
145
146 static int regmap_dm9051_phy_reg_write(void *context, unsigned int reg, unsigned int val)
147 {
148 struct board_info *db = context;
149 int ret;
150
151 regmap_write(db->regmap, DM9051_EPAR, DM9051_PHY | reg);
152 regmap_write(db->regmap, DM9051_EPDRL, val & 0xff);
> 153 regmap_write(db->regmap, DM9051_EPDRH, (val >> 8) && 0xff);
154 regmap_write(db->regmap, DM9051_EPCR, EPCR_EPOS | EPCR_ERPRW);
155 ret = dm9051_map_poll(db);
156 regmap_write(db->regmap, DM9051_EPCR, 0x0);
157
158 if (reg == MII_BMCR && !(val & 0x0800))
159 mdelay(1); /* need for if activate phyxcer */
160
161 return ret;
162 }
163
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
next prev parent reply other threads:[~2022-01-05 23:38 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-05 8:17 [PATCH v10, 0/2] ADD DM9051 ETHERNET DRIVER Joseph CHAMG
2022-01-05 8:17 ` [PATCH v10, 1/2] yaml: Add dm9051 SPI network yaml file Joseph CHAMG
2022-01-05 8:17 ` [PATCH v10, 2/2] net: Add dm9051 driver Joseph CHAMG
2022-01-05 12:31 ` Andy Shevchenko
2022-01-05 16:54 ` Andrew Lunn
2022-01-05 23:38 ` kernel test robot [this message]
2022-01-05 23:38 ` 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=202201060738.5ZBat35r-lkp@intel.com \
--to=lkp@intel.com \
--cc=josright123@gmail.com \
--cc=kbuild-all@lists.01.org \
--cc=llvm@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.