Re: [PATCH 2/4] Input: omap4-keypad - scan keys in two phases and simplify with bitmask

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Tony,

I love your patch! Perhaps something to improve:

[auto build test WARNING on input/next]
[also build test WARNING on hid/for-next linux/master linus/master v5.11-rc2 next-20210104]
[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]

url:    https://github.com/0day-ci/linux/commits/Tony-Lindgren/Lost-key-up-interrupt-handling-for-omap4-keypad/20210106-210045
base:   https://git.kernel.org/pub/scm/linux/kernel/git/dtor/input.git next
config: openrisc-randconfig-s031-20210106 (attached as .config)
compiler: or1k-linux-gcc (GCC) 9.3.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # apt-get install sparse
        # sparse version: v0.6.3-208-g46a52ca4-dirty
        # https://github.com/0day-ci/linux/commit/6a18714b171daeb44c0418e33cc3e78c7daaa44b
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Tony-Lindgren/Lost-key-up-interrupt-handling-for-omap4-keypad/20210106-210045
        git checkout 6a18714b171daeb44c0418e33cc3e78c7daaa44b
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=openrisc 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@xxxxxxxxx>

All warnings (new ones prefixed by >>):

   drivers/input/keyboard/omap4-keypad.c: In function 'omap4_keypad_irq_thread_fn':
   drivers/input/keyboard/omap4-keypad.c:161:15: warning: variable 'keys_down' set but not used [-Wunused-but-set-variable]
     161 |  int keys_up, keys_down;
         |               ^~~~~~~~~
>> drivers/input/keyboard/omap4-keypad.c:161:6: warning: variable 'keys_up' set but not used [-Wunused-but-set-variable]
     161 |  int keys_up, keys_down;
         |      ^~~~~~~


vim +/keys_up +161 drivers/input/keyboard/omap4-keypad.c

   156	
   157	static irqreturn_t omap4_keypad_irq_thread_fn(int irq, void *dev_id)
   158	{
   159		struct omap4_keypad *keypad_data = dev_id;
   160		struct input_dev *input_dev = keypad_data->input;
 > 161		int keys_up, keys_down;
   162		u32 low, high;
   163		u64 keys;
   164	
   165		low = kbd_readl(keypad_data, OMAP4_KBD_FULLCODE31_0);
   166		high = kbd_readl(keypad_data, OMAP4_KBD_FULLCODE63_32);
   167		keys = low | (u64)high << 32;
   168	
   169		/* Scan for key up events for lost key-up interrupts */
   170		keys_up = omap4_keypad_scan_state(keypad_data, keys, false);
   171	
   172		/* Scan for key down events */
   173		keys_down = omap4_keypad_scan_state(keypad_data, keys, true);
   174	
   175		input_sync(input_dev);
   176	
   177		keypad_data->keys = keys;
   178	
   179		/* clear pending interrupts */
   180		kbd_write_irqreg(keypad_data, OMAP4_KBD_IRQSTATUS,
   181				 kbd_read_irqreg(keypad_data, OMAP4_KBD_IRQSTATUS));
   182	
   183		return IRQ_HANDLED;
   184	}
   185	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux