Bug 72551 - Toshiba Qosmio X75-A7298 - Can't Adjust Brightness
Summary: Toshiba Qosmio X75-A7298 - Can't Adjust Brightness
Status: CLOSED CODE_FIX
Alias: None
Product: ACPI
Classification: Unclassified
Component: Power-Video (show other bugs)
Hardware: All Linux
: P1 normal
Assignee: Aaron Lu
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-03-20 14:07 UTC by Lonnie Lee Best
Modified: 2014-10-23 08:15 UTC (History)
4 users (show)

See Also:
Kernel Version: 3.13.0-18-generic x86_64
Subsystem:
Regression: No
Bisected commit-id:


Attachments
acpidump.txt (526.42 KB, text/plain)
2014-04-23 14:56 UTC, Lonnie Lee Best
Details
Photo of Keyboard (2.76 MB, image/jpeg)
2014-04-23 15:12 UTC, Lonnie Lee Best
Details
Photo2 of Keyboard (839.69 KB, image/png)
2014-04-23 15:20 UTC, Lonnie Lee Best
Details
Proposed patch (1.26 KB, patch)
2014-06-28 01:24 UTC, Azael Avalos
Details | Diff

Description Lonnie Lee Best 2014-03-20 14:07:38 UTC
The Toshiba Qosmio X75-A7298 is running Ubuntu 14.04 blazingly fast.

The only issue I've noticed, is that the OS doesn't seem to have a proper mapping to this laptop's function keys.

Specifically, I'm unable to adjust the screen's brightness. Looking a the keyboard layout, I should be able to dim the screen by holding down the FN key and then press F2. Alternatively, to make the screen brighter you'd key FN-F3.

This is a fantasic laptop, I'd like to help (if I can) to get it fully functional for Ubuntu 14.04.

ProblemType: Bug
DistroRelease: Ubuntu 14.04
Package: linux-image-3.13.0-18-generic 3.13.0-18.38 [modified: boot/vmlinuz-3.13.0-18-generic]
ProcVersionSignature: Ubuntu 3.13.0-18.38-generic 3.13.6
Uname: Linux 3.13.0-18-generic x86_64
ApportVersion: 2.13.3-0ubuntu1
Architecture: amd64
AudioDevicesInUse:
 USER PID ACCESS COMMAND
 /dev/snd/controlC1: steve 2503 F.... pulseaudio
 /dev/snd/controlC0: steve 2503 F.... pulseaudio
CRDA:
 country TW:
  (2402 - 2472 @ 40), (3, 27)
  (5270 - 5330 @ 40), (3, 17), DFS
  (5735 - 5815 @ 40), (3, 30)
CurrentDesktop: Unity
Date: Thu Mar 20 08:43:44 2014
HibernationDevice: RESUME=UUID=c040a1e4-2261-47d3-85df-a01363cf3fca
InstallationDate: Installed on 2014-03-19 (0 days ago)
InstallationMedia: Ubuntu 14.04 LTS "Trusty Tahr" - Alpha amd64 (20140319)
MachineType: TOSHIBA Qosmio X75-A
ProcFB: 0 inteldrmfb
ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.13.0-18-generic root=UUID=82c4632b-cc2b-48f4-b42f-61690dbc80b7 ro quiet splash vt.handoff=7
RelatedPackageVersions:
 linux-restricted-modules-3.13.0-18-generic N/A
 linux-backports-modules-3.13.0-18-generic N/A
 linux-firmware 1.126
