lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 31 May 2022 15:56:59 +0800
From:   kernel test robot <lkp@...el.com>
To:     Cosmin Tanislav <demonsingur@...il.com>
Cc:     kbuild-all@...ts.01.org,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Jiri Slaby <jirislaby@...nel.org>,
        linux-serial@...r.kernel.org, linux-kernel@...r.kernel.org,
        Cosmin Tanislav <cosmin.tanislav@...log.com>
Subject: Re: [PATCH 4/4] serial: max310x: implement I2C support

Hi Cosmin,

I love your patch! Yet something to improve:

[auto build test ERROR on tty/tty-testing]
[also build test ERROR on usb/usb-testing v5.18 next-20220531]
[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/intel-lab-lkp/linux/commits/Cosmin-Tanislav/serial-max310x-use-regmap-methods-for-SPI-batch-operations/20220531-061619
base:   https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty.git tty-testing
config: openrisc-randconfig-c023-20220531 (https://download.01.org/0day-ci/archive/20220531/202205311555.lv5uAjEN-lkp@intel.com/config)
compiler: or1k-linux-gcc (GCC) 11.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/intel-lab-lkp/linux/commit/6c293b95fc5654df5353ba273a9bbd08f1cd3f3a
        git remote add linux-review https://github.com/intel-lab-lkp/linux
        git fetch --no-tags linux-review Cosmin-Tanislav/serial-max310x-use-regmap-methods-for-SPI-batch-operations/20220531-061619
        git checkout 6c293b95fc5654df5353ba273a9bbd08f1cd3f3a
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.3.0 make.cross W=1 O=build_dir ARCH=openrisc SHELL=/bin/bash drivers/tty/serial/

If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@...el.com>

All error/warnings (new ones prefixed by >>):

   drivers/tty/serial/max310x.c: In function 'max310x_i2c_probe':
>> drivers/tty/serial/max310x.c:1603:31: error: implicit declaration of function 'devm_i2c_new_dummy_device' [-Werror=implicit-function-declaration]
    1603 |                 port_client = devm_i2c_new_dummy_device(&client->dev,
         |                               ^~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/tty/serial/max310x.c:1603:29: warning: assignment to 'struct i2c_client *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
    1603 |                 port_client = devm_i2c_new_dummy_device(&client->dev,
         |                             ^
   drivers/tty/serial/max310x.c: In function 'max310x_uart_init':
   drivers/tty/serial/max310x.c:1658:1: warning: label 'err_i2c_register' defined but not used [-Wunused-label]
    1658 | err_i2c_register:
         | ^~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors


vim +/devm_i2c_new_dummy_device +1603 drivers/tty/serial/max310x.c

  1582	
  1583	static int max310x_i2c_probe(struct i2c_client *client)
  1584	{
  1585		const struct max310x_devtype *devtype =
  1586				device_get_match_data(&client->dev);
  1587		struct i2c_client *port_client;
  1588		struct regmap *regmaps[4];
  1589		unsigned int i;
  1590		u8 port_addr;
  1591	
  1592		if (client->addr < devtype->slave_addr.min ||
  1593			client->addr > devtype->slave_addr.max)
  1594			return dev_err_probe(&client->dev, -EINVAL,
  1595					     "Slave addr 0x%x outside of range [0x%x, 0x%x]\n",
  1596					     client->addr, devtype->slave_addr.min,
  1597					     devtype->slave_addr.max);
  1598	
  1599		regmaps[0] = devm_regmap_init_i2c(client, &regcfg_i2c);
  1600	
  1601		for (i = 1; i < devtype->nr; i++) {
  1602			port_addr = max310x_i2c_slave_addr(client->addr, i);
> 1603			port_client = devm_i2c_new_dummy_device(&client->dev,
  1604								client->adapter,
  1605								port_addr);
  1606	
  1607			regmaps[i] = devm_regmap_init_i2c(port_client, &regcfg_i2c);
  1608		}
  1609	
  1610		return max310x_probe(&client->dev, devtype, &max310x_i2c_if_cfg,
  1611				     regmaps, client->irq);
  1612	}
  1613	

-- 
0-DAY CI Kernel Test Service
https://01.org/lkp

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