#5703 HIGH 8.2.0 (: Lid switch detection is unreliable.

Zarro Boogs per Child bugtracker at laptop.org
Mon Nov 15 12:30:57 EST 2010

#5703: Lid switch detection is unreliable.
           Reporter:  cjb              |       Owner:  dilinger            
               Type:  defect           |      Status:  new                 
           Priority:  high             |   Milestone:  8.2.0 (was Update.2)
          Component:  kernel           |     Version:                      
         Resolution:                   |    Keywords:  power               
        Next_action:  test in release  |    Verified:  0                   
Deployment_affected:                   |   Blockedby:                      
           Blocking:  6590             |  

Comment(by pgf):

 i've now (re)implemented the XO-1 lid-handling, based on mitch's proposal
 in comment 17.  i did this because in implementing wake-on-close, and the
 ability to query lid-state, the 100 usec delay moved from just the resume
 path to the main interrupt handler path.

 the only addendum to mitch's analysis is that we sometimes seem to get
 _both_ positive and negative edge events when i would have expected only a
 positive edge event.  i simply clear both event bits on any interrupt to
 handle that.  but the essential technique of disabling both edge
 detectors, relying on the "implicit" edge detector we get when they're
 both off, and using the front-end inverter, works fine.

Ticket URL: <http://dev.laptop.org/ticket/5703#comment:21>
One Laptop Per Child <http://laptop.org/>
OLPC bug tracking system

More information about the Bugs mailing list