public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Stefan Berger <stefanb@linux.vnet.ibm.com>
To: Jiri Slaby <jirislaby@gmail.com>
Cc: Rajiv Andrade <srajiv@linux.vnet.ibm.com>,
	"Rafael J. Wysocki" <rjw@sisk.pl>,
	linux-pm <linux-pm@lists.linux-foundation.org>,
	stable@kernel.org,
	Linux kernel mailing list <linux-kernel@vger.kernel.org>,
	debora@linux.vnet.ibm.com,
	Linus Torvalds <torvalds@linux-foundation.org>,
	preining@logic.at
Subject: Re: 2.6.37.1 s2disk regression (TPM)
Date: Mon, 21 Feb 2011 19:42:21 -0500	[thread overview]
Message-ID: <4D63066D.3080701@linux.vnet.ibm.com> (raw)
In-Reply-To: <4D62E2F2.4060406@gmail.com>

On 02/21/2011 05:10 PM, Jiri Slaby wrote:
> On 02/21/2011 11:07 PM, Rajiv Andrade wrote:
>> On 02/21/2011 06:44 PM, Jiri Slaby wrote:
>>> On 02/21/2011 10:29 PM, Stefan Berger wrote:
>>>> On 02/21/2011 03:39 PM, Jiri Slaby wrote:
>>>>> On 02/21/2011 06:12 PM, Rajiv Andrade wrote:
>>>>>> On 02/21/2011 01:34 PM, Jiri Slaby wrote:
>>>>>>> There has to be another problem which caused my regression. And
>>>>>>> since it
>>>>>>> reports "Operation Timed out", the former default timeout values
>>>>>>> worked
>>>>>>> for me, the ones read from TPM do not.
>>>>>> Yes, it's highly due inconsistent timeout values reported by the
>>>>>> TPM as
>>>>>> I mentioned, my working timeouts are:
>>>>>> 3020000 4510000 181000000
>>>>> 1000000 2000 150000
>>>>>
>>>>> Actually the first one from HW is 1. This is one is HZ after correction
>>>>> in get_timeout. So perhaps it is in ms, yes.
>>>> Following the specs, the timeouts are supposed to be in microseconds and
>>>> ascending order for short, medium and long duration. Of course, if the
>>>> device returns wrong timeouts, the command isn't going to succeed,
>>>> failing the suspend in this case. Nevertheless, I think we need the
>>>> patch I put in but at the same time we'll need a work-around for devices
>>>> like this.
>>> Yes, the patch is correct per se. But as it breaks bunch of machines it
>>> cannot go in now. The rule is no regressions.
>>>
>>> After you have the workaround it should go into the next rc1 after that.
>>> Do you plan to add a dmi-based quirk? Or, IOW do you want me to attach
>>> dmidecode output? Or are you going to base it solely on TPM
>>> manufacturer/version
>> It's more reliable to base the workaround on the values themselves,
>> instead of the TPM's ID, since
>> we don't know whether other models will behave similarly.
> As I wrote, you may base it on dmi data.
>
>> It should be fine then to extend the existing workaround for short
>> timeouts to the medium and long ones.
> OK, but how will you guess the values?
One way of doing it would be to at least make sure that the timeouts are

short < medium < long

and if that's not true, as in the case of your TPM, set the timeouts to 
0 and have Rajiv's work-around kick in  OR we assign the same high 
values to the timeouts explicily that Rajiv's work-around is using right 
now. Of course there could be another type of bad TPM firmware out there 
where all values are in ascending order but given in ms and cause 
time-outs -- but I would wait for someone to point that out since I am 
not aware of such a device.

Using the manufacturer, firmware version etc. to distinguish would 
probably open a can of worms...

    Stefan


  parent reply	other threads:[~2011-02-22  0:42 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-20 10:13 2.6.37.1 s2disk regression (TPM) Jiri Slaby
2011-02-20 10:44 ` Rafael J. Wysocki
2011-02-20 10:46   ` Jiri Slaby
2011-02-20 10:51     ` Rafael J. Wysocki
2011-02-20 10:57       ` [REVERT request stable-2.6.36/37] " Jiri Slaby
2011-02-20 16:50         ` [stable] " Greg KH
2011-02-20 11:48       ` Rafael J. Wysocki
2011-02-21 15:30         ` Rajiv Andrade
2011-02-21 16:34           ` Jiri Slaby
2011-02-21 16:57             ` Linus Torvalds
2011-02-21 17:12             ` Rajiv Andrade
2011-02-21 20:39               ` Jiri Slaby
2011-02-21 21:29                 ` Stefan Berger
2011-02-21 21:44                   ` Jiri Slaby
2011-02-21 22:07                     ` Rajiv Andrade
2011-02-21 22:10                       ` Jiri Slaby
2011-02-21 22:17                         ` Rafael J. Wysocki
2011-02-22  0:42                         ` Stefan Berger [this message]
2011-02-22  8:41                           ` Jiri Slaby
2011-02-22 11:57                             ` Stefan Berger
2011-02-22 17:39                               ` Jiri Slaby
2011-02-22  5:39           ` Norbert Preining
2011-02-22  8:42             ` Jiri Slaby
2011-02-22  9:13               ` Norbert Preining

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=4D63066D.3080701@linux.vnet.ibm.com \
    --to=stefanb@linux.vnet.ibm.com \
    --cc=debora@linux.vnet.ibm.com \
    --cc=jirislaby@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@lists.linux-foundation.org \
    --cc=preining@logic.at \
    --cc=rjw@sisk.pl \
    --cc=srajiv@linux.vnet.ibm.com \
    --cc=stable@kernel.org \
    --cc=torvalds@linux-foundation.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