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] [day] [month] [year] [list]
Message-ID: <20250106204254.28b79000@pc>
Date: Mon,  6 Jan 2025 18:42:54 +0000
From: Daniil Stas <daniil.stas@...teo.net>
To: Guenter Roeck <linux@...ck-us.net>
Cc: linux-hwmon@...r.kernel.org, Chris Healy <cphealy@...il.com>, Linus
 Walleij <linus.walleij@...aro.org>, "Martin K. Petersen"
 <martin.petersen@...cle.com>, Bart Van Assche <bvanassche@....org>,
 linux-kernel@...r.kernel.org, linux-scsi@...r.kernel.org,
 linux-ide@...r.kernel.org
Subject: Re: [PATCH] hwmon: drivetemp: Fix driver producing garbage data
 when SCSI errors occur

On Mon, 6 Jan 2025 08:43:54 -0800
Guenter Roeck <linux@...ck-us.net> wrote:

> On Sun, Jan 05, 2025 at 09:36:18PM +0000, Daniil Stas wrote:
> > scsi_execute_cmd() function can return both negative (linux codes)
> > and positive (scsi_cmnd result field) error codes.
> > 
> > Currently the driver just passes error codes of scsi_execute_cmd()
> > to hwmon core, which is incorrect because hwmon only checks for
> > negative error codes. This leads to hwmon reporting uninitialized
> > data to userspace in case of SCSI errors (for example if the disk
> > drive was disconnected).
> > 
> > This patch checks scsi_execute_cmd() output and returns -EIO if it's
> > error code is positive.
> >   
> 
> Applied.
> 
> Thanks,
> Guenter

Thanks!

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