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]
Date:	Sat, 28 Oct 2006 05:12:16 +0000
From:	Pavel Machek <pavel@....cz>
To:	David Woodhouse <dwmw2@...radead.org>
Cc:	Richard Hughes <hughsient@...il.com>,
	Dan Williams <dcbw@...hat.com>, linux-kernel@...r.kernel.org,
	devel@...top.org, sfr@...b.auug.org.au, len.brown@...el.com,
	greg@...ah.com, benh@...nel.crashing.org,
	David Zeuthen <davidz@...hat.com>
Subject: Re: [PATCH v2] Re: Battery class driver.

Hi!

> I haven't (yet) changed from a single 'status' file to multiple
> 'is_flag_0' 'is_flag_1' 'is_flag_2' files. I really don't like that idea
> much -- it doesn't seem any more sensible than exposing each bit of the
> voltage value through a separate file. These flags are _read_ together,
> and _used_ together. I'd rather show it as a hex value 'flags' than
> split it up. But I still think that the current 'present,charging,low'
> is best.

Please do this change. sysfs *is* one file per value.. if at least to
be consistent with rest of code.

> @@ -0,0 +1,177 @@
> +/*
> + * Battery class core
> + *
> + *	?? 2006 David Woodhouse <dwmw2@...radead.org>
> + *
> + * Based on LED Class support, by John Lenz and Richard Purdie:
> + *
> + *	?? 2005 John Lenz <lenz@...wisc.edu>
> + *	?? 2005-2006 Richard Purdie <rpurdie@...nedhand.com>

Could we get something ascii here? I'm not sure what you see instead
of copyright... but I see ??. I could not find it in source, but if
you use non-ascii character in file, please fix that, too.

> +ssize_t battery_attribute_show_ac_status(char *buf, unsigned long status)
> +{
> +	return 1 + sprintf(buf, "o%s-line\n", status?"n":"ff");
> +}  

I guess ac_online should show 0/1...

> +	if (unlikely(err))
> +		return err;
> +
> +        battery_dev->dev = device_create(battery_class, parent, 0,

space/tab problem?


-- 
Thanks for all the (sleeping) penguins.
-
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