On Fri, Dec 09, 2016 at 04:25:48PM +0100, Jean Delvare wrote:
> On Fri, 9 Dec 2016 06:22:43 -0800, Guenter Roeck wrote:
> > On 12/09/2016 01:49 AM, Jean Delvare wrote:
> > > Looking at function nct7802_write_fan_min() I think an overflow can
> > > happen here too, as DIV_ROUND_CLOSEST() is called
On Fri, 9 Dec 2016 06:22:43 -0800, Guenter Roeck wrote:
> On 12/09/2016 01:49 AM, Jean Delvare wrote:
> > Looking at function nct7802_write_fan_min() I think an overflow can
> > happen here too, as DIV_ROUND_CLOSEST() is called before clamp_val().
> > Any reason why you did not fix that one?
> >
>
Hi Jean,
On 12/09/2016 01:49 AM, Jean Delvare wrote:
Hi Guenter,
On Sun, 4 Dec 2016 20:55:32 -0800, Guenter Roeck wrote:
Fix overflows seen when writing voltage and temperature limit attributes.
The value passed to DIV_ROUND_CLOSEST() needs to be clamped.
Signed-off-by: Guenter Roeck
Hi Guenter,
On Sun, 4 Dec 2016 20:55:32 -0800, Guenter Roeck wrote:
> Fix overflows seen when writing voltage and temperature limit attributes.
>
> The value passed to DIV_ROUND_CLOSEST() needs to be clamped.
>
> Signed-off-by: Guenter Roeck
I think you can also add:
Fix overflows seen when writing voltage and temperature limit attributes.
The value passed to DIV_ROUND_CLOSEST() needs to be clamped.
Signed-off-by: Guenter Roeck
---
drivers/hwmon/nct7802.c | 7 ---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git