public inbox for linux-acpi@vger.kernel.org
 help / color / mirror / Atom feed
* RE: help needed with invalid method in GPE block
@ 2003-03-18  0:34 Grover, Andrew
       [not found] ` <F760B14C9561B941B89469F59BA3A84725A201-sBd4vmA9Se4Lll3ZsUKC9FDQ4js95KgL@public.gmane.org>
  0 siblings, 1 reply; 16+ messages in thread
From: Grover, Andrew @ 2003-03-18  0:34 UTC (permalink / raw)
  To: Charl P. Botha, Moore, Robert; +Cc: acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f

> From: Charl P. Botha [mailto:c.p.botha-ra0OqMccq8edIhEUFHOBvg@public.gmane.org] 
> My frikking sleep button is still not waking my laptop up 
> though.  I would
> appreciate any other tips for debugging that problem.

I would guess that we are disabling your sleep button's GPE when we are
sleeping.

To verify this, you might try calling _PRW from the button driver (or
just look at the ASL), and then using that GPE number call
acpi_enable_gpe(gpe_num, NULL, ACPI_EVENT_WAKE_ENABLE).

This is not the correct long-term solution but it should at least verify
the root cause of the problem...

Regards -- Andy


-------------------------------------------------------
This SF.net email is sponsored by:Crypto Challenge is now open! 
Get cracking and register here for some mind boggling fun and 
the chance of winning an Apple iPod:
http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0031en

^ permalink raw reply	[flat|nested] 16+ messages in thread
* RE: help needed with invalid method in GPE block
@ 2003-03-18 22:25 Moore, Robert
       [not found] ` <B9ECACBD6885D5119ADC00508B68C1EA0D19BBD5-LkGsggTGxVmSsB6bSF6DdVDQ4js95KgL@public.gmane.org>
  0 siblings, 1 reply; 16+ messages in thread
From: Moore, Robert @ 2003-03-18 22:25 UTC (permalink / raw)
  To: 'Charl P. Botha', Grover, Andrew
  Cc: Moore, Robert, acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f

So,
We are calling acpi_hw_enable_gpe() on 0x1D or not?



> -----Original Message-----
> From: Charl P. Botha [mailto:c.p.botha-ra0OqMccq8edIhEUFHOBvg@public.gmane.org]
> Sent: Tuesday, March 18, 2003 2:09 PM
> To: Grover, Andrew
> Cc: Moore, Robert; acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
> Subject: Re: [ACPI] help needed with invalid method in GPE block
> 
> On Tue, Mar 18, 2003 at 01:54:11PM -0800, Grover, Andrew wrote:
> > > Through printk()s all over, it seems that the acpi code never
> > > explicitly
> > > enables the 0x1D event on my machine at all, nevermind enabling it for
> > > waking.  Is this a problem with my firmware/dsdt or with the
> > > acpi kernel
> > > code?
> >
> > Are you sure? We should be calling acpi_ev_save_method_info for each
> > _Lxx or _Exx entry under _GPE scope, and that function enables the GPE.
> > Please let me know if this is not the case.
> 
> I'm quite sure.  Yes, you do call acpi_ev_save_method_info() for each _Lxx
> and _Exx method, but in acpi_ev_save_method_info() you only call
> acpi_hw_enable_gpe() and NEVER acpi_hw_enable_gpe_for_wakeup().  As a
> matter
> of fact, shouldn't that call rather be acpi_enable_event() (INSTEAD of
> acpi_hw_enable_gpe()) with the WAKEUP parameter according to some mask?
> 
> Fact is, with my ACPI-untrained eyes, I couldn't find any occurrence where
> acpi_hw_enable_gpe_for_wakeup() is directly or indirectly called for the
> sleep button method (_L1D in my case).
> 
> Your thoughts?
> 
> Thanks,
> Charl
> 
> --
> charl p. botha http://cpbotha.net/ http://visualisation.tudelft.nl/
> 
> 
> -------------------------------------------------------
> This SF.net email is sponsored by: Does your code think in ink?
> You could win a Tablet PC. Get a free Tablet PC hat just for playing.
> What are you waiting for?
> http://ads.sourceforge.net/cgi-bin/redirect.pl?micr5043en
> _______________________________________________
> Acpi-devel mailing list
> Acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
> https://lists.sourceforge.net/lists/listinfo/acpi-devel


-------------------------------------------------------
This SF.net email is sponsored by: Does your code think in ink? 
You could win a Tablet PC. Get a free Tablet PC hat just for playing. 
What are you waiting for?
http://ads.sourceforge.net/cgi-bin/redirect.pl?micr5043en

^ permalink raw reply	[flat|nested] 16+ messages in thread
* RE: help needed with invalid method in GPE block
@ 2003-03-18 22:24 Grover, Andrew
       [not found] ` <F760B14C9561B941B89469F59BA3A84725A204-sBd4vmA9Se4Lll3ZsUKC9FDQ4js95KgL@public.gmane.org>
  0 siblings, 1 reply; 16+ messages in thread
From: Grover, Andrew @ 2003-03-18 22:24 UTC (permalink / raw)
  To: Charl P. Botha; +Cc: Moore, Robert, acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f

> From: Charl P. Botha [mailto:c.p.botha-ra0OqMccq8edIhEUFHOBvg@public.gmane.org] 
> > > Through printk()s all over, it seems that the acpi code never 
> > > explicitly
> > > enables the 0x1D event on my machine at all, nevermind 
> enabling it for
> > > waking.  Is this a problem with my firmware/dsdt or with the 
> > > acpi kernel
> > > code?
> > 
> > Are you sure? We should be calling acpi_ev_save_method_info for each
> > _Lxx or _Exx entry under _GPE scope, and that function 
> enables the GPE.
> > Please let me know if this is not the case.
> 
> I'm quite sure.  Yes, you do call acpi_ev_save_method_info() 
> for each _Lxx
> and _Exx method, but in acpi_ev_save_method_info() you only call
> acpi_hw_enable_gpe() and NEVER 
> acpi_hw_enable_gpe_for_wakeup().  As a matter
> of fact, shouldn't that call rather be acpi_enable_event() (INSTEAD of
> acpi_hw_enable_gpe()) with the WAKEUP parameter according to 
> some mask?

I agree that it is currently never enabled for wakeup, but you said we
never enable it at all, the opposite of what your last email said. I
guess I'll assume the second statement is what you meant.

BTW here is the bug:
http://bugme.osdl.org/show_bug.cgi?id=470

Apparently it only allows CCs to registered people, so I couldn't add
you, but if you have any extra comments, feel free to register and add
them there.

Regards -- Andy



-------------------------------------------------------
This SF.net email is sponsored by: Does your code think in ink? 
You could win a Tablet PC. Get a free Tablet PC hat just for playing. 
What are you waiting for?
http://ads.sourceforge.net/cgi-bin/redirect.pl?micr5043en

^ permalink raw reply	[flat|nested] 16+ messages in thread
* RE: help needed with invalid method in GPE block
@ 2003-03-18 21:54 Grover, Andrew
       [not found] ` <F760B14C9561B941B89469F59BA3A84725A203-sBd4vmA9Se4Lll3ZsUKC9FDQ4js95KgL@public.gmane.org>
  0 siblings, 1 reply; 16+ messages in thread
From: Grover, Andrew @ 2003-03-18 21:54 UTC (permalink / raw)
  To: Charl P. Botha; +Cc: Moore, Robert, acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f

> From: Charl P. Botha [mailto:c.p.botha-ra0OqMccq8edIhEUFHOBvg@public.gmane.org] 
> > > I was planning on adding this just after the
> > > status = acpi_hw_enable_gpe (gpe_event_info);
> > > call in the acpi_ev_save_method_info() function of 
> evgpeblk.c IF the
> > > gpe_num is 0x1D.  Is this okay for verifying?
> > 
> > I would think so, but there's only one way to find out...
> 
> Yay, my frikking sleep button is now waking the laptop from 
> sleep! Nevermind
> the fact that everything else is still dead (these problems 
> seem a tad more
> tractable), the BUTTON IS WORKING.

Great.

> Through printk()s all over, it seems that the acpi code never 
> explicitly
> enables the 0x1D event on my machine at all, nevermind enabling it for
> waking.  Is this a problem with my firmware/dsdt or with the 
> acpi kernel
> code?

Are you sure? We should be calling acpi_ev_save_method_info for each
_Lxx or _Exx entry under _GPE scope, and that function enables the GPE.
Please let me know if this is not the case.

> I ran into some *cough* Microsoft documents *cough* online 
> that claimed that
> *cough* Windows *cough* enabled/disabled certain devices for waking.
> According to these documents, the sleep button was always 
> enabled.  Should
> Linux ACPI be doing the same?

Yes. The button driver should be enabling its devices for wakeup. I
think the ACPI bus code should  export a function that makes this easy
to do.

I am going to stick this in kernel.bugzilla.org so we don't forget about
it, and I will add you to the CC list.

Regards -- Andy


-------------------------------------------------------
This SF.net email is sponsored by: Does your code think in ink? 
You could win a Tablet PC. Get a free Tablet PC hat just for playing. 
What are you waiting for?
http://ads.sourceforge.net/cgi-bin/redirect.pl?micr5043en

^ permalink raw reply	[flat|nested] 16+ messages in thread
* RE: help needed with invalid method in GPE block
@ 2003-03-18 17:21 Grover, Andrew
       [not found] ` <F760B14C9561B941B89469F59BA3A847E96D1A-sBd4vmA9Se4Lll3ZsUKC9FDQ4js95KgL@public.gmane.org>
  0 siblings, 1 reply; 16+ messages in thread
From: Grover, Andrew @ 2003-03-18 17:21 UTC (permalink / raw)
  To: Charl P. Botha; +Cc: Moore, Robert, acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f

> From: Charl P. Botha [mailto:c.p.botha-ra0OqMccq8edIhEUFHOBvg@public.gmane.org] 
> > To verify this, you might try calling _PRW from the button 
> driver (or
> > just look at the ASL), and then using that GPE number call
> > acpi_enable_gpe(gpe_num, NULL, ACPI_EVENT_WAKE_ENABLE).
> 
> Can I assume that you mean:
> acpe_enable_event(gpe_num, ACPI_EVENT_GPE, ACPI_EVENT_WAKE_ENABLE);
> where gpe_num is in my case 0x1D (the method in the asl is _L1D)?

Hehe yes. Did I mention the next version will change that interface? :)

> I was planning on adding this just after the
> status = acpi_hw_enable_gpe (gpe_event_info);
> call in the acpi_ev_save_method_info() function of evgpeblk.c IF the
> gpe_num is 0x1D.  Is this okay for verifying?

I would think so, but there's only one way to find out...

Regards -- Andy


-------------------------------------------------------
This SF.net email is sponsored by: Does your code think in ink? 
You could win a Tablet PC. Get a free Tablet PC hat just for playing. 
What are you waiting for?
http://ads.sourceforge.net/cgi-bin/redirect.pl?micr5043en

^ permalink raw reply	[flat|nested] 16+ messages in thread
[parent not found: <B9ECACBD6885D5119ADC00508B68C1EA0D19BBCC@orsmsx107.jf.intel.com>]
* RE: help needed with invalid method in GPE block
@ 2003-03-17 23:07 Moore, Robert
       [not found] ` <B9ECACBD6885D5119ADC00508B68C1EA0D19BBCB-LkGsggTGxVmSsB6bSF6DdVDQ4js95KgL@public.gmane.org>
  0 siblings, 1 reply; 16+ messages in thread
From: Moore, Robert @ 2003-03-17 23:07 UTC (permalink / raw)
  To: 'Charl P. Botha',
	acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f

You can ignore the GPE error messages, they are leftover cruft and have no
meaning.


