public inbox for linux-acpi@vger.kernel.org
 help / color / mirror / Atom feed
From: Szymon Olko <szymonolko@o2.pl>
To: corentincj@iksaif.net, acpi4asus-user@lists.sourceforge.net
Cc: linux-acpi@vger.kernel.org
Subject: Re: Asus V1j
Date: Sat, 24 Mar 2007 15:47:35 +0200	[thread overview]
Message-ID: <46052BF7.3030602@o2.pl> (raw)
In-Reply-To: <200703241415.04656.corentincj@iksaif.net>

Corentin CHARY napisał(a):
> Mail cced to linux-acpi@vger.kernel.org, they may be able to help us =)
>
> Le Saturday 24 March 2007 13:43:26 Szymon Olko, vous avez écrit :
>   
>> Dear *,
>>
>> Finally I found some time to play with buttons in my V1j. At first
>> thanks for great work!!!
>>
>> I'm not acpi nor dsdt guru, but I looked into the code and this is what
>> I found out.
>> Module is working very good, almost all buttons are working. So I
>> decided to play with my DSDT.
>> I had few problems, and this is how I solved them or I think should be
>> solved.
>>
>> 1. In /proc/acpi/events few keys which looks normal in DSDT are not
>> reported. I found that all of them have code bigger than 0x80. I founded
>> those lines and changed them to return codes below 0x80 (to ones that
>> are not used) and that solved problem. I did not have time to look into
>> acpi source code and maybe my solution is not the best way to do it, and
>> maybe not solves the problem, but works for me.
>> Example:
>>
>>     - F2 wifi button
>>     //Notify (\_SB.ATKD, 0x88)
>>     Notify (\_SB.ATKD, 0x56)
>>
>> The only exception is sleep button F1 but it is notified not to
>> \_SB.ATKD but to \_SB.SLPB and is processed by buttons module.
>>
>> Notify (\_SB.SLPB, 0x80)
>>
>> Is it a bug or a feature that codes over 0x80 are not reported?
>>     
> I don't know :/ So, let's ask linux-acpi@vger.kernel.org
>
>   
Thx for forwarding problem.
>
>   
>> 2. This laptop has doubled buttons.
>>     
> Thanks asus :D
>
>   
>> 3. Brightness  buttons (F5 ; F6). They ware generation exceptions like:
>>
>> ACPI Error (psargs-0355): [\_SB_.PCI0.P0P2.VGA_.LCDD] Namespace lookup
>> failure, AE_NOT_FOUND ACPI Error (psparse-0537): Method parse/execution
>> failed [\_SB_.PCI0.SBRG.EC0_._Q0E] (Node c194bf40), AE_NOT_FOUND
>>
>> As far as I understand this problem it is a problem of DSDT which tries
>> to notify about an event with not defined namespace. This is this line
>>     Notify (\_SB.PCI0.P0P2.VGA.LCDD, 0x87)
>> I will try to solve that later, because method that process F5 also
>> decrement brightness, for now the hack is as follows:
>>
>>             Method (_Q0F, 0, NotSerialized)            //bright F5
>>             {
>> /*
>>                 If (LEqual (OSFG, OSVT))
>>                 {
>>                     Notify (\_SB.PCI0.P0P2.VGA.LCDD, 0x87)
>>                 }
>>                 Else
>>                 {
>>                     If (LGreater (LBTN, 0x00))
>>                     {
>>                         Decrement (LBTN)
>>                     }
>>
>>                     If (LGreater (LBTN, 0x0F))
>>                     {
>>                         Store (0x0F, LBTN)
>>                     }
>>
>>                     STBR ()
>> */
>>                     If (\_SB.ATKP)
>>                     {
>> //                        Notify (\_SB.ATKD, Add (LBTN, 0x20))
>>                         Notify (\_SB.ATKD, 0x52)
>>                     }
>> /*
>>                 }
>>
>>                 Return (One)
>> */
>>             }
>>
>> I commented whole code of that method and just notify about button
>> pressed. As for now backlight is working with video module or with
>> asus_laptop via /sys/class/backlight/asus-laptop/brightness it can be
>> easily workaround with simple script. But as I said I will try to fix
>> DSDT later. For F6 code is similar.
>>     
> Hum, you can just remove the 
>                  If (LEqual (OSFG, OSVT))
>                  {
>                      Notify (\_SB.PCI0.P0P2.VGA.LCDD, 0x87)
>                  }
>                  Else
>                  {
> and it shall work .. But it's a serious issue, as this problem have been 
> reported on other laptop .... What should we do with 
> Notify (\_SB.PCI0.P0P2.VGA.LCDD, 0x87) ?
> (I think OSVT is for Os Vista).
>
>   
I did that an now it works beautiful. Returning 0x1y and 0x2y where y is 
state of brightness.
>> 4. Multimedia button, the first on the left side from top buttons. On
>> windows it runs full screen application to what movies, presentation and
>> listen music. I made a change like with brightness buttons:
>>
>>             Method (_Q51, 0, NotSerialized)
>> //multimedia (top)
>>             {
>> /*
>>                 \_SB.PCI0.SBRG.EC0.WRAM (0x04, 0xCB, 0x09)
>>                 Store (One, Local0)
>>                 While (Local0)
>>                 {
>>                     If (\_SB.ATKP)
>>                     {
>>                         SPIN (0x23, 0x00)
>>                         Sleep (0x32)
>>                         SPIN (0x23, 0x01)
>>                     }
>>
>>                     Store (Zero, Local2)
>>                     If (\_SB.PCI0.SBRG.EC0.RPIN (0x43))
>>                     {
>>                         Or (Local2, 0x04, Local2)
>>                     }
>>
>>                     If (\_SB.PCI0.SBRG.EC0.RPIN (0x43))
>>                     {
>>                         Or (Local2, 0x02, Local2)
>>                     }
>>
>>                     If (\_SB.PCI0.SBRG.EC0.RPIN (0x43))
>>                     {
>>                         Or (Local2, 0x01, Local2)
>>                     }
>>
>>                     If (LEqual (Local2, 0x07))
>>                     {
>>                         \_SB.PCI0.SBRG.EC0.WRAM (0x04, 0xCB, 0x89)
>>                         Notify (\_SB.ATKD, 0x95)
>>                         Store (Zero, Local0)
>>                     }
>>                 }
>> */
>>                     If (\_SB.ATKP)
>>                     {
>>                         Notify (\_SB.ATKD, 0x68)
>>                     }
>>             }
>> But it notify to the /proc/acpi/event for the first time it is pressed.
>> Next time I press it, it does do nothing. Again I need more time to look
>> what this method should do but looking on the code it is strange that
>> \_SB.PCI0.SBRG.EC0.RPIN (0x43) is checked few times. This is still
>> pending to be solved. Maybe I commended to much, and there is no state
>> wrote to memory, and that is why it is not called again.
>>
>> 5. The last big mystery are media control buttons (play, stop, rewind,
>> forward). I cannot find the in DSDT. I found something that I think
>> should be connected to those keys.
>>             Method (_Q6E, 0, NotSerialized)            //unknown 1
>>             {
>>                 If (\_SB.ATKP)
>>                 {
>> //                    Notify (\_SB.ATKD, 0x8A)
>>                     Notify (\_SB.ATKD, 0x65)
>>                 }
>>             }
>> ////////////////////////////////////
>>             Method (_Q6F, 0, NotSerialized)            //unknown 3
>>             {
>>                 If (\_SB.ATKP)
>>                 {
>> //                    Notify (\_SB.ATKD, 0x99)
>>                     Notify (\_SB.ATKD, 0x67)
>>                 }
>>             }
>> But those are two keys not four. And my values are not reported in
>> /proc/acpi/events.
>>     
> Does they work on the other OS ?
>   
Will try that now with windows xp. I uninstalled some drivers, because 
it was so heavy and system was very slow.
>> ---------------
>> That is all about buttons. Summarizing, all except (play, stop, rewind,
>> forward) are working, multimedia is working once.
>> This laptop does not have TLED but DSDT says so. I don't know why it is
>> for. From looking into DSDT WLED and BLED are handled almost the same as
>> MLED. Is it possible to make a change in asus_laptop to have those leds
>> visible in /sys/class/leds?
>>     
> I didn't find a way to know if BLED and WLED will handle the device, the led, 
> or both .. So I can't move them to /sys/class/leds ..
>   
My mistake, now I see it is working via 
/sys/devices/platform/asus-laptop/ (bluetooth and wlan).
>   
>> Asus laptops in Windows notifies about plugin connector into sound
>> device. I think that this code:
>>         Method (_L05, 0, NotSerialized)
>>         {
>>             Notify (\_SB.PCI0.MC97, 0x02)
>>             Notify (\_SB.PCI0.HDAC, 0x02)
>>         }
>> Maybe responsible for that. Are any modules that handles this? Am I wright?
>>     
> I don't think any modules handles this .. But MC97 seems to be a modem 
> controller.
>   
Yes, i think also this is a modem. I think that HDAC may stand for HIGH 
DEFINITON AUDIO CONTROLER or CODEC. Audio device is intel High Definition.

Thanks again

S.O.

-
To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2007-03-24 13:48 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <46051CEE.4030402@o2.pl>
2007-03-24 13:15 ` Asus V1j Corentin CHARY
2007-03-24 13:46   ` Szymon Olko
2007-03-24 13:47   ` Szymon Olko [this message]
2007-03-26  4:32   ` Notify(0x88) (was Re: Asus V1j) Len Brown
2007-03-26 19:26     ` Szymon Olko

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=46052BF7.3030602@o2.pl \
    --to=szymonolko@o2.pl \
    --cc=acpi4asus-user@lists.sourceforge.net \
    --cc=corentincj@iksaif.net \
    --cc=linux-acpi@vger.kernel.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