oe-kbuild-all.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Maximilian Weigand <mweigand@mweigand.net>,
	Linus Walleij <linus.walleij@linaro.org>,
	Dmitry Torokhov <dmitry.torokhov@gmail.com>,
	linux-input@vger.kernel.org, linux-kernel@vger.kernel.org,
	devicetree@vger.kernel.org
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev,
	Maximilian Weigand <mweigand@mweigand.net>,
	Alistair Francis <alistair@alistair23.me>
Subject: Re: [PATCH 6/6] Input: cyttsp5: implement proper sleep and wakeup procedures
Date: Tue, 28 Mar 2023 02:11:57 +0800	[thread overview]
Message-ID: <202303280119.UlD7s4Rk-lkp@intel.com> (raw)
In-Reply-To: <20230323135205.1160879-7-mweigand@mweigand.net>

Hi Maximilian,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on dtor-input/next]
[also build test WARNING on dtor-input/for-linus linus/master v6.3-rc4 next-20230327]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/Maximilian-Weigand/Input-cyttsp5-fix-array-length/20230323-215957
base:   https://git.kernel.org/pub/scm/linux/kernel/git/dtor/input.git next
patch link:    https://lore.kernel.org/r/20230323135205.1160879-7-mweigand%40mweigand.net
patch subject: [PATCH 6/6] Input: cyttsp5: implement proper sleep and wakeup procedures
config: i386-randconfig-a011-20230327 (https://download.01.org/0day-ci/archive/20230328/202303280119.UlD7s4Rk-lkp@intel.com/config)
compiler: clang version 14.0.6 (https://github.com/llvm/llvm-project f28c006a5895fc0e329fe15fead81e37457cb1d1)
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/intel-lab-lkp/linux/commit/9988f8132aa9a4e8c9f0eb3093b06a9f02d90ec9
        git remote add linux-review https://github.com/intel-lab-lkp/linux
        git fetch --no-tags linux-review Maximilian-Weigand/Input-cyttsp5-fix-array-length/20230323-215957
        git checkout 9988f8132aa9a4e8c9f0eb3093b06a9f02d90ec9
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=i386 olddefconfig
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=i386 SHELL=/bin/bash drivers/input/touchscreen/

If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@intel.com>
| Link: https://lore.kernel.org/oe-kbuild-all/202303280119.UlD7s4Rk-lkp@intel.com/

All warnings (new ones prefixed by >>):

>> drivers/input/touchscreen/cyttsp5.c:581:6: warning: unused variable 'crc' [-Wunused-variable]
           u16 crc;
               ^
   drivers/input/touchscreen/cyttsp5.c:620:6: warning: unused variable 'crc' [-Wunused-variable]
           u16 crc;
               ^
   drivers/input/touchscreen/cyttsp5.c:700:5: warning: unused variable 'cmd' [-Wunused-variable]
           u8 cmd[2];
              ^
>> drivers/input/touchscreen/cyttsp5.c:1004:6: warning: unused variable 'error' [-Wunused-variable]
           int error;
               ^
>> drivers/input/touchscreen/cyttsp5.c:1003:21: warning: unused variable 'client' [-Wunused-variable]
           struct i2c_client *client = to_i2c_client(dev);
                              ^
   5 warnings generated.


vim +/crc +581 drivers/input/touchscreen/cyttsp5.c

   576	
   577	static int cyttsp5_enter_sleep(struct cyttsp5 *ts)
   578	{
   579		int rc;
   580		u8 cmd[2];
 > 581		u16 crc;
   582	
   583		memset(cmd, 0, sizeof(cmd));
   584	
   585		SET_CMD_REPORT_TYPE(cmd[0], 0);
   586		SET_CMD_REPORT_ID(cmd[0], HID_POWER_SLEEP);
   587		SET_CMD_OPCODE(cmd[1], HID_CMD_SET_POWER);
   588	
   589		rc = cyttsp5_write(ts, HID_COMMAND_REG, cmd, 2);
   590		if (rc) {
   591			dev_err(ts->dev, "Failed to write command %d", rc);
   592			return rc;
   593		}
   594	
   595		rc = wait_for_completion_interruptible_timeout(&ts->cmd_command_done,
   596					msecs_to_jiffies(CY_HID_SET_POWER_TIMEOUT));
   597		if (rc <= 0) {
   598			dev_err(ts->dev, "HID output cmd execution timed out\n");
   599			rc = -ETIMEDOUT;
   600			return rc;
   601		}
   602	
   603		/* validate */
   604		if ((ts->response_buf[2] != HID_RESPONSE_REPORT_ID)
   605				|| ((ts->response_buf[3] & 0x3) != HID_POWER_SLEEP)
   606				|| ((ts->response_buf[4] & 0xF) != HID_CMD_SET_POWER)) {
   607			rc = -EINVAL;
   608			dev_err(ts->dev, "Validation of the sleep response failed\n");
   609			return rc;
   610		}
   611	
   612		return 0;
   613	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests

           reply	other threads:[~2023-03-27 18:12 UTC|newest]

Thread overview: expand[flat|nested]  mbox.gz  Atom feed
 [parent not found: <20230323135205.1160879-7-mweigand@mweigand.net>]

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=202303280119.UlD7s4Rk-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=alistair@alistair23.me \
    --cc=devicetree@vger.kernel.org \
    --cc=dmitry.torokhov@gmail.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=llvm@lists.linux.dev \
    --cc=mweigand@mweigand.net \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).