Re: [PATCH 1/3] Bluetooth: hci_h5: add WAKEUP_DISABLE flag

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

 



Hi Archie,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on bluetooth-next/master]
[also build test WARNING on next-20210714]
[cannot apply to bluetooth/master v5.14-rc1]
[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/Archie-Pusaka/Bluetooth-hci_h5-add-WAKEUP_DISABLE-flag/20210714-151525
base:   https://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth-next.git master
config: xtensa-allyesconfig (attached as .config)
compiler: xtensa-linux-gcc (GCC) 9.3.0
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/865118c4aaa9efbd4776dee71bf3a1a263a6571e
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Archie-Pusaka/Bluetooth-hci_h5-add-WAKEUP_DISABLE-flag/20210714-151525
        git checkout 865118c4aaa9efbd4776dee71bf3a1a263a6571e
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=xtensa 

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/bluetooth/hci_h5.c: In function 'h5_serdev_probe':
>> drivers/bluetooth/hci_h5.c:804:18: warning: variable 'hdev' set but not used [-Wunused-but-set-variable]
     804 |  struct hci_dev *hdev;
         |                  ^~~~


vim +/hdev +804 drivers/bluetooth/hci_h5.c

   799	
   800	static int h5_serdev_probe(struct serdev_device *serdev)
   801	{
   802		struct device *dev = &serdev->dev;
   803		struct h5 *h5;
 > 804		struct hci_dev *hdev;
   805		const struct h5_device_data *data;
   806		int err;
   807	
   808		h5 = devm_kzalloc(dev, sizeof(*h5), GFP_KERNEL);
   809		if (!h5)
   810			return -ENOMEM;
   811	
   812		h5->hu = &h5->serdev_hu;
   813		h5->serdev_hu.serdev = serdev;
   814		serdev_device_set_drvdata(serdev, h5);
   815	
   816		if (has_acpi_companion(dev)) {
   817			const struct acpi_device_id *match;
   818	
   819			match = acpi_match_device(dev->driver->acpi_match_table, dev);
   820			if (!match)
   821				return -ENODEV;
   822	
   823			data = (const struct h5_device_data *)match->driver_data;
   824			h5->vnd = data->vnd;
   825			h5->id  = (char *)match->id;
   826	
   827			if (h5->vnd->acpi_gpio_map)
   828				devm_acpi_dev_add_driver_gpios(dev,
   829							       h5->vnd->acpi_gpio_map);
   830		} else {
   831			data = of_device_get_match_data(dev);
   832			if (!data)
   833				return -ENODEV;
   834	
   835			h5->vnd = data->vnd;
   836		}
   837	
   838	
   839		h5->enable_gpio = devm_gpiod_get_optional(dev, "enable", GPIOD_OUT_LOW);
   840		if (IS_ERR(h5->enable_gpio))
   841			return PTR_ERR(h5->enable_gpio);
   842	
   843		h5->device_wake_gpio = devm_gpiod_get_optional(dev, "device-wake",
   844							       GPIOD_OUT_LOW);
   845		if (IS_ERR(h5->device_wake_gpio))
   846			return PTR_ERR(h5->device_wake_gpio);
   847	
   848		err = hci_uart_register_device(&h5->serdev_hu, &h5p);
   849		if (err)
   850			return err;
   851	
   852		hdev = h5->serdev_hu.hdev;
   853	
   854		if (data->driver_info & H5_INFO_WAKEUP_DISABLE)
   855			set_bit(H5_WAKEUP_DISABLE, &h5->flags);
   856	
   857		return 0;
   858	}
   859	

---
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]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux