All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: "Luke D. Jones" <luke@ljones.dev>, linux-input@vger.kernel.org
Cc: oe-kbuild-all@lists.linux.dev, linux-kernel@vger.kernel.org,
	bentiss@kernel.org, jikos@kernel.org,
	"Luke D. Jones" <luke@ljones.dev>
Subject: Re: [PATCH] hid-asus-ally: Add full gamepad support
Date: Wed, 7 Aug 2024 17:50:02 +0800	[thread overview]
Message-ID: <202408071743.00IxSKrf-lkp@intel.com> (raw)
In-Reply-To: <20240806081212.56860-1-luke@ljones.dev>

Hi Luke,

kernel test robot noticed the following build warnings:

[auto build test WARNING on hid/for-next]
[also build test WARNING on next-20240807]
[cannot apply to linus/master v6.11-rc2]
[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/Luke-D-Jones/hid-asus-ally-Add-full-gamepad-support/20240806-170850
base:   https://git.kernel.org/pub/scm/linux/kernel/git/hid/hid.git for-next
patch link:    https://lore.kernel.org/r/20240806081212.56860-1-luke%40ljones.dev
patch subject: [PATCH] hid-asus-ally: Add full gamepad support
config: parisc-allmodconfig (https://download.01.org/0day-ci/archive/20240807/202408071743.00IxSKrf-lkp@intel.com/config)
compiler: hppa-linux-gcc (GCC) 14.1.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240807/202408071743.00IxSKrf-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202408071743.00IxSKrf-lkp@intel.com/

All warnings (new ones prefixed by >>):

   drivers/hid/hid-asus-ally.c: In function 'ally_x_create':
>> drivers/hid/hid-asus-ally.c:565:17: warning: variable 'max_output_report_size' set but not used [-Wunused-but-set-variable]
     565 |         uint8_t max_output_report_size;
         |                 ^~~~~~~~~~~~~~~~~~~~~~
   drivers/hid/hid-asus-ally.c: In function '__gamepad_store_deadzones':
>> drivers/hid/hid-asus-ally.c:1177:13: warning: variable 'cmd' set but not used [-Wunused-but-set-variable]
    1177 |         int cmd, side, is_tr;
         |             ^~~
   In file included from drivers/hid/hid-asus-ally.c:24:
   drivers/hid/hid-asus-ally.c: At top level:
>> drivers/hid/hid-asus-ally.h:321:44: warning: 'btn_mapping_rt_attr_group' defined but not used [-Wunused-const-variable=]
     321 |         ALLY_BTN_ATTRS_GROUP(btn_##_fname, btn_mapping_##_fname)
         |                                            ^~~~~~~~~~~~
   drivers/hid/hid-asus-ally.h:306:45: note: in definition of macro 'ALLY_BTN_ATTRS_GROUP'
     306 |         static const struct attribute_group _fname##_attr_group = {       \
         |                                             ^~~~~~
   drivers/hid/hid-asus-ally.c:895:1: note: in expansion of macro 'ALLY_BTN_MAPPING'
     895 | ALLY_BTN_MAPPING(rt, btn_pair_lt_rt, btn_pair_side_right);
         | ^~~~~~~~~~~~~~~~
>> drivers/hid/hid-asus-ally.h:321:44: warning: 'btn_mapping_lt_attr_group' defined but not used [-Wunused-const-variable=]
     321 |         ALLY_BTN_ATTRS_GROUP(btn_##_fname, btn_mapping_##_fname)
         |                                            ^~~~~~~~~~~~
   drivers/hid/hid-asus-ally.h:306:45: note: in definition of macro 'ALLY_BTN_ATTRS_GROUP'
     306 |         static const struct attribute_group _fname##_attr_group = {       \
         |                                             ^~~~~~
   drivers/hid/hid-asus-ally.c:894:1: note: in expansion of macro 'ALLY_BTN_MAPPING'
     894 | ALLY_BTN_MAPPING(lt, btn_pair_lt_rt, btn_pair_side_left);
         | ^~~~~~~~~~~~~~~~


vim +/max_output_report_size +565 drivers/hid/hid-asus-ally.c

   562	
   563	static struct ally_x_device *ally_x_create(struct hid_device *hdev)
   564	{
 > 565		uint8_t max_output_report_size;
   566		struct ally_x_device *ally_x;
   567		struct ff_report *report;
   568		int ret;
   569	
   570		ally_x = devm_kzalloc(&hdev->dev, sizeof(*ally_x), GFP_KERNEL);
   571		if (!ally_x)
   572			return ERR_PTR(-ENOMEM);
   573	
   574		ally_x->hdev = hdev;
   575		INIT_WORK(&ally_x->output_worker, ally_x_work);
   576		spin_lock_init(&ally_x->lock);
   577		ally_x->output_worker_initialized = true;
   578		ally_x->qam_btns_steam_mode =
   579			true; /* Always default to steam mode, it can be changed by userspace attr */
   580	
   581		max_output_report_size = sizeof(struct ally_x_input_report);
   582		report = devm_kzalloc(&hdev->dev, sizeof(*report), GFP_KERNEL);
   583		if (!report) {
   584			ret = -ENOMEM;
   585			goto free_ally_x;
   586		}
   587	
   588		/* None of these bytes will change for the FF command for now */
   589		report->report_id = 0x0D;
   590		report->ff.enable = 0x0F; /* Enable all by default */
   591		report->ff.pulse_sustain_10ms = 0xFF; /* Duration */
   592		report->ff.pulse_release_10ms = 0x00; /* Start Delay */
   593		report->ff.loop_count = 0xEB; /* Loop Count */
   594		ally_x->ff_packet = report;
   595	
   596		ally_x->input = ally_x_setup_input(hdev);
   597		if (IS_ERR(ally_x->input)) {
   598			ret = PTR_ERR(ally_x->input);
   599			goto free_ff_packet;
   600		}
   601	
   602		if (sysfs_create_file(&hdev->dev.kobj, &dev_attr_ally_x_qam_mode.attr)) {
   603			ret = -ENODEV;
   604			goto unregister_input;
   605		}
   606	
   607		ally_x->update_ff = true;
   608		if (ally_x->output_worker_initialized)
   609			schedule_work(&ally_x->output_worker);
   610	
   611		hid_info(hdev, "Registered Ally X controller using %s\n",
   612			 dev_name(&ally_x->input->dev));
   613		return ally_x;
   614	
   615	unregister_input:
   616		input_unregister_device(ally_x->input);
   617	free_ff_packet:
   618		kfree(ally_x->ff_packet);
   619	free_ally_x:
   620		kfree(ally_x);
   621		return ERR_PTR(ret);
   622	}
   623	

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

  parent reply	other threads:[~2024-08-07  9:50 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-06  8:12 [PATCH] hid-asus-ally: Add full gamepad support Luke D. Jones
2024-08-06 21:34 ` kernel test robot
2024-08-06 22:20   ` Luke Jones
2024-08-07  9:50 ` kernel test robot [this message]
2024-08-07 11:43 ` kernel test robot
  -- strict thread matches above, loose matches on Subject: below --
2024-08-08 15:35 Antheas Kapenekakis
2024-08-11  9:22 ` Luke Jones
2024-08-11 16:10   ` Antheas Kapenekakis
2024-08-11 20:20     ` Denis Benato
2024-08-11 23:14     ` Derek J. Clark
2024-08-12  8:31       ` Antheas Kapenekakis
2024-08-12 12:49         ` Denis Benato

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=202408071743.00IxSKrf-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=bentiss@kernel.org \
    --cc=jikos@kernel.org \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luke@ljones.dev \
    --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 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.