[Bug 98501] [i915][HSW] ACPI GPE06 storm

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Sun Oct 30 13:07:00 UTC 2016


https://bugs.freedesktop.org/show_bug.cgi?id=98501

Pierre Moreau <pierre.morrow at free.fr> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |lukas at wunner.de

--- Comment #2 from Pierre Moreau <pierre.morrow at free.fr> ---
Lukas Wunner did investigate it a bit, so here are his comments:

Okay I've just looked at an acpidump I have here (I think yours is an
MBP11,3, rather than an MBP11,2), found this in the DSDT:

    Scope (\_GPE)
    {
    ...
        Method (_L06, 0, NotSerialized)  // _Lxx: Level-Triggered GPE
        {
            If (LAnd (\_SB.PCI0.IGPU.GSSE, LNot (GSMI)))
            {
                \_SB.PCI0.IGPU.GSCI ()
            }
            Else
            {
                Store (0x00, \_SB.PCI0.IGPU.GEFC)
                Store (0x01, SCIS) /* \SCIS */
                Store (0x00, \_SB.PCI0.IGPU.GSSE)
                Store (0x00, \_SB.PCI0.IGPU.SCIE)
            }
        }

This method is executed every time GPE 0x06 fires.  It's clearly
related to the Intel GPU but I don't know why it's generating an
interrupt storm.  The above method might give a hint:  The GSSE
bit queried in the if-condition and set in the else-branch is
defined further up:

                OperationRegion (IGDP, PCI_Config, 0x40, 0xC0)
                Field (IGDP, AnyAcc, NoLock, Preserve)
                {
                ...
                    Offset (0xA8), 
                    GSSE,   1, 
                    GSSB,   14, 
                    GSES,   1, 
                ...
                }

So GSSE is a bit in the PCI configuration space at offset
0x40 + 0xa8 = 0xe8.  You can see the current value of the bit
with "lspci -vvvvxxxx -s 0000:00:02.0".  But the question is
what this bit means.  The PRMs for this Haswell GPU are here:

https://01.org/linuxgraphics/documentation/hardware-specification-prms/2013-intel-core-processor-family

Here's the PRM documenting the registers in PCI configuration space:

https://01.org/sites/default/files/documentation/intel-gfx-prm-osrc-hsw-pcie-config-registers_0.pdf

If you go to page 172 of that manual you'll find there's a 16 bit
register at offset 0xe8 which is laid out like this:

Bit 15          SMI or SCI event select (SMISCISEL)
Bit 14:1        Software scratch bits (SCISB)
Bit 0           Software SCI Event (GSSCIE)

Based on the name I would guess that GSSE in the DSDT corresponds to
"GSSCIE" and GSES corresponds to "SMISCISEL".

There's some more details in the manual but SCI means System Control
Interrupt and SMI means System Management Interrupt.  There's a hidden
firmware on these Intel machines and if the CPU gets such an interrupt
it briefly stops the operating system, switches into System Management
Mode and executes an interrupt handler in the firmware.  It then switches
back to the OS and the OS has no idea anything happened.

With Thunderbolt we know that on non-Macs, the PCI tunnels are set up
by the firmware in System Management Mode.  Apple didn't like this for
some reason and steers the controller natively from the OS using a
dedicated driver.

Apparently these Intel GPUs also have some firmware code.  Apple only
supports macOS and Windows on these machines.  With the patch to make
the Intel GPU visible, the OS identifies as macOS to the EFI firmware.
Conceivably, the SCI/SMI stuff is set up differently by the EFI firmware
for Windows versus macOS and the Linux i915 driver isn't prepared for
that.



The output of `lspci -vvvvxxxx -s 0000:00:02.0` is:

00:02.0 VGA compatible controller: Intel Corporation Crystal Well Integrated
Graphics Controller (rev 08) (prog-if 00 [VGA controller])
        Subsystem: Apple Inc. Device 012f
        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
Stepping- SERR- FastB2B- DisINTx+
        Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=fast >TAbort- <TAbort-
<MAbort- >SERR- <PERR- INTx-
        Latency: 0
        Interrupt: pin A routed to IRQ 42
        Region 0: Memory at c1400000 (64-bit, non-prefetchable) [size=4M]
        Region 2: Memory at b0000000 (64-bit, prefetchable) [size=256M]
        Region 4: I/O ports at 2000 [size=64]
        [virtual] Expansion ROM at 000c0000 [disabled] [size=128K]
        Capabilities: [90] MSI: Enable+ Count=1/1 Maskable- 64bit-
                Address: fee00018  Data: 0000
        Capabilities: [d0] Power Management version 2
                Flags: PMEClk- DSI+ D1- D2- AuxCurrent=0mA
PME(D0-,D1-,D2-,D3hot-,D3cold-)
                Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME-
        Capabilities: [a4] PCI Advanced Features
                AFCap: TP+ FLR+
                AFCtrl: FLR-
                AFStatus: TP-
        Kernel driver in use: i915
        Kernel modules: i915
00: 86 80 26 0d 07 04 90 00 08 00 00 03 00 00 00 00
10: 04 00 40 c1 00 00 00 00 0c 00 00 b0 00 00 00 00
20: 01 20 00 00 00 00 00 00 00 00 00 00 6b 10 2f 01
30: 00 00 00 00 90 00 00 00 00 00 00 00 00 01 00 00
40: 09 00 0c 01 89 21 00 42 d0 00 4c 74 00 00 00 00
50: 11 02 00 00 3d 00 00 00 00 00 00 00 01 00 a0 7b
60: 00 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00
70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
90: 05 d0 01 00 18 00 e0 fe 00 00 00 00 00 00 00 00
a0: 00 00 00 00 13 00 06 03 00 00 00 00 00 00 00 00
b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
d0: 01 a4 22 00 00 00 00 00 00 00 00 00 00 00 00 00
e0: 00 00 00 00 00 00 00 00 00 80 00 00 00 00 00 00
f0: 00 00 00 00 00 00 00 00 00 00 08 00 90 81 d1 7a

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/intel-gfx-bugs/attachments/20161030/dcba765b/attachment-0001.html>


More information about the intel-gfx-bugs mailing list