Re: [PATCH 0/3] ACPI: video/apple-gmux: Improve apple-gmux backlight detection

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

On 1/23/23 13:09, Lukas Wunner wrote:
> On Mon, Jan 23, 2023 at 12:37:47PM +0100, Hans de Goede wrote:
>> Some apple laptop models have an ACPI device with a HID of APP000B
>> and that device has an IO resource (so it does not describe the new
>> unsupported MMIO based gmux type), but there actually is no gmux
>> in the laptop at all.
>>
>> This patch-series improves the drivers/acpi/video_detect.c so that
>> it no longer tries to use the non present gmux in this case.
>>
>> Note I'm still waiting for testing feedback from the reporter of
>> this problem. But from the logs the problem is clear
>> (the logs show: "apple_gmux: gmux device not present")
> 
> Please provide a link to the original report.  I would also like to
> know the exact MacBook model used and I would like to see full dmesg
> output as well as an acpidump.

I only have a report by private email. This does include full dmesg
output and an acpidump. I will forward this to you in a private
email.

The reporter describes their model as a macbookpro8,1.

> What you're saying here is that there's a fake APP000B device present
> in DSDT

Yes that is exactly what I'm saying.

> and I have a hard time believng that.

Yes that seems to be exactly what is happening. If you look at
the drivers/platform/x86/apple-gmux.c code that is pretty much
the only scenario which leads to the:

apple_gmux: gmux device not present

message getting logged; and it seems to me that the reason that
check is there likely is exactly because of such machines
actually existing.

And /sys/class/backlight contains only intel_backlight
suggesting that this is not a hybrid gfx machine. Which also
matches with the specs which I can find for the  macbookpro8,1.

Yet there is an APP000B device present in the DSDT, here is
the relevant bit of the DSDT:

                Device (GMUX)
                {
                    Name (_HID, EisaId ("APP000B"))  // _HID: Hardware ID
                    Name (_CID, "gmux")  // _CID: Compatible ID
                    Name (_STA, 0x0B)  // _STA: Status
                    Name (_CRS, ResourceTemplate ()  // _CRS: Current Resource Settings
                    {
                        IO (Decode16,
                            0x0700,             // Range Minimum
                            0x07FF,             // Range Maximum
                            0x01,               // Alignment
                            0xFF,               // Length
                            )
                    })
                    Name (_PRW, Package (0x02)  // _PRW: Power Resources for Wake
                    {
                        0x16, 
                        0x03
                    })
                    Scope (\_GPE)
                    {
                        Method (_L16, 0, NotSerialized)  // _Lxx: Level-Triggered GPE, xx=0x00-0xFF
                        {
                            Notify (\_SB.PCI0.LPCB.GMUX, 0x80) // Status Change
                        }
                    }

                    Name (GMGP, 0x16)
                    Method (GMSP, 1, NotSerialized)
                    {
                        If ((Arg0 <= 0x01))
                        {
                            GP06 |= Arg0
                        }
                    }

                    Method (GMLV, 0, NotSerialized)
                    {
                        Return (GP06) /* \GP06 */
                    }
                }
            }

Regards,

Hans




[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]
  Powered by Linux