All of lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Renninger <trenn@suse.de>
To: Alexey Starikovskiy <aystarik@gmail.com>
Cc: Thomas Lindroth <thomas.lindroth@gmail.com>, linux-acpi@vger.kernel.org
Subject: Re: Problem: ACPI related soft lockup on Fujitsu-Siemens AMILO Si 2636
Date: Thu, 9 Oct 2008 00:19:20 +0200	[thread overview]
Message-ID: <200810090019.21303.trenn@suse.de> (raw)
In-Reply-To: <48EC9F0B.3090207@gmail.com>

On Wednesday 08 October 2008 01:52:43 pm Alexey Starikovskiy wrote:
> Thomas Renninger wrote:
> > On Wednesday 08 October 2008 12:48:36 Thomas Lindroth wrote:
...
> > Is there a general hint I could add into the ACPI Linux guideline, like:
> > Don't implement EC data/index register reads/writes in AML yourself.
> > Define a EC variable and e.g. use Store(ECXY, Local0) to read and
> > Store(Local0, ECXY) to write to specific EC bytes.
>
> Declare EC interface might be a better wording.
>
> > Did I get this right?
>
> Yes.
> My understanding is that Windows does not support 2 EC devices, so
> these people need to implement second in AML.
> So, it might be worth noting that Linux can handle any number of EC
> devices.
Can these guys do it right if we return true for:
_OSI("Multiple EC capable")

How does a second EC declaration look like?
Just a second EC OperationRegion?
Ahh, it's a whole device, it would still work. It's just the first time that 
the device is only used on Linux and not on Windows.
This would also be declared in Windows, because you cannot set conditions 
around declarations, but it would not hurt:
This is done in _OSI init section:

                    If (\_OSI ("Multiple EC capable"))
                    {
                        Store (0x01, \MIEC)
                    }

Somewhere in the Scope you have this unconditionally.
Arghh, that would certainly not work on Windows then or could at least
be a potential risk there?:
                    /* Second EC, unused on Windows */
                    Device (EC2)
                   {
                        Name (_HID, EisaId ("PNP0C09"))
                        OperationRegion (ECOR, EmbeddedControl, 0x00, 0x0100)
                        Field (ECOR, ByteAcc, NoLock, Preserve)
                        {
                            RTMP,   1,
                            ...
                        }
                   }

Where the actual value is read:

/* Linux case */
if(LEqual(MIEC, 1))
   Store(RTMP, 1)

/* Windows case */
else {
    While (RCMD (0x80, Local0))
    {
        Noop
        Noop
        Store (PMUC, Local5)
        If (And (Local5, One, Local2))
        {
            Store (PMUD, Local5)
        }
    }
}

---------------
Better ideas?
The problem is the second EC HID device which cannot be hidden on Windows...
If Windows is really too dumb for two ECs and vendors are therefore really 
doing such crap as above, we should think about alternatives..., the EC 
driver simulation looks rather unsupportable (It misses some locks, but not 
in AML namespace, but the ones in drivers/acpi/ec.c, right?).

IIRC the ACPI spec explicitly mentions a two (or multiple?) EC PC 
configuration somewhere? Anyway...

     Thomas

  reply	other threads:[~2008-10-08 22:19 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-06 11:23 Problem: ACPI related soft lockup on Fujitsu-Siemens AMILO Si 2636 Thomas Lindroth
2008-10-08  7:20 ` Thomas Lindroth
2008-10-08  7:42   ` Alexey Starikovskiy
2008-10-08  8:49     ` Alexey Starikovskiy
2008-10-08 10:48       ` Thomas Lindroth
2008-10-08 11:08         ` Thomas Renninger
2008-10-08 11:52           ` Alexey Starikovskiy
2008-10-08 22:19             ` Thomas Renninger [this message]
2008-10-09  1:50   ` Len Brown
2008-10-09  7:46     ` Thomas Lindroth

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=200810090019.21303.trenn@suse.de \
    --to=trenn@suse.de \
    --cc=aystarik@gmail.com \
    --cc=linux-acpi@vger.kernel.org \
    --cc=thomas.lindroth@gmail.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.