SourcePackage: linux
UpgradeStatus: No upgrade log present (probably fresh install)
dmi.bios.date: 09/18/2013
dmi.bios.vendor: Insyde Corp.
dmi.bios.version: 1.30
dmi.board.asset.tag: Type2 - Board Asset Tag
dmi.board.name: Type2 - Board Product Name1
dmi.board.vendor: Type2 - Board Vendor Name1
dmi.board.version: Type2 - Board Version
dmi.chassis.asset.tag: No Asset Tag
dmi.chassis.type: 10
dmi.chassis.vendor: OEM Chassis Manufacturer
dmi.chassis.version: OEM Chassis Version
dmi.modalias: dmi:bvnInsydeCorp.:bvr1.30:bd09/18/2013:svnTOSHIBA:pnQosmioX75-A:pvrPSPLTU-017016:rvnType2-BoardVendorName1:rnType2-BoardProductName1:rvrType2-BoardVersion:cvnOEMChassisManufacturer:ct10:cvrOEMChassisVersion:
dmi.product.name: Qosmio X75-A
dmi.product.version: PSPLTU-017016
dmi.sys.vendor: TOSHIBA

For more details about hardware and configuration go here:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1295141
Comment 1 Aaron Lu 2014-04-23 01:32:29 UTC
acpidump please:
# acpidump > acpidump.txt

Please list what backlight control interfaces do you have:
# ls /sys/class/backlight
And test if manually echo a value works:
# cd /sys/class/backlight/i915_xxx
# cat max_brightness
1234
# echo 400 > brightness
# echo 600 > brightness
...
Comment 2 Lonnie Lee Best 2014-04-23 14:56:02 UTC
@Aaron lu: I've included the information you've requested in post #5 here:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1295141

Please list what backlight control interfaces do you have:
# ls /sys/class/backlight
acpi_video0  intel_backlight

And test if manually echo a value works:
# cd /sys/class/backlight/i915_xxx
# cat max_brightness

user@Qosmio-X75-A:~$ cd /sys/class/backlight/i915_xxx
bash: cd: /sys/class/backlight/i915_xxx: No such file or directory
user@Qosmio-X75-A:~$ cd /sys
user@Qosmio-X75-A:/sys$ ls
block  class  devices   fs          kernel  power
bus    dev    firmware  hypervisor  module
user@Qosmio-X75-A:/sys$ cd class/backlight/
user@Qosmio-X75-A:/sys/class/backlight$ ls
acpi_video0  intel_backlight
user@Qosmio-X75-A:/sys/class/backlight$ cd intel_backlight
user@Qosmio-X75-A:/sys/class/backlight/intel_backlight$ ls
actual_brightness  brightness  max_brightness  subsystem  uevent
bl_power           device      power           type
user@Qosmio-X75-A:/sys/class/backlight/intel_backlight$ cat max_brightness 
5273
user@Qosmio-X75-A:/sys/class/backlight/intel_backlight$ cd ..
user@Qosmio-X75-A:/sys/class/backlight$ ls
acpi_video0  intel_backlight
user@Qosmio-X75-A:/sys/class/backlight$ cd acpi_video0
user@Qosmio-X75-A:/sys/class/backlight/acpi_video0$ ls
actual_brightness  brightness  max_brightness  subsystem  uevent
bl_power           device      power           type
user@Qosmio-X75-A:/sys/class/backlight/acpi_video0$ cat max_brightness 
100
user@Qosmio-X75-A:/sys/class/backlight/acpi_video0$ echo 400 > brightness 
bash: brightness: Permission denied
user@Qosmio-X75-A:/sys/class/backlight/acpi_video0$ sudo echo 400 > brightness 
bash: brightness: Permission denied
user@Qosmio-X75-A:/sys/class/backlight/acpi_video0$ cd ..
user@Qosmio-X75-A:/sys/class/backlight$ ls
acpi_video0  intel_backlight
user@Qosmio-X75-A:/sys/class/backlight$ cd intel_backlight
user@Qosmio-X75-A:/sys/class/backlight/intel_backlight$ ls
actual_brightness  brightness  max_brightness  subsystem  uevent
bl_power           device      power           type
user@Qosmio-X75-A:/sys/class/backlight/intel_backlight$ cat brightness 
5100
user@Qosmio-X75-A:/sys/class/backlight/intel_backlight$ sudo echo 400 > brightness 
bash: brightness: Permission denied
user@Qosmio-X75-A:/sys/class/backlight/intel_backlight$ sudo echo 600 > brightness 
bash: brightness: Permission denied
Comment 3 Lonnie Lee Best 2014-04-23 14:56:43 UTC
Created attachment 133391 [details]
acpidump.txt
Comment 4 Lonnie Lee Best 2014-04-23 15:12:55 UTC
Created attachment 133401 [details]
Photo of Keyboard
Comment 5 Aaron Lu 2014-04-23 15:16:42 UTC
Please use a root shell to do echo.
$ sudo -s
#

