Skip to contentSkip to conversation

acpi-als on Dell XPS 13 9343

DISCUSSION Marek Vasut 3 participants 4 messages Dec 30, 2015 – May 25, 2016 4 messages not in the archive IIO

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

A message that is not in the archive (sent off-list or not yet received): [email protected]

A message that is not in the archive (sent off-list or not yet received): [email protected]

#3 lore raw
Quoted 32 lines · Mykola Dvornik

Hi Marek,

Thanks for you prompt reply.

The DSDT describes _ALI method:

	...
Device (ALSD)
    {
        Name (_HID, "ACPI0008" /* Ambient Light Sensor Device */)  //
_HID: Hardware ID
        Method (_STA, 0, NotSerialized)  // _STA: Status
        {
            If ((ALSE == 0x02))
            {
                Return (0x0B)
            }

            Return (Zero)
        }

        Method (_ALI, 0, NotSerialized)  // _ALI: Ambient Light
Illuminance
        {
            Return (((LHIH << 0x08) | LLOW))
        }
	...

acpidump also shows _ALI method.

But '/sys/bus/acpi/devices/ACPI0008:00' only contains:

Quoted 7 lines

hid
modalias
path
power
status
subsystem
uevent

OK, I don't have a machine with the ALS in it here, so I am CCing the list and a few more interested parties.

Quoted 32 lines

Regards,

Mykola

Quoted 27 lines · Marek Vasut
Quoted 12 lines · Mykola Dvornik

Hi guys,

I am writing to you because the acpi-als kernel module is not

detecting

ALS on Dell XPS 13 9343.

The (decompiled) DSDT of the laptop is attached to this email.

The ACPI0008 is present in the system with 'cat modalias':

Quoted 7 lines

acpi:ACPI0008:

but exposes no iio-related stuff.

I am running Fedora 23 with kernel-4.2.8.

Would you be so kind to look into this issue?

Do you have the _ALI value in the ACPI0008 ? That's what's used to read out
the illuminance and without it, the ALS driver won't report anything.

Best regards,
Marek Vasut

#4 lore raw

2015-12-30 10:50 GMT+01:00 Marek Vasut <[email protected]>:

Quoted 33 lines · Mykola Dvornik
Quoted 32 lines

Hi Marek,

Thanks for you prompt reply.

The DSDT describes _ALI method:

      ...
Device (ALSD)
    {
        Name (_HID, "ACPI0008" /* Ambient Light Sensor Device */)  //
_HID: Hardware ID
        Method (_STA, 0, NotSerialized)  // _STA: Status
        {
            If ((ALSE == 0x02))
            {
                Return (0x0B)
            }

            Return (Zero)
        }

        Method (_ALI, 0, NotSerialized)  // _ALI: Ambient Light
Illuminance
        {
            Return (((LHIH << 0x08) | LLOW))
        }
      ...

acpidump also shows _ALI method.

But '/sys/bus/acpi/devices/ACPI0008:00' only contains:

Quoted 7 lines
Quoted 7 lines

hid
modalias
path
power
status
subsystem
uevent

Hi,

looking at this portion of the ACPI table I can see that the status of the ambient light sensor is controlled by a variable (ALSE, which I guess stands for ALS Enabled).

If the output of /sys/bus/acpi/devices/ACPI0008:00/status is 0, then the light sensor is disabled and must be somehow enabled. When the sensor is enabled, the output of status should be 11. I don't know what controls the value of ALSE, I think it's something specific of your laptop.

Regards,
Gabriele

Quoted 35 lines

OK, I don't have a machine with the ALS in it here, so I am CCing the list and a few more interested parties.

Quoted 32 lines

Regards,

Mykola

Quoted 27 lines · Marek Vasut
Quoted 12 lines · Mykola Dvornik

Hi guys,

I am writing to you because the acpi-als kernel module is not

detecting

ALS on Dell XPS 13 9343.

The (decompiled) DSDT of the laptop is attached to this email.

The ACPI0008 is present in the system with 'cat modalias':

Quoted 7 lines

acpi:ACPI0008:

but exposes no iio-related stuff.

I am running Fedora 23 with kernel-4.2.8.

Would you be so kind to look into this issue?

Do you have the _ALI value in the ACPI0008 ? That's what's used to read out
the illuminance and without it, the ALS driver won't report anything.

Best regards,
Marek Vasut

A message that is not in the archive (sent off-list or not yet received): [email protected]

#6 lore raw

2015-12-30 12:01 GMT+01:00 Mykola Dvornik <[email protected]>:

Quoted 6 lines

Hi Gabriele,

Thanks for the tip.

The reported status is 0, so the device is disabled and there is no way to override it in BIOS.

Not really related to acpi-als, but you could take a look at libsmbios. I know it can enable the ambient light sensor of some Dell laptops.

Gabriele

Quoted 7 lines

Anyway thanks guys for all your help.

Happy New Year.

Cheers,

Mykola

#7 lore raw
In reply to Gabriele Mazzotta
Quoted 48 lines · On Wednesday 30 December 2015 11:28:32 Gabriele Mazzotta wrote:

2015-12-30 10:50 GMT+01:00 Marek Vasut <[email protected]>:

Quoted 33 lines · Mykola Dvornik
Quoted 32 lines

Hi Marek,

Thanks for you prompt reply.

The DSDT describes _ALI method:

      ...
Device (ALSD)
    {
        Name (_HID, "ACPI0008" /* Ambient Light Sensor Device */)  //
_HID: Hardware ID
        Method (_STA, 0, NotSerialized)  // _STA: Status
        {
            If ((ALSE == 0x02))
            {
                Return (0x0B)
            }

            Return (Zero)
        }

        Method (_ALI, 0, NotSerialized)  // _ALI: Ambient Light
Illuminance
        {
            Return (((LHIH << 0x08) | LLOW))
        }
      ...

acpidump also shows _ALI method.

But '/sys/bus/acpi/devices/ACPI0008:00' only contains:

Quoted 7 lines
Quoted 7 lines

hid
modalias
path
power
status
subsystem
uevent

Hi,

looking at this portion of the ACPI table I can see that the status of the ambient light sensor is controlled by a variable (ALSE, which I guess stands for ALS Enabled).

Quoted 8 lines

If the output of /sys/bus/acpi/devices/ACPI0008:00/status is 0, then the light sensor is disabled and must be somehow enabled. When the sensor is enabled, the output of status should be 11. I don't know what controls the value of ALSE, I think it's something specific of your laptop.

Regards,
Gabriele

Hi Mykola! Please look at dell-wmi driver:
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/drivers/platform/x86/dell-wmi.c?h=v4.6#n634

There is specific Dell SMBIOS call which tell Dell BIOS/firmware to start generating WMI events when some buttons are pressed.

In above link is also documentation for that SMBIOS call and there is also parameter "ALS Driver". So maybe this one can enable your currently disabled ambient light sensor...

Can you play with it?

Quoted 36 lines
Quoted 35 lines

OK, I don't have a machine with the ALS in it here, so I am CCing the list and a few more interested parties.

Quoted 32 lines

Regards,

Mykola

Quoted 27 lines · Marek Vasut
Quoted 12 lines · Mykola Dvornik

Hi guys,

I am writing to you because the acpi-als kernel module is not

detecting

ALS on Dell XPS 13 9343.

The (decompiled) DSDT of the laptop is attached to this email.

The ACPI0008 is present in the system with 'cat modalias':

Quoted 7 lines

acpi:ACPI0008:

but exposes no iio-related stuff.

I am running Fedora 23 with kernel-4.2.8.

Would you be so kind to look into this issue?

Do you have the _ALI value in the ACPI0008 ? That's what's used to read out
the illuminance and without it, the ALS driver won't report anything.

Best regards,
Marek Vasut

Signature · 2 lines
Pali Rohár
[email protected]