> -----Original Message-----
> From: Charl P. Botha [mailto:c.p.botha-ra0OqMccq8edIhEUFHOBvg@public.gmane.org]
> Sent: Monday, March 17, 2003 1:35 PM
> To: acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
> Subject: [ACPI] help needed with invalid method in GPE block
> 
> Dear list,
> 
> I'm still trying to get my stupid sleep/wake-button to wake my laptop.
> This
> is quite interesting:
> 
> ACPI Namespace successfully loaded at root c02cdcfc
> evxfevnt-0092 [04] acpi_enable           : Transition to ACPI mode
> successful
>    evgpe-0416 [06] ev_create_gpe_block   : GPE Block: 2 registers at
> 0000000000001028
>    evgpe-0421 [06] ev_create_gpe_block   : GPE Block defined as GPE0 to
> GPE15
>    evgpe-0138 [08] ev_save_method_info   : GPE number associated with
> method _L1D is not valid
>    evgpe-0416 [06] ev_create_gpe_block   : GPE Block: 2 registers at
> 000000000000102C
>    evgpe-0421 [06] ev_create_gpe_block   : GPE Block defined as GPE16 to
> GPE31
>    evgpe-0138 [08] ev_save_method_info   : GPE number associated with
> method _L05 is not valid
>    evgpe-0138 [08] ev_save_method_info   : GPE number associated with
> method _L1D is not valid
> 
> Coincidentally, in my dsdt _L1D (the one with invalid number above) is a
> control method for my sleep button (control method type, not hard-wired).
> This _could_ explain why the button is not doing anything when pressed
> during sleep:
> 
>         Method (_L1D, 0, NotSerialized)
>         {
>             Notify (\_SB.SLPB, 0x02)
>         }
> 
> This is in the \_GPE scope.  I've tried hacking the control method sleep
> button example on page 66 of ACPIspec-2-0a.pdf into my dsdt as method
> _L01,
> but to no avail.  Then ACPI just claims that _L01 is invalid for the
> *second* GPE block:
> 
> evxfevnt-0092 [04] acpi_enable           : Transition to ACPI mode
> successful
> evgpe-0416 [06] ev_create_gpe_block   : GPE Block: 2 registers at
> 0000000000001028
> evgpe-0421 [06] ev_create_gpe_block   : GPE Block defined as GPE0 to GPE15
> evgpe-0138 [08] ev_save_method_info   : GPE number associated with method
> _L1D is not valid
> evgpe-0416 [06] ev_create_gpe_block   : GPE Block: 2 registers at
> 000000000000102C
> evgpe-0421 [06] ev_create_gpe_block   : GPE Block defined as GPE16 to
> GPE31
> evgpe-0138 [08] ev_save_method_info   : GPE number associated with method
> _L05 is not valid
> evgpe-0138 [08] ev_save_method_info   : GPE number associated with method
> _L1D is not valid
> evgpe-0138 [08] ev_save_method_info   : GPE number associated with method
> _L01 is not valid
> 
> In both cases, my fixed DSDT compiled with iasl 20030228 with no errors
> and
> no warnings.
> 
> Can anyone explain to me why I have two GPE blocks?  This means (according
> to the code logic in the acpi driver) that a control method is ALWAYS
> going
> to have an invalid GPE number in at least one of the two blocks.
> 
> If anyone is interested, my original dsdt is here:
> http://cpbotha.net/thingies/dsdt.asl.original
> and the hacked one is here:
> http://cpbotha.net/thingies/dsdt.asl
> 
> The object of the game is to get my wake button to wake. :)
> 
> Thanks,
> Charl
> 
> --
> charl p. botha http://cpbotha.net/ http://visualisation.tudelft.nl/
> 
> 
> -------------------------------------------------------
> This SF.net email is sponsored by:Crypto Challenge is now open!
> Get cracking and register here for some mind boggling fun and
> the chance of winning an Apple iPod:
> http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0031en
> _______________________________________________
> Acpi-devel mailing list
> Acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
> https://lists.sourceforge.net/lists/listinfo/acpi-devel


-------------------------------------------------------
This SF.net email is sponsored by:Crypto Challenge is now open! 
Get cracking and register here for some mind boggling fun and 
the chance of winning an Apple iPod:
http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0031en

^ permalink raw reply	[flat|nested] 16+ messages in thread
* help needed with invalid method in GPE block
@ 2003-03-17 21:34 Charl P. Botha
  0 siblings, 0 replies; 16+ messages in thread
From: Charl P. Botha @ 2003-03-17 21:34 UTC (permalink / raw)
  To: acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f

Dear list,

I'm still trying to get my stupid sleep/wake-button to wake my laptop.  This
is quite interesting:

ACPI Namespace successfully loaded at root c02cdcfc
evxfevnt-0092 [04] acpi_enable           : Transition to ACPI mode successful
   evgpe-0416 [06] ev_create_gpe_block   : GPE Block: 2 registers at 0000000000001028
   evgpe-0421 [06] ev_create_gpe_block   : GPE Block defined as GPE0 to GPE15
   evgpe-0138 [08] ev_save_method_info   : GPE number associated with method _L1D is not valid
   evgpe-0416 [06] ev_create_gpe_block   : GPE Block: 2 registers at 000000000000102C
   evgpe-0421 [06] ev_create_gpe_block   : GPE Block defined as GPE16 to GPE31
   evgpe-0138 [08] ev_save_method_info   : GPE number associated with method _L05 is not valid
   evgpe-0138 [08] ev_save_method_info   : GPE number associated with method _L1D is not valid

Coincidentally, in my dsdt _L1D (the one with invalid number above) is a
control method for my sleep button (control method type, not hard-wired).
This _could_ explain why the button is not doing anything when pressed
during sleep:

        Method (_L1D, 0, NotSerialized) 
        {
            Notify (\_SB.SLPB, 0x02)
        }