BTW, 400 value is an example, you should not use a value that is greater than max_brightness. Every interface's max_brightness is different.
Comment 6 Lonnie Lee Best 2014-04-23 15:20:00 UTC
Created attachment 133411 [details]
Photo2 of Keyboard
Comment 7 Lonnie Lee Best 2014-04-23 15:33:28 UTC
The echo's you suggested did indeed adjust the brightness after trying them with root shell:

user@Qosmio-X75-A:/sys/class/backlight/intel_backlight$ sudo -s
[sudo] password for user: 
root@Qosmio-X75-A:/sys/devices/pci0000:00/0000:00:02.0/drm/card0/card0-eDP-1/intel_backlight# ls
actual_brightness  brightness  max_brightness  subsystem  uevent
bl_power           device      power           type
root@Qosmio-X75-A:/sys/devices/pci0000:00/0000:00:02.0/drm/card0/card0-eDP-1/intel_backlight# cat max_brightness 
5273
root@Qosmio-X75-A:/sys/devices/pci0000:00/0000:00:02.0/drm/card0/card0-eDP-1/intel_backlight# echo 400 > brightness 
root@Qosmio-X75-A:/sys/devices/pci0000:00/0000:00:02.0/drm/card0/card0-eDP-1/intel_backlight# echo 4000 > brightness 
root@Qosmio-X75-A:/sys/devices/pci0000:00/0000:00:02.0/drm/card0/card0-eDP-1/intel_backlight# 

You'll also notice that I've attached photos of the keyboard, as I couldn't imagine how you'd implement the proper mappings without seeing the symbols shown on the keys themselves.
Comment 8 Aaron Lu 2014-05-04 05:34:54 UTC
Sorry for the delay.
Please run acpi_listen and then press the backlight related hotkeys, see if you get any output:
$ sudo -s
...
# acpi_listen
now press the hotkeys
Comment 9 Lonnie Lee Best 2014-05-05 21:13:01 UTC
Brightness would not adjust while running acpi_listen as root.

Here is the output where I initiall hit FN-f2 twice then FN-f3 twice. Neither changed brightness and FN-F3 actually caused the laptop to go into hibernation instead of making the screen brighter (as the key indicates).

root@Qosmio-X75-A:~# acpi_listen

