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]
Date:	Mon, 25 Oct 2010 22:36:31 +0200
From:	"Rafael J. Wysocki" <rjw@...k.pl>
To:	Pavel Machek <pavel@....cz>
Cc:	Sitsofe Wheeler <sitsofe@...oo.com>,
	Henrique de Moraes Holschuh <hmh@....eng.br>,
	Matthew Garrett <mjg59@...f.ucam.org>,
	Len Brown <lenb@...nel.org>, Zhang Rui <rui.zhang@...el.com>,
	David Zeuthen <davidz@...hat.com>,
	Richard Hughes <richard@...hsie.com>,
	linux-acpi@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] ACPI / Battery: Return -ENODATA for unknown values in get_property()

On Monday, October 25, 2010, Pavel Machek wrote:
> Hi!
> 
> > That's why I suggested to use -ENODATA. :-)
> > 
> > Still, if user space has problems with failing reads from the sysfs attributes,
> > it may be better to simply put -1 in there.  Patch is appended, please test.
> 
> I'd say that reporting -1 for unknown is ugly. You can have -1A
> current easily (charging at 1A), and I've seen machines reporting <0
> current -- when charging. Logical and well-defined.

I posted a patch fixing that in a different way (makng the battery driver return
-ENODEV instead of -ENODATA) in the meantime, which has been confirmed to work.

Thanks,
Rafael
--
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