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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202008070543.xk2BOriv%lkp@intel.com>
Date:   Fri, 7 Aug 2020 05:57:43 +0800
From:   kernel test robot <lkp@...el.com>
To:     Stephen Kitt <steve@....org>, Guenter Roeck <linux@...ck-us.net>,
        Jean Delvare <jdelvare@...e.com>, linux-hwmon@...r.kernel.org
Cc:     kbuild-all@...ts.01.org, clang-built-linux@...glegroups.com,
        linux-i2c@...r.kernel.org, linux-kernel@...r.kernel.org,
        Stephen Kitt <steve@....org>
Subject: Re: [PATCH] hwmon/pmbus: use simple i2c probe function

Hi Stephen,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on bcf876870b95592b52519ed4aafcf9d95999bc9c]

url:    https://github.com/0day-ci/linux/commits/Stephen-Kitt/hwmon-pmbus-use-simple-i2c-probe-function/20200807-024648
base:    bcf876870b95592b52519ed4aafcf9d95999bc9c
config: x86_64-randconfig-a013-20200806 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 076b120bebfd727b502208601012a44ab2e1028e)
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
        # install x86_64 cross compiling tool for clang build
        # apt-get install binutils-x86-64-linux-gnu
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64 

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

All errors (new ones prefixed by >>):

>> drivers/hwmon/pmbus/adm1275.c:794:36: error: too many arguments to function call, expected 2, have 3
           return pmbus_do_probe(client, id, info);
                  ~~~~~~~~~~~~~~             ^~~~
   drivers/hwmon/pmbus/pmbus.h:479:5: note: 'pmbus_do_probe' declared here
   int pmbus_do_probe(struct i2c_client *client, struct pmbus_driver_info *info);
       ^
   1 error generated.

vim +794 drivers/hwmon/pmbus/adm1275.c