button/battery BAT 00000080 00000000 K
button/battery BAT 00000080 00000000 K
button/sleep SBTN 00000080 00000000 K
button/sleep SBTN 00000080 00000000 K
ac_adapter ACPI0003:00 00000080 00000001
battery PNP0C0A:00 00000080 00000001
^[OR^[OR
^[OQ^[OR^[OQ^[OBR

The final outputs you see are after I came back out of hibernation. I tried to use these same keys to adjust brightness. As you can see, after hibernation pressing fn-f2 produced "^[OR" and fn-f3 produced "^[OQ". I was not sent back to habernation again however (from pressing fn-f3).
Comment 10 Blindekinder 2014-05-13 08:32:21 UTC
Hi, exactly same problem on Toshiba Tecra A50-A-130:

$ ls /sys/class/backlight
acpi_video0  intel_backlight  toshiba

This works:
/sys/class/backlight/intel_backlight$ sudo -s
[sudo] password for raphael: 
root@alphonse:/sys/devices/pci0000:00/0000:00:02.0/drm/card1/card1-eDP-1/intel_backlight# echo 700 > brightness 
root@alphonse:/sys/devices/pci0000:00/0000:00:02.0/drm/card1/card1-eDP-1/intel_backlight# echo 1000 > brightness 

interesting lines of acpi_listen:
video/brightnessup BRTUP 00000086 00000000 K
video/brightnessdown BRTDN 00000087 00000000 K

(how do I get a system config list to put here? eg. ProblemType: Bug
  DistroRelease:...)
Comment 11 Blindekinder 2014-05-13 08:51:57 UTC
acpi_listen give same lines after sleep, but brightness turns to initial value
Comment 12 Aaron Lu 2014-05-21 01:51:23 UTC
Hi Lonnie,
In case any vendor driver did something fancy, please check if any module starts with toshiba is loaded. If so, please blacklist them and try acpi_listen again. The problem with your laptop is the hotkey doesn't work while we already have a working backlight control interface, so we need to find out how to make hotkey work.
Comment 13 Aaron Lu 2014-05-21 01:53:44 UTC
(In reply to Blindekinder from comment #10)
> Hi, exactly same problem on Toshiba Tecra A50-A-130:
> 
> $ ls /sys/class/backlight
> acpi_video0  intel_backlight  toshiba
> 
> This works:
> /sys/class/backlight/intel_backlight$ sudo -s
> [sudo] password for raphael: 
> root@alphonse:/sys/devices/pci0000:00/0000:00:02.0/drm/card1/card1-eDP-1/
> intel_backlight# echo 700 > brightness 
> root@alphonse:/sys/devices/pci0000:00/0000:00:02.0/drm/card1/card1-eDP-1/
> intel_backlight# echo 1000 > brightness 
> 
> interesting lines of acpi_listen:
> video/brightnessup BRTUP 00000086 00000000 K
> video/brightnessdown BRTDN 00000087 00000000 K
 
So both the control interface and the hotkey works for you :-)
What's the problem? Oh, I see, maybe it's due to the X driver doesn't pick intel_backlight. Can you please add video.use_native_backlight=1 to the kernel cmdline and test again? Thanks.
Comment 14 Blindekinder 2014-05-21 09:04:24 UTC
tried video.use_native_backlight=1 in boot cmdline, and it works: I can know set backlight in seven step.
Comment 15 Azael Avalos 2014-05-21 22:13:16 UTC
Hi

Searching the web for Toshiba DSDTs I came accross this post.

Newer Toshiba models (like yours) now come with the Fn keys already "enabled",
and by that I mean that you don't need to press the Fn key to access the special functions, you press the Fn key to access F{1,2,3,4,5,6,7,8,9,10,11,12}.

Try pressing just the F2-F3 key and see if brightness changes, otherwise the driver won't fire the notification to the input layer.

Hope this helps.

Cheers
Comment 16 Blindekinder 2014-05-22 12:59:01 UTC
No, F_ doesn't change brightness. Actually it's F6-7 on mine.
Comment 17 Aaron Lu 2014-05-23 01:56:28 UTC
Blinde,

Since your hotkey just works, I think Azael's hint is for Lonnie. The only problem with your model is acpi_video interface gets in the way and we will need to make it disappear(so essentially your problem is a different one with the original reporter).
Comment 18 Azael Avalos 2014-05-23 04:31:09 UTC
Aaron, Lonnie:

Please take a look at this bug <a href="show_bug.cgi?id=69761">69761</a>,
it seems Toshiba decided to change the keyboard layout without doing a proper key remapping, so pressing F2-F3 is actually triggering BATTERY and SLEEP, that's why you're not getting any changes at all, try pressing F6-F7 and see if brightness changes.

Seems that more machines need to be added to that DMI matching.
Comment 19 Aaron Lu 2014-05-23 05:13:09 UTC
Yes, that looks like to be the case for Lonnie, thanks for the info Azael.
Comment 20 Blindekinder 2014-05-24 09:19:00 UTC
Aaron Lu,
ok, do I have to fill a new bug report?
Comment 21 Aaron Lu 2014-05-26 01:24:13 UTC
(In reply to Blindekinder from comment #20)
> Aaron Lu,
> ok, do I have to fill a new bug report?

Yes please. Don't forget to attach the acpidump there, thanks.
Comment 22 Lonnie Lee Best 2014-05-26 01:49:17 UTC
This is actually computer I set up for a business owner. I will have access to it again later this week an address unconfirmed suggestions.
Comment 23 Blindekinder 2014-05-27 13:06:44 UTC
(done thank you:
https://bugzilla.kernel.org/show_bug.cgi?id=76971

Please, how can I get this for my system?:

>ProblemType: Bug
>DistroRelease: Ubuntu 14.04
>Package: linux-image-3.13.0-18-generic 3.13.0-18.38 [modified:
>boot/vmlinuz-3.13.0-18-generic]
>ProcVersionSignature: Ubuntu 3.13.0-18.38-generic 3.13.6
>Uname: Linux 3.13.0-18-generic x86_64
>ApportVersion: 2.13.3-0ubuntu1
>...
Comment 24 Aaron Lu 2014-06-11 06:21:13 UTC
Any update Lonnie? Did you try Azael's suggestion at comment #18?
Comment 25 Lonnie Lee Best 2014-06-18 15:24:57 UTC
@Azael Avalos

It is true that the function keys are active without having to hit the FN keys (I did not know this).

However, they are still improperly mapped. Hitting F2 and F3 without the FN key produces the same undesired results as FN+F2 AND FN+F3 does.
Comment 26 Lonnie Lee Best 2014-06-18 15:37:54 UTC
Again, the keyboard layout can be seen here:
https://bugzilla.kernel.org/attachment.cgi?id=133401

Some of the function keys work fine. For example: F9, F10, and F11 properly adjust volume (reduce, increase, mute) and hitting the FN button is not required to do this. As a matter of fact, they do not work if you do hold the FN key.

However, F2 and FN+F2 do not dim the screen as the button-label indicates. Same goes with F3 AND FN-F3 (in regards to brightening). 

No function key combination (with or without hoding the FN key) adjusts brightness.
Comment 27 Lonnie Lee Best 2014-06-18 15:48:25 UTC
@Azael Avalos - I did also try your suggestion of F5 and f6 (with and without holding the FN key). I thought I should explicitly mention this, though my last message covers this fact broadly.
Comment 28 Lonnie Lee Best 2014-06-18 15:49:47 UTC
Meant to say F6-F7. I've really tried all combinations.
Comment 29 Azael Avalos 2014-06-18 16:03:49 UTC
Then your model should be added to the DMI matching list, the recently released kernel 3.16-rc1 now comes with the new keymap (commit fe808bfb59d693e07ee23c99542cd64e1f41b8c9).

A simple patch to add your model will do, as this bug is similar to bug 69761 and  we can probably get this in rc2.
Comment 30 Azael Avalos 2014-06-28 01:23:44 UTC
@Lonnie

Try the following patch against 3.16 and check if your issue still persist,
in case you don't want to download the whole release, just get toshiba_acpi.c from upstream and a makefile from here http://pastebin.com/Jv0YWma3
Comment 31 Azael Avalos 2014-06-28 01:24:46 UTC
Created attachment 141191 [details]
Proposed patch
Comment 32 Aaron Lu 2014-07-02 08:24:54 UTC
Lonnie,

Can you please try the patch in #comment 31? Thanks.
Comment 33 Lonnie Lee Best 2014-07-02 13:52:37 UTC
This is actually a computer I set up for a business owner. So, I won't have access to it again until next week. At that time, I will surely test your proposed patch. Thank you.
Comment 34 Aaron Lu 2014-07-22 07:00:46 UTC
Any update?
Comment 35 Aaron Lu 2014-10-23 08:15:19 UTC
commit e6efad7f292d99190b66d32f1ddcc764db0fa6f4
Author: Azael Avalos <coproscefalo@gmail.com>
Date:   Mon Aug 4 09:21:02 2014 -0600

    toshiba_acpi: Add Qosmio X75-A to the alt keymap dmi list

Note You need to log in before you can comment on or make changes to this bug.