This is in the \_GPE scope.  I've tried hacking the control method sleep
button example on page 66 of ACPIspec-2-0a.pdf into my dsdt as method _L01,
but to no avail.  Then ACPI just claims that _L01 is invalid for the
*second* GPE block:

evxfevnt-0092 [04] acpi_enable           : Transition to ACPI mode successful
evgpe-0416 [06] ev_create_gpe_block   : GPE Block: 2 registers at 0000000000001028
evgpe-0421 [06] ev_create_gpe_block   : GPE Block defined as GPE0 to GPE15
evgpe-0138 [08] ev_save_method_info   : GPE number associated with method _L1D is not valid
evgpe-0416 [06] ev_create_gpe_block   : GPE Block: 2 registers at 000000000000102C
evgpe-0421 [06] ev_create_gpe_block   : GPE Block defined as GPE16 to GPE31
evgpe-0138 [08] ev_save_method_info   : GPE number associated with method _L05 is not valid
evgpe-0138 [08] ev_save_method_info   : GPE number associated with method _L1D is not valid
evgpe-0138 [08] ev_save_method_info   : GPE number associated with method _L01 is not valid

In both cases, my fixed DSDT compiled with iasl 20030228 with no errors and
no warnings.

Can anyone explain to me why I have two GPE blocks?  This means (according
to the code logic in the acpi driver) that a control method is ALWAYS going
to have an invalid GPE number in at least one of the two blocks.

If anyone is interested, my original dsdt is here:
http://cpbotha.net/thingies/dsdt.asl.original
and the hacked one is here:
http://cpbotha.net/thingies/dsdt.asl

The object of the game is to get my wake button to wake. :)

Thanks,
Charl

-- 
charl p. botha http://cpbotha.net/ http://visualisation.tudelft.nl/


-------------------------------------------------------
This SF.net email is sponsored by:Crypto Challenge is now open! 
Get cracking and register here for some mind boggling fun and 
the chance of winning an Apple iPod:
http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0031en

^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2003-03-19  8:38 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-03-18  0:34 help needed with invalid method in GPE block Grover, Andrew
     [not found] ` <F760B14C9561B941B89469F59BA3A84725A201-sBd4vmA9Se4Lll3ZsUKC9FDQ4js95KgL@public.gmane.org>
2003-03-18  8:51   ` Charl P. Botha
2003-03-18 12:54   ` Charl P. Botha
  -- strict thread matches above, loose matches on Subject: below --
2003-03-18 22:25 Moore, Robert
     [not found] ` <B9ECACBD6885D5119ADC00508B68C1EA0D19BBD5-LkGsggTGxVmSsB6bSF6DdVDQ4js95KgL@public.gmane.org>
2003-03-18 22:33   ` Charl P. Botha
2003-03-18 22:24 Grover, Andrew
     [not found] ` <F760B14C9561B941B89469F59BA3A84725A204-sBd4vmA9Se4Lll3ZsUKC9FDQ4js95KgL@public.gmane.org>
2003-03-19  8:38   ` Charl P. Botha
2003-03-18 21:54 Grover, Andrew
     [not found] ` <F760B14C9561B941B89469F59BA3A84725A203-sBd4vmA9Se4Lll3ZsUKC9FDQ4js95KgL@public.gmane.org>
2003-03-18 22:09   ` Charl P. Botha
2003-03-18 17:21 Grover, Andrew
     [not found] ` <F760B14C9561B941B89469F59BA3A847E96D1A-sBd4vmA9Se4Lll3ZsUKC9FDQ4js95KgL@public.gmane.org>
2003-03-18 21:44   ` Charl P. Botha
     [not found] <B9ECACBD6885D5119ADC00508B68C1EA0D19BBCC@orsmsx107.jf.intel.com>
     [not found] ` <B9ECACBD6885D5119ADC00508B68C1EA0D19BBCC-LkGsggTGxVmSsB6bSF6DdVDQ4js95KgL@public.gmane.org>
2003-03-18  0:19   ` Charl P. Botha
     [not found]     ` <20030318001918.GA651-V1rPnKwUOrA59+mn7qD7y50iERQUc4G+@public.gmane.org>
2003-03-18  8:54       ` Charl P. Botha
2003-03-17 23:07 Moore, Robert
     [not found] ` <B9ECACBD6885D5119ADC00508B68C1EA0D19BBCB-LkGsggTGxVmSsB6bSF6DdVDQ4js95KgL@public.gmane.org>
2003-03-17 23:20   ` Charl P. Botha
2003-03-17 21:34 Charl P. Botha

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox