[ltp] Re: Re: EC Hanging with latest tp-smapi (0.29)

TNKS linux-thinkpad@linux-thinkpad.org
Wed, 23 Aug 2006 10:03:48 -0500


Shem Multinymous wrote:
 
> OK, that rules out one cause. Can you try the following patch too, and
> report the first ~20 dmesg lines starting with the first "weird" one?
> 
> --- a/thinkpad_ec.c
> +++ b/thinkpad_ec.c
> @@ -63,3 +63,3 @@
>  #define TPC_READ_NDELAY     500
> -#define TPC_REQUEST_RETRIES 100
> +#define TPC_REQUEST_RETRIES 1000
>  #define TPC_REQUEST_NDELAY   10
> @@ -229,2 +229,6 @@
>  MSG_FMT("OBF3B=1 after read (0x%02x)", str3));
> +     /* If port 0x161F returns 0x80 too often, the EC may lock up: */
> +     if (data->val[0xF] == 0x80)
> +             printk(KERN_WARNING
> +                    MSG_FMT("0x161F indicates error", data->val[0xF]));
>  return 0;

Sorry,

This hung too...  Here's the relevant section of the kernel log starting
with my loading of the tp_smapi module with the patch above:

Aug 23 09:42:07 hole kernel: thinkpad_ec: thinkpad_ec 0.29 loaded.
Aug 23 09:42:07 hole kernel: tp_smapi 0.29 loading...
Aug 23 09:42:07 hole kernel: tp_smapi successfully loaded (smapi_port=0xb2).
Aug 23 09:43:03 hole kernel: thinkpad_ec: thinkpad_ec_request_row: EC is
mysteriously silent: (0x00:0x00)->0xa0
Aug 23 09:43:03 hole kernel: thinkpad_ec: thinkpad_ec_read_row: failed
requesting row: (0x00:0x00)->0xfffffffb
Aug 23 09:43:03 hole kernel: thinkpad_ec: thinkpad_ec_request_row: bad
initial STR3: (0x00:0x00)->0xa0
Aug 23 09:43:03 hole kernel: thinkpad_ec: thinkpad_ec_read_row: failed
requesting row: (0x00:0x00)->0xfffffffb
Aug 23 09:43:03 hole kernel: thinkpad_ec: thinkpad_ec_request_row: bad
initial STR3: (0x00:0x00)->0xa0
Aug 23 09:43:03 hole kernel: thinkpad_ec: thinkpad_ec_read_row: failed
requesting row: (0x00:0x00)->0xfffffffb
Aug 23 09:43:03 hole kernel: thinkpad_ec: thinkpad_ec_request_row: bad
initial STR3: (0x00:0x00)->0xa0
Aug 23 09:43:03 hole kernel: thinkpad_ec: thinkpad_ec_read_row: failed
requesting row: (0x00:0x00)->0xfffffffb
Aug 23 09:43:03 hole kernel: thinkpad_ec: thinkpad_ec_request_row: bad
initial STR3: (0x00:0x00)->0xa0

It just repeats until I forceably shut down the machine (I'm pretty sure
this is the same behavior I observed when I posted originally).  From the
time stamps I counted and about 200 lines of text reported per second, so
this is a really tight loop.

I'm happy to help you dig deeper.  Just let me know what's next.  Also, just
to help us keep our assessments straight, it might help to modify the
version number slightly to serialize our experiments.  That way, when the
module is loaded, we have a clear marker of it in the kernel log (takes a
little pressure off me to make sure I'm working with the right patch). 
Since you're making the patches, I thought maybe it might be something you
could remember to do.  If not, I'll do it on my end.

- Sukant