87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  464  
83f7649c52871d drivers/hwmon/adm1275.c       Guenter Roeck                           2011-03-17  465  static int adm1275_probe(struct i2c_client *client,
83f7649c52871d drivers/hwmon/adm1275.c       Guenter Roeck                           2011-03-17  466  			 const struct i2c_device_id *id)
83f7649c52871d drivers/hwmon/adm1275.c       Guenter Roeck                           2011-03-17  467  {
6d1d41c075a1a5 drivers/hwmon/pmbus/adm1275.c Chu Lin                                 2020-07-09  468  	s32 (*config_read_fn)(const struct i2c_client *client, u8 reg);
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  469  	u8 block_buffer[I2C_SMBUS_BLOCK_MAX + 1];
c5e6763667ffc9 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-08-02  470  	int config, device_config;
3b33ca41227a54 drivers/hwmon/adm1275.c       Guenter Roeck                           2011-06-30  471  	int ret;
83f7649c52871d drivers/hwmon/adm1275.c       Guenter Roeck                           2011-03-17  472  	struct pmbus_driver_info *info;
c5e6763667ffc9 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-08-02  473  	struct adm1275_data *data;
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  474  	const struct i2c_device_id *mid;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  475  	const struct coefficients *coefficients;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  476  	int vindex = -1, voindex = -1, cindex = -1, pindex = -1;
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  477  	int tindex = -1;
6e5c06ad94115e drivers/hwmon/pmbus/adm1275.c Kun Yi                                  2018-10-17  478  	u32 shunt;
83f7649c52871d drivers/hwmon/adm1275.c       Guenter Roeck                           2011-03-17  479  
83f7649c52871d drivers/hwmon/adm1275.c       Guenter Roeck                           2011-03-17  480  	if (!i2c_check_functionality(client->adapter,
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  481  				     I2C_FUNC_SMBUS_READ_BYTE_DATA
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  482  				     | I2C_FUNC_SMBUS_BLOCK_DATA))
83f7649c52871d drivers/hwmon/adm1275.c       Guenter Roeck                           2011-03-17  483  		return -ENODEV;
83f7649c52871d drivers/hwmon/adm1275.c       Guenter Roeck                           2011-03-17  484  
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  485  	ret = i2c_smbus_read_block_data(client, PMBUS_MFR_ID, block_buffer);
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  486  	if (ret < 0) {
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  487  		dev_err(&client->dev, "Failed to read Manufacturer ID\n");
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  488  		return ret;
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  489  	}
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  490  	if (ret != 3 || strncmp(block_buffer, "ADI", 3)) {
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  491  		dev_err(&client->dev, "Unsupported Manufacturer ID\n");
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  492  		return -ENODEV;
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  493  	}
83f7649c52871d drivers/hwmon/adm1275.c       Guenter Roeck                           2011-03-17  494  
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  495  	ret = i2c_smbus_read_block_data(client, PMBUS_MFR_MODEL, block_buffer);
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  496  	if (ret < 0) {
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  497  		dev_err(&client->dev, "Failed to read Manufacturer Model\n");
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  498  		return ret;
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  499  	}
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  500  	for (mid = adm1275_id; mid->name[0]; mid++) {
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  501  		if (!strncasecmp(mid->name, block_buffer, strlen(mid->name)))
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  502  			break;
3b33ca41227a54 drivers/hwmon/adm1275.c       Guenter Roeck                           2011-06-30  503  	}
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  504  	if (!mid->name[0]) {
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  505  		dev_err(&client->dev, "Unsupported device\n");
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  506  		return -ENODEV;
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  507  	}
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  508  
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  509  	if (id->driver_data != mid->driver_data)
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  510  		dev_notice(&client->dev,
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  511  			   "Device mismatch: Configured %s, detected %s\n",
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  512  			   id->name, mid->name);
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  513  
6d1d41c075a1a5 drivers/hwmon/pmbus/adm1275.c Chu Lin                                 2020-07-09  514  	if (mid->driver_data == adm1272 || mid->driver_data == adm1278 ||
6d1d41c075a1a5 drivers/hwmon/pmbus/adm1275.c Chu Lin                                 2020-07-09  515  	    mid->driver_data == adm1293 || mid->driver_data == adm1294)
6d1d41c075a1a5 drivers/hwmon/pmbus/adm1275.c Chu Lin                                 2020-07-09  516  		config_read_fn = i2c_smbus_read_word_data;
6d1d41c075a1a5 drivers/hwmon/pmbus/adm1275.c Chu Lin                                 2020-07-09  517  	else
6d1d41c075a1a5 drivers/hwmon/pmbus/adm1275.c Chu Lin                                 2020-07-09  518  		config_read_fn = i2c_smbus_read_byte_data;
6d1d41c075a1a5 drivers/hwmon/pmbus/adm1275.c Chu Lin                                 2020-07-09  519  	config = config_read_fn(client, ADM1275_PMON_CONFIG);
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  520  	if (config < 0)
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  521  		return config;
83f7649c52871d drivers/hwmon/adm1275.c       Guenter Roeck                           2011-03-17  522  
6d1d41c075a1a5 drivers/hwmon/pmbus/adm1275.c Chu Lin                                 2020-07-09  523  	device_config = config_read_fn(client, ADM1275_DEVICE_CONFIG);
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  524  	if (device_config < 0)
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  525  		return device_config;
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  526  
8b313ca7f1b982 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-22  527  	data = devm_kzalloc(&client->dev, sizeof(struct adm1275_data),
8b313ca7f1b982 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-22  528  			    GFP_KERNEL);
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  529  	if (!data)
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  530  		return -ENOMEM;
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  531  
6e5c06ad94115e drivers/hwmon/pmbus/adm1275.c Kun Yi                                  2018-10-17  532  	if (of_property_read_u32(client->dev.of_node,
6e5c06ad94115e drivers/hwmon/pmbus/adm1275.c Kun Yi                                  2018-10-17  533  				 "shunt-resistor-micro-ohms", &shunt))
6e5c06ad94115e drivers/hwmon/pmbus/adm1275.c Kun Yi                                  2018-10-17  534  		shunt = 1000; /* 1 mOhm if not set via DT */
6e5c06ad94115e drivers/hwmon/pmbus/adm1275.c Kun Yi                                  2018-10-17  535  
6e5c06ad94115e drivers/hwmon/pmbus/adm1275.c Kun Yi                                  2018-10-17  536  	if (shunt == 0)
6e5c06ad94115e drivers/hwmon/pmbus/adm1275.c Kun Yi                                  2018-10-17  537  		return -EINVAL;
6e5c06ad94115e drivers/hwmon/pmbus/adm1275.c Kun Yi                                  2018-10-17  538  
87102808d03948 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-09-30  539  	data->id = mid->driver_data;
c5e6763667ffc9 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-08-02  540  
c5e6763667ffc9 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-08-02  541  	info = &data->info;
c5e6763667ffc9 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-08-02  542  
83f7649c52871d drivers/hwmon/adm1275.c       Guenter Roeck                           2011-03-17  543  	info->pages = 1;
1061d8518f8bde drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-06-25  544  	info->format[PSC_VOLTAGE_IN] = direct;
1061d8518f8bde drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-06-25  545  	info->format[PSC_VOLTAGE_OUT] = direct;
1061d8518f8bde drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-06-25  546  	info->format[PSC_CURRENT_OUT] = direct;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  547  	info->format[PSC_POWER] = direct;
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  548  	info->format[PSC_TEMPERATURE] = direct;
c83529c17e1204 drivers/hwmon/pmbus/adm1275.c Adamski, Krzysztof (Nokia - PL/Wroclaw  2019-05-29  549) 	info->func[0] = PMBUS_HAVE_IOUT | PMBUS_HAVE_STATUS_IOUT |
c83529c17e1204 drivers/hwmon/pmbus/adm1275.c Adamski, Krzysztof (Nokia - PL/Wroclaw  2019-05-29  550) 			PMBUS_HAVE_SAMPLES;
83f7649c52871d drivers/hwmon/adm1275.c       Guenter Roeck                           2011-03-17  551  
c576e30cd0c981 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-07-09  552  	info->read_word_data = adm1275_read_word_data;
c5e6763667ffc9 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-08-02  553  	info->read_byte_data = adm1275_read_byte_data;
c576e30cd0c981 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-07-09  554  	info->write_word_data = adm1275_write_word_data;
c576e30cd0c981 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-07-09  555  
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  556  	switch (data->id) {
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  557  	case adm1075:
c5e6763667ffc9 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-08-02  558  		if (device_config & ADM1275_IOUT_WARN2_SELECT)
c5e6763667ffc9 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-08-02  559  			data->have_oc_fault = true;
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  560  		else
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  561  			data->have_uc_fault = true;
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  562  		data->have_pin_max = true;
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  563  		data->have_vaux_status = true;
c5e6763667ffc9 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-08-02  564  
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  565  		coefficients = adm1075_coefficients;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  566  		vindex = 0;
927112696654f4 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-24  567  		switch (config & ADM1075_IRANGE_MASK) {
927112696654f4 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-24  568  		case ADM1075_IRANGE_25:
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  569  			cindex = 1;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  570  			pindex = 3;
927112696654f4 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-24  571  			break;
927112696654f4 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-24  572  		case ADM1075_IRANGE_50:
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  573  			cindex = 2;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  574  			pindex = 4;
927112696654f4 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-24  575  			break;
927112696654f4 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-24  576  		default:
927112696654f4 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-24  577  			dev_err(&client->dev, "Invalid input current range");
927112696654f4 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-24  578  			break;
927112696654f4 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-24  579  		}
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  580  
927112696654f4 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-24  581  		info->func[0] |= PMBUS_HAVE_VIN | PMBUS_HAVE_PIN
927112696654f4 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-24  582  		  | PMBUS_HAVE_STATUS_INPUT;
927112696654f4 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-24  583  		if (config & ADM1275_VIN_VOUT_SELECT)
927112696654f4 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-24  584  			info->func[0] |=
927112696654f4 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-24  585  			  PMBUS_HAVE_VOUT | PMBUS_HAVE_STATUS_VOUT;
927112696654f4 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-24  586  		break;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  587  	case adm1272:
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  588  		data->have_vout = true;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  589  		data->have_pin_max = true;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  590  		data->have_temp_max = true;
7d45deb31bec39 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2019-06-12  591  		data->have_power_sampling = true;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  592  
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  593  		coefficients = adm1272_coefficients;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  594  		vindex = (config & ADM1275_VRANGE) ? 1 : 0;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  595  		cindex = (config & ADM1272_IRANGE) ? 3 : 2;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  596  		/* pindex depends on the combination of the above */
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  597  		switch (config & (ADM1275_VRANGE | ADM1272_IRANGE)) {
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  598  		case 0:
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  599  		default:
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  600  			pindex = 4;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  601  			break;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  602  		case ADM1275_VRANGE:
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  603  			pindex = 5;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  604  			break;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  605  		case ADM1272_IRANGE:
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  606  			pindex = 6;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  607  			break;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  608  		case ADM1275_VRANGE | ADM1272_IRANGE:
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  609  			pindex = 7;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  610  			break;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  611  		}
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  612  		tindex = 8;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  613  
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  614  		info->func[0] |= PMBUS_HAVE_PIN | PMBUS_HAVE_STATUS_INPUT |
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  615  			PMBUS_HAVE_VOUT | PMBUS_HAVE_STATUS_VOUT;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  616  
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  617  		/* Enable VOUT if not enabled (it is disabled by default) */
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  618  		if (!(config & ADM1278_VOUT_EN)) {
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  619  			config |= ADM1278_VOUT_EN;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  620  			ret = i2c_smbus_write_byte_data(client,
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  621  							ADM1275_PMON_CONFIG,
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  622  							config);
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  623  			if (ret < 0) {
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  624  				dev_err(&client->dev,
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  625  					"Failed to enable VOUT monitoring\n");
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  626  				return -ENODEV;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  627  			}
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  628  		}
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  629  
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  630  		if (config & ADM1278_TEMP1_EN)
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  631  			info->func[0] |=
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  632  				PMBUS_HAVE_TEMP | PMBUS_HAVE_STATUS_TEMP;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  633  		if (config & ADM1278_VIN_EN)
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  634  			info->func[0] |= PMBUS_HAVE_VIN;
4ff0ce227a1e65 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2018-03-10  635  		break;
5cf231a346fb80 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-07-14  636  	case adm1275:
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  637  		if (device_config & ADM1275_IOUT_WARN2_SELECT)
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  638  			data->have_oc_fault = true;
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  639  		else
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  640  			data->have_uc_fault = true;
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  641  		data->have_vout = true;
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  642  
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  643  		coefficients = adm1275_coefficients;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  644  		vindex = (config & ADM1275_VRANGE) ? 0 : 1;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  645  		cindex = 2;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  646  
83f7649c52871d drivers/hwmon/adm1275.c       Guenter Roeck                           2011-03-17  647  		if (config & ADM1275_VIN_VOUT_SELECT)
5cf231a346fb80 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-07-14  648  			info->func[0] |=
5cf231a346fb80 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-07-14  649  			  PMBUS_HAVE_VOUT | PMBUS_HAVE_STATUS_VOUT;
83f7649c52871d drivers/hwmon/adm1275.c       Guenter Roeck                           2011-03-17  650  		else
5cf231a346fb80 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-07-14  651  			info->func[0] |=
5cf231a346fb80 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-07-14  652  			  PMBUS_HAVE_VIN | PMBUS_HAVE_STATUS_INPUT;
5cf231a346fb80 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-07-14  653  		break;
5cf231a346fb80 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-07-14  654  	case adm1276:
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  655  		if (device_config & ADM1275_IOUT_WARN2_SELECT)
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  656  			data->have_oc_fault = true;
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  657  		else
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  658  			data->have_uc_fault = true;
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  659  		data->have_vout = true;
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  660  		data->have_pin_max = true;
9048539b7cd6ca drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  661  
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  662  		coefficients = adm1276_coefficients;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  663  		vindex = (config & ADM1275_VRANGE) ? 0 : 1;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  664  		cindex = 2;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  665  		pindex = (config & ADM1275_VRANGE) ? 3 : 4;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  666  
5cf231a346fb80 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-07-14  667  		info->func[0] |= PMBUS_HAVE_VIN | PMBUS_HAVE_PIN
5cf231a346fb80 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-07-14  668  		  | PMBUS_HAVE_STATUS_INPUT;
5cf231a346fb80 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-07-14  669  		if (config & ADM1275_VIN_VOUT_SELECT)
5cf231a346fb80 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-07-14  670  			info->func[0] |=
5cf231a346fb80 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-07-14  671  			  PMBUS_HAVE_VOUT | PMBUS_HAVE_STATUS_VOUT;
5cf231a346fb80 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-07-14  672  		break;
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  673  	case adm1278:
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  674  		data->have_vout = true;
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  675  		data->have_pin_max = true;
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  676  		data->have_temp_max = true;
7d45deb31bec39 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2019-06-12  677  		data->have_power_sampling = true;
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  678  
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  679  		coefficients = adm1278_coefficients;
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  680  		vindex = 0;
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  681  		cindex = 1;
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  682  		pindex = 2;
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  683  		tindex = 3;
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  684  
2b3d0c19537c1b drivers/hwmon/pmbus/adm1275.c Yi Li                                   2016-10-17  685  		info->func[0] |= PMBUS_HAVE_PIN | PMBUS_HAVE_STATUS_INPUT |
2b3d0c19537c1b drivers/hwmon/pmbus/adm1275.c Yi Li                                   2016-10-17  686  			PMBUS_HAVE_VOUT | PMBUS_HAVE_STATUS_VOUT;
2b3d0c19537c1b drivers/hwmon/pmbus/adm1275.c Yi Li                                   2016-10-17  687  
2b3d0c19537c1b drivers/hwmon/pmbus/adm1275.c Yi Li                                   2016-10-17  688  		/* Enable VOUT if not enabled (it is disabled by default) */
2b3d0c19537c1b drivers/hwmon/pmbus/adm1275.c Yi Li                                   2016-10-17  689  		if (!(config & ADM1278_VOUT_EN)) {
2b3d0c19537c1b drivers/hwmon/pmbus/adm1275.c Yi Li                                   2016-10-17  690  			config |= ADM1278_VOUT_EN;
2b3d0c19537c1b drivers/hwmon/pmbus/adm1275.c Yi Li                                   2016-10-17  691  			ret = i2c_smbus_write_byte_data(client,
2b3d0c19537c1b drivers/hwmon/pmbus/adm1275.c Yi Li                                   2016-10-17  692  							ADM1275_PMON_CONFIG,
2b3d0c19537c1b drivers/hwmon/pmbus/adm1275.c Yi Li                                   2016-10-17  693  							config);
2b3d0c19537c1b drivers/hwmon/pmbus/adm1275.c Yi Li                                   2016-10-17  694  			if (ret < 0) {
2b3d0c19537c1b drivers/hwmon/pmbus/adm1275.c Yi Li                                   2016-10-17  695  				dev_err(&client->dev,
2b3d0c19537c1b drivers/hwmon/pmbus/adm1275.c Yi Li                                   2016-10-17  696  					"Failed to enable VOUT monitoring\n");
2b3d0c19537c1b drivers/hwmon/pmbus/adm1275.c Yi Li                                   2016-10-17  697  				return -ENODEV;
2b3d0c19537c1b drivers/hwmon/pmbus/adm1275.c Yi Li                                   2016-10-17  698  			}
2b3d0c19537c1b drivers/hwmon/pmbus/adm1275.c Yi Li                                   2016-10-17  699  		}
2b3d0c19537c1b drivers/hwmon/pmbus/adm1275.c Yi Li                                   2016-10-17  700  
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  701  		if (config & ADM1278_TEMP1_EN)
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  702  			info->func[0] |=
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  703  				PMBUS_HAVE_TEMP | PMBUS_HAVE_STATUS_TEMP;
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  704  		if (config & ADM1278_VIN_EN)
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  705  			info->func[0] |= PMBUS_HAVE_VIN;
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  706  		break;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  707  	case adm1293:
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  708  	case adm1294:
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  709  		data->have_iout_min = true;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  710  		data->have_pin_min = true;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  711  		data->have_pin_max = true;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  712  		data->have_mfr_vaux_status = true;
7d45deb31bec39 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2019-06-12  713  		data->have_power_sampling = true;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  714  
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  715  		coefficients = adm1293_coefficients;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  716  
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  717  		voindex = 0;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  718  		switch (config & ADM1293_VIN_SEL_MASK) {
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  719  		case ADM1293_VIN_SEL_012:	/* 1.2V */
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  720  			vindex = 0;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  721  			break;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  722  		case ADM1293_VIN_SEL_074:	/* 7.4V */
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  723  			vindex = 1;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  724  			break;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  725  		case ADM1293_VIN_SEL_210:	/* 21V */
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  726  			vindex = 2;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  727  			break;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  728  		default:			/* disabled */
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  729  			break;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  730  		}
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  731  
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  732  		switch (config & ADM1293_IRANGE_MASK) {
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  733  		case ADM1293_IRANGE_25:
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  734  			cindex = 3;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  735  			break;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  736  		case ADM1293_IRANGE_50:
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  737  			cindex = 4;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  738  			break;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  739  		case ADM1293_IRANGE_100:
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  740  			cindex = 5;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  741  			break;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  742  		case ADM1293_IRANGE_200:
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  743  			cindex = 6;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  744  			break;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  745  		}
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  746  
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  747  		if (vindex >= 0)
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  748  			pindex = 7 + vindex * 4 + (cindex - 3);
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  749  
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  750  		if (config & ADM1293_VAUX_EN)
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  751  			info->func[0] |=
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  752  				PMBUS_HAVE_VOUT | PMBUS_HAVE_STATUS_VOUT;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  753  
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  754  		info->func[0] |= PMBUS_HAVE_PIN |
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  755  			PMBUS_HAVE_VIN | PMBUS_HAVE_STATUS_INPUT;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  756  
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  757  		break;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  758  	default:
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  759  		dev_err(&client->dev, "Unsupported device\n");
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  760  		return -ENODEV;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  761  	}
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  762  
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  763  	if (voindex < 0)
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  764  		voindex = vindex;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  765  	if (vindex >= 0) {
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  766  		info->m[PSC_VOLTAGE_IN] = coefficients[vindex].m;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  767  		info->b[PSC_VOLTAGE_IN] = coefficients[vindex].b;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  768  		info->R[PSC_VOLTAGE_IN] = coefficients[vindex].R;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  769  	}
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  770  	if (voindex >= 0) {
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  771  		info->m[PSC_VOLTAGE_OUT] = coefficients[voindex].m;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  772  		info->b[PSC_VOLTAGE_OUT] = coefficients[voindex].b;
68a403823600fc drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-03-17  773  		info->R[PSC_VOLTAGE_OUT] = coefficients[voindex].R;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  774  	}
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  775  	if (cindex >= 0) {
6e5c06ad94115e drivers/hwmon/pmbus/adm1275.c Kun Yi                                  2018-10-17  776  		/* Scale current with sense resistor value */
6e5c06ad94115e drivers/hwmon/pmbus/adm1275.c Kun Yi                                  2018-10-17  777  		info->m[PSC_CURRENT_OUT] =
6e5c06ad94115e drivers/hwmon/pmbus/adm1275.c Kun Yi                                  2018-10-17  778  			coefficients[cindex].m * shunt / 1000;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  779  		info->b[PSC_CURRENT_OUT] = coefficients[cindex].b;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  780  		info->R[PSC_CURRENT_OUT] = coefficients[cindex].R;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  781  	}
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  782  	if (pindex >= 0) {
6e5c06ad94115e drivers/hwmon/pmbus/adm1275.c Kun Yi                                  2018-10-17  783  		info->m[PSC_POWER] =
6e5c06ad94115e drivers/hwmon/pmbus/adm1275.c Kun Yi                                  2018-10-17  784  			coefficients[pindex].m * shunt / 1000;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  785  		info->b[PSC_POWER] = coefficients[pindex].b;
904b296f308dc7 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-04  786  		info->R[PSC_POWER] = coefficients[pindex].R;
5cf231a346fb80 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2011-07-14  787  	}
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  788  	if (tindex >= 0) {
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  789  		info->m[PSC_TEMPERATURE] = coefficients[tindex].m;
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  790  		info->b[PSC_TEMPERATURE] = coefficients[tindex].b;
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  791  		info->R[PSC_TEMPERATURE] = coefficients[tindex].R;
709066acdd12c3 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2015-07-05  792  	}
83f7649c52871d drivers/hwmon/adm1275.c       Guenter Roeck                           2011-03-17  793  
8b313ca7f1b982 drivers/hwmon/pmbus/adm1275.c Guenter Roeck                           2012-02-22 @794  	return pmbus_do_probe(client, id, info);
83f7649c52871d drivers/hwmon/adm1275.c       Guenter Roeck                           2011-03-17  795  }
83f7649c52871d drivers/hwmon/adm1275.c       Guenter Roeck                           2011-03-17  796  

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

Download attachment ".config.gz" of type "application/gzip" (36855 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