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: <200812250755.39288.carlos@strangeworlds.co.uk>
Date:	Thu, 25 Dec 2008 07:55:37 +0000
From:	Carlos Corbacho <carlos@...angeworlds.co.uk>
To:	"Krzysztof Kosiński" <tweenk.pl@...il.com>
Cc:	linux-kernel@...r.kernel.org, linux-acpi@...r.kernel.org,
	Len Brown <lenb@...nel.org>
Subject: Re: [PATCH] tc1100-wmi: fix state reporting

[Adding CC's]

On Thursday 25 December 2008 02:45:25 Krzysztof Kosiński wrote:
> This small patch fixes the state reported when reading the files in
> /sys/devices/platofrm/tc1100-wmi/*. The first change fixes always
> returning 0 from the files in sysfs. The second one fixes jogdial
> state reprting to match with the commands used to set it (e.g. now
> after "echo 0 > /sys/devices/platofrm/tc1100-wmi/jogdial", "cat
> /sys/devices/platofrm/tc1100-wmi/jogdial" will return 0 instead of 1).
>
> Please CC any replies to me (I'm not subscribed).
> Regards, Krzysztof Kosiński

Can you resend this with a Signed-off-by, so I can ACK it and Len can merge 
it.

Also, please add to your description of this patch that it fixes Bug 12286.

-Carlos

> --- linux-2.6.27/drivers/misc/tc1100-wmi.c	2008-10-10 00:13:53.000000000
> +0200 +++ linux/drivers/misc/tc1100-wmi.c	2008-12-25 02:58:48.000000000
> +0100 @@ -95,9 +95,8 @@
>  		return -ENODEV;
>
>  	obj = (union acpi_object *) result.pointer;
> -	if (obj && obj->type == ACPI_TYPE_BUFFER &&
> -		obj->buffer.length == sizeof(u32)) {
> -		tmp = *((u32 *) obj->buffer.pointer);
> +	if (obj && obj->type == ACPI_TYPE_INTEGER) {
> +		tmp = obj->integer.value;
>  	} else {
>  		tmp = 0;
>  	}
> @@ -110,7 +109,7 @@
>  		*out = (tmp == 3) ? 1 : 0;
>  		return 0;
>  	case TC1100_INSTANCE_JOGDIAL:
> -		*out = (tmp == 1) ? 1 : 0;
> +		*out = (tmp == 1) ? 0 : 1;
>  		return 0;
>  	default:
>  		return -ENODEV;

-- 
E-Mail: carlos@...angeworlds.co.uk
Web: strangeworlds.co.uk
GPG Key ID: 0x23EE722D
--
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