From: Karol Kozimor <sziwan-DETuoxkZsSqrDJvtcaxF/A@public.gmane.org>
To: "Carl-Daniel Hailfinger"
<c-d.hailfinger.devel.2005-hi6Y0CQ0nG0@public.gmane.org>,
"Hanno Böck" <mail-60OJuG18Xr6zQB+pC5nmwQ@public.gmane.org>
Cc: "Moore,
Robert" <robert.moore-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>,
acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org,
Christian Aichinger <Greek0-hi6Y0CQ0nG0@public.gmane.org>
Subject: Re: oops with asus_acpi on P30/P35
Date: Wed, 29 Jun 2005 17:50:15 +0200 [thread overview]
Message-ID: <20050629155015.GB14659@hell.org.pl> (raw)
In-Reply-To: <42C2BA01.2060806-hi6Y0CQ0nG0@public.gmane.org>
Thus wrote Carl-Daniel Hailfinger:
>> Bob, is the implicit return code supposed to trigger also when using
>> acpi_evaluate_object()? FYI, this is what we currently do:
>>
>> write_acpi_int(hotk->handle, "INIT", 0, &buffer) (drivers/acpi/asus_acpi.c)
>>
>> which is fine if the INIT method returns a string (the usual), but
>> apparently not if there is no return statement in the method (the P30
>> case). The old code assumed the buffer will be null in this case.
>>
>> Is that a bug in the ACPICA or should the asus_acpi code cover for other
>> cases of buffer.type?
>
> Will the fix for this be submitted to stable-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org? I can't upgrade
> to 2.6.12.1 because of this oops.
This should fix ya for now, but I can't sign it off until I get a comment
from Bob.
Best regards,
--
Karol 'sziwan' Kozimor
sziwan-DETuoxkZsSqrDJvtcaxF/A@public.gmane.org
--- linux-2.6.12/drivers/acpi/asus_acpi.c~ 2005-06-29 17:37:29.000000000 +0200
+++ linux-2.6.12/drivers/acpi/asus_acpi.c 2005-06-29 17:45:53.000000000 +0200
@@ -990,9 +990,15 @@
else if (bsts_result)
printk(KERN_NOTICE " BSTS called, 0x%02x returned\n", bsts_result);
+ if (buffer.pointer == NULL)
+ return -EINVAL;
+ model = (union acpi_object *) buffer.pointer;
+
/* Samsung P30 has a device with a valid _HID whose INIT does not
* return anything. Catch this one and any similar here */
- if (buffer.pointer == NULL) {
+ if (model->type == ACPI_TYPE_STRING) {
+ printk(KERN_NOTICE " %s model detected, ", model->string.pointer);
+ } else {
if (asus_info && /* Samsung P30 */
strncmp(asus_info->oem_table_id, "ODEM", 4) == 0) {
hotk->model = P30;
@@ -1007,11 +1013,6 @@
return AE_OK;
}
- model = (union acpi_object *) buffer.pointer;
- if (model->type == ACPI_TYPE_STRING) {
- printk(KERN_NOTICE " %s model detected, ", model->string.pointer);
- }
-
hotk->model = END_MODEL;
if (strncmp(model->string.pointer, "L3D", 3) == 0)
hotk->model = L3D;
-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
next prev parent reply other threads:[~2005-06-29 15:50 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-06-18 0:45 oops with asus_acpi on P30/P35 Christian Aichinger
[not found] ` <20050618004506.GE3690-eJYrgmUciHpxYM3rXe3Iuw@public.gmane.org>
2005-06-29 11:10 ` Karol Kozimor
[not found] ` <20050629111044.GA2910-DETuoxkZsSqrDJvtcaxF/A@public.gmane.org>
2005-06-29 15:10 ` Carl-Daniel Hailfinger
[not found] ` <42C2BA01.2060806-hi6Y0CQ0nG0@public.gmane.org>
2005-06-29 15:50 ` Karol Kozimor [this message]
[not found] ` <20050629155015.GB14659-DETuoxkZsSqrDJvtcaxF/A@public.gmane.org>
2005-08-19 15:49 ` Hanno Böck
[not found] ` <200508191749.18016.mail-60OJuG18Xr6zQB+pC5nmwQ@public.gmane.org>
2005-08-21 14:36 ` Timo Hoenig
[not found] ` <1124634977.4952.9.camel-dCxI//HcOdFeoWH0uzbU5w@public.gmane.org>
2005-09-21 9:08 ` Christian Aichinger
[not found] ` <20050921090810.GS22403-eJYrgmUciHpxYM3rXe3Iuw@public.gmane.org>
2005-09-21 11:47 ` Hanno Böck
[not found] ` <200509211347.13322.mail-60OJuG18Xr6zQB+pC5nmwQ@public.gmane.org>
2005-09-21 14:39 ` Christian Aichinger
2005-09-21 13:39 ` Timo Hoenig
[not found] ` <1127309993.26683.15.camel-1iW2g3EOClSoYr4blSSd5g@public.gmane.org>
2005-09-21 15:08 ` Christian Aichinger
[not found] ` <20050921150851.GU22403-eJYrgmUciHpxYM3rXe3Iuw@public.gmane.org>
2005-09-22 12:13 ` Karol Kozimor
[not found] ` <20050922121342.GA9462-DETuoxkZsSqrDJvtcaxF/A@public.gmane.org>
2005-09-22 12:52 ` Christian Aichinger
2005-09-22 14:31 ` Timo Hoenig
2005-09-23 23:36 ` [PATCH] acpi: Fix oops in asus_acpi.c on Samsung P30/P35 Laptops Christian Aichinger
-- strict thread matches above, loose matches on Subject: below --
2005-06-29 16:09 oops with asus_acpi on P30/P35 Moore, Robert
[not found] ` <971FCB6690CD0E4898387DBF7552B90E01F61BCB-sBd4vmA9Se5Qxe9IK+vIArfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2005-06-29 16:35 ` Karol Kozimor
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20050629155015.GB14659@hell.org.pl \
--to=sziwan-detuoxkzssqrdjvtcaxf/a@public.gmane.org \
--cc=Greek0-hi6Y0CQ0nG0@public.gmane.org \
--cc=acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org \
--cc=c-d.hailfinger.devel.2005-hi6Y0CQ0nG0@public.gmane.org \
--cc=mail-60OJuG18Xr6zQB+pC5nmwQ@public.gmane.org \
--cc=robert.moore-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox