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]
Message-ID: <CAMpxmJXp2NT+rie2d2+Z7hixKMyS+xcRNdKRNZaUSJD-aTUVVg@mail.gmail.com>
Date:	Wed, 10 Dec 2014 17:46:43 +0100
From:	Bartosz Golaszewski <bgolaszewski@...libre.com>
To:	Guenter Roeck <linux@...ck-us.net>
Cc:	LKML <linux-kernel@...r.kernel.org>,
	Benoit Cousson <bcousson@...libre.com>,
	Patrick Titiano <ptitiano@...libre.com>,
	LM Sensors <lm-sensors@...sensors.org>
Subject: Re: [PATCH v5 1/3] hwmon: ina2xx: make shunt resistance configurable
 at run-time

2014-12-10 15:20 GMT+01:00 Guenter Roeck <linux@...ck-us.net>:
>> +       case INA2XX_CALIBRATION:
>> +               if (data->regs[reg] == 0)
>> +                       val = 0;
>> +               else
>> +                       val = data->config->calibration_factor
>> +                                               / data->regs[reg];
>> +               break;
>
>
> This doesn't really make sense. What you want to show is rshunt, not the
> above.
> I think it would be better to write a separate show function to display it.

Hi Guenter,

this is the only way to display values read from the chip. It also
tells the user what the actual programmed value is. In fact it was
your suggestion (https://lkml.org/lkml/2014/11/30/233) and I agree
that it's a better alternative. Are you sure you don't want it done
this way?

Bart
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