LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (http://www.linuxquestions.org/questions/slackware-14/)
-   -   Screen brightness will not change on netbook install (http://www.linuxquestions.org/questions/slackware-14/screen-brightness-will-not-change-on-netbook-install-4175419110/)

Miranden 07-28-2012 03:10 PM

Screen brightness will not change on netbook install
 
Hi,

I just installed Slackware 13.37 on my netbook, and the screen brightness is way too dim. Control + up/down does nothing, and neither does the brightness slider in KDE. I tried in fluxbox also, and it's the same.

Can anyone help me? I am brand new to Slackware, and I can't see well enough to learn what I am doing! And my eyes are killing me.

Thanks!

Edit: Oh, my netbook is a Samsung N145 Plus. I see some solutions for the problem under Ubuntu, but I have no idea how to extend them to Slackware.

alphageek 07-28-2012 09:54 PM

Your post is extremely sparse on usable info. When in doubt, provide too much rather than too little.

That said, a bit of digging shows that the innards of your netbook is somewhat similar to my Asus 1001P. I'll assume what worked for me might work for you:
  • add "acpi_backlight=vendor acpi_osi=Linux" to the append= line of /etc/lilo.conf
  • re-run lilo
  • reboot

If that doesn't do the trick, give us more info. Tell us exactly what you've tried & what degree of success/failure each attempt has given. Provide a snippet of 'lspci -vv' (only the section regarding the 'VGA compatible controller' is necessary in this case).

dh2k 07-29-2012 07:04 AM

Until you can verify a permanent solution how about trying 'xbacklight'


guff@guff:/usr/bin$ xbacklight --help
usage: xbacklight [options]
where options are:
-display <display> or -d <display>
-help
-set <percentage> or = <percentage>
-inc <percentage> or + <percentage>
-dec <percentage> or - <percentage>
-get
-time <fade time in milliseconds>
-steps <number of steps in fade>
guff@guff:/usr/bin$


XBACKLIGHT(1) XBACKLIGHT(1)

NAME
xbacklight - adjust backlight brightness using RandR extension

SYNOPSIS
xbacklight [-help] [-display display] [-get] [-set percent] [-inc per-
cent] [-dec percent]

DESCRIPTION
Xbacklight is used to adjust the backlight brightness where supported.
It finds all outputs on the X server supporting backlight brightness
control and changes them all in the same way.

Miranden 07-29-2012 07:49 AM

Quote:

Originally Posted by alphageek (Post 4740328)
Your post is extremely sparse on usable info. When in doubt, provide too much rather than too little.

That said, a bit of digging shows that the innards of your netbook is somewhat similar to my Asus 1001P. I'll assume what worked for me might work for you:
  • add "acpi_backlight=vendor acpi_osi=Linux" to the append= line of /etc/lilo.conf
  • re-run lilo
  • reboot

If that doesn't do the trick, give us more info. Tell us exactly what you've tried & what degree of success/failure each attempt has given. Provide a snippet of 'lspci -vv' (only the section regarding the 'VGA compatible controller' is necessary in this case).

I did tell you exactly what I tried. I tried the up and down key method that usually works, the slider in KDE, and changing desktop environments. As I said, I'm new to this, and I didn't know what else to try. Maybe this is all old hat to you, but when you can't see anything and are completely unfamiliar with an operating system, it's very difficult to go poking around with no idea. I didn't know where to start.

If you wanted to know something about my computer's "innards," all you had to do was ask and I would have thankfully provided it. There is no need for snippiness. I don't know what gave you the idea that I had tried several things with differing degrees of success and failure that I for some reason was withholding. As I also believe I said, nothing I tried made any difference. That's complete failure.

Thank you for the advice about the kernel parameter, but it did not change anything (i.e. total failure). Here is the lspci -vv snippet:

Code:

00:02.0 VGA compatible controller: Intel Corporation N10 Family Integrated Graphics Controller (prog-if 00 [VGA controller])
        Subsystem: Samsung Electronics Co Ltd Device c08f
        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 43
        Region 0: Memory at f0300000 (32-bit, non-prefetchable) [size=512K]
        Region 1: I/O ports at 18d0 [size=8]
        Region 2: Memory at d0000000 (32-bit, prefetchable) [size=256M]
        Region 3: Memory at f0000000 (32-bit, non-prefetchable) [size=1M]
        Expansion ROM at <unassigned> [disabled]
        Capabilities: [90] MSI: Enable+ Count=1/1 Maskable- 64bit-
                Address: fee0300c  Data: 4181
        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-
        Kernel driver in use: i915
        Kernel modules: i915

00:02.1 Display controller: Intel Corporation N10 Family Integrated Graphics Controller
        Subsystem: Samsung Electronics Co Ltd Device c08f
        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
        Region 0: Memory at f0380000 (32-bit, non-prefetchable) [size=512K]
        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-

Also, I read Didier Spaier's reply to another post about laptop screen brightness, and he mentioned going into /sys/class/backlight/acpi_video0 and changing the brightness, so I thought I would look in there and see if I could set it manually (or if the values were changing with respect to the up/down keys and the slider already, but just not having an effect). It turns out that I do not even have an acpi_video0 folder: the backlight directory is completely empty.

I don't know if this is important or not, but I thought I would mention it.

Thanks.

Miranden 07-29-2012 07:53 AM

Quote:

Originally Posted by dh2k (Post 4740507)
Until you can verify a permanent solution how about trying 'xbacklight'


guff@guff:/usr/bin$ xbacklight --help
usage: xbacklight [options]
where options are:
-display <display> or -d <display>
-help
-set <percentage> or = <percentage>
-inc <percentage> or + <percentage>
-dec <percentage> or - <percentage>
-get
-time <fade time in milliseconds>
-steps <number of steps in fade>
guff@guff:/usr/bin$


XBACKLIGHT(1) XBACKLIGHT(1)

NAME
xbacklight - adjust backlight brightness using RandR extension

SYNOPSIS
xbacklight [-help] [-display display] [-get] [-set percent] [-inc per-
cent] [-dec percent]

DESCRIPTION
Xbacklight is used to adjust the backlight brightness where supported.
It finds all outputs on the X server supporting backlight brightness
control and changes them all in the same way.

dh2k: I do not understand those instructions, but I will look into Xbacklight. Thanks.

Edit: Oh, I see. Trying now.

Miranden 07-29-2012 09:32 AM

I tried Xbacklight, but whenever I give it any command except "-help" (I tried xbacklight -inc 40, xbacklight -get, xbacklight -dec 40), it says

Code:

Cannot open display ""

Didier Spaier 07-29-2012 04:09 PM

The fact that /sys/class/backlight be empty can have several causes.

Maybe there is no interface in /sys for your laptop's backlight, or it lies elsewhere, or the relevant driver is not loaded.

Anyhow it seems that you need that the kernel driver "samsung-laptop" be loaded to be able to change the brightness level.

Check that it be loaded with the command:
Code:

lsmod|grep samsung|grep laptop
You should see at least one line in the output, beginning with "samsung_laptop"

If not try to load the driver manually. As root:
Code:

modprobe samsung-laptop
If you don't have any answer, then the command worked (check again with the first command), if not please post the error message here.

If the driver was not loaded at first but you could load it manually then try changing the brightness level.

In any case please report what you got.

EDIT if after the "modprobe" command the error message says something like "this driver conflict with another one", probably you need to to set at boot time the acpi_backlight kernel parameter this way: "acpi_backlight=vendor". To do that, just reboot and when you see lilo's greeting screen, hit the Tab key and type the command like this before hitting enter:
Code:

Linux acpi_backlight=vendor
After that the samsung-laptop kernel driver should be automatically loaded.

If that command was successful, to make that setting permanent you can add a line like this in the proper image section of /etc/lilo.conf (do that as root):
Code:

append="acpi_backlight=vendor"
and run:
Code:

lilo -t -v
then if all seems well:
Code:

lilo

Miranden 07-30-2012 06:23 AM

I tried

Code:

lsmod|grep samsung|grep laptop
and got no answer. Then the next line gives this:

Code:

root@darkstar:~# modprobe samsung-laptop
FATAL: Error inserting samsung_laptop (/lib/modules/2.6.37.6-smp/kernel/drivers/staging/samsung-laptop/samsung-laptop.ko): No such device
root@darkstar:~#

Thank you for your help, I really appreciate it!

Didier Spaier 07-30-2012 06:45 AM

As "modinfo samsung-laptop" says:
Code:

parm:          force:Disable the DMI check and forces the driver to be loaded (bool)

Try this as root then:
Code:

modprobe samsung-laptop force

Miranden 07-30-2012 12:28 PM

Thank you. However, for some reason when I try that, it says invalid argument:

Code:

root@darkstar:~# modprobe samsung-laptop force
FATAL: Error inserting samsung_laptop (/lib/modules/2.6.37.6-smp/kernel/drivers/staging/samsung-laptop/samsung-laptop.ko): Invalid argument
root@darkstar:~# modprobe force samsung-laptop
FATAL: Module force not found.
root@darkstar:~# force modprobe samsung-laptop
bash: force: command not found
root@darkstar:~# modprobe samsung_laptop force
FATAL: Error inserting samsung_laptop (/lib/modules/2.6.37.6-smp/kernel/drivers/staging/samsung-laptop/samsung-laptop.ko): Invalid argument
root@darkstar:~# modinfo samsung-laptop
filename:      /lib/modules/2.6.37.6-smp/kernel/drivers/staging/samsung-laptop/samsung-laptop.ko
license:        GPL
description:    Samsung Backlight driver
author:        Greg Kroah-Hartman <gregkh@suse.de>
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:pn*N130*:rn*N130*:
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:pn*N128*:rn*N128*:
depends:        rfkill
staging:        Y
vermagic:      2.6.37.6-smp SMP mod_unload 686
parm:          force:Disable the DMI check and forces the driver to be loaded (bool)
parm:          debug:Debug enabled or not (bool)
root@darkstar:~#

I can see now that those other variations I tried were bad form, but I didn't know how else to try it.

dr.s 07-30-2012 12:55 PM

try this syntax
Code:

modprobe -f samsung-laptop
or
modprobe --force samsung-laptop

Edit: never mind, i mixed up the force parm that Didier referred to with "force loading".

Didier Spaier 07-30-2012 12:57 PM

The command I gave you was probably wrong, sorry. Instead, try:
Code:

modprobe samsung-laptop force=1
This is the form that the driver's author recommends, so this should be the good one.

Miranden 07-30-2012 05:01 PM

Thank you, but unfortunately that line gave me the exact same error. :(

Didier Spaier 07-31-2012 07:57 AM

Maybe that is because the interface used by the kernel to talk to the BIOS, needed by samsung-laptop, is not present.

To check, post the output of following commands, typed as root:
Code:

dmesg|grep SABI
cat /var/log/messages|grep SABI
cat /var/log/syslog|grep SABI

If in one of the the outputs you see something like this:
Code:

kernel: This computer does not support SABI
then my assumption could be right.

But there seems to be a workaround, though, which is to send a command to the card through the PCI bus.

On some Samsung models, for instance you could type as root:
Code:

setpci -s 00:02.1 F4.B=FF
In this commmand:
"setpci -s" is the core command, the "-s" option being the method used to select the device ("man lspci" will tell you more)
"00:02.1" is the device number
"F4.B" should be the property of the device to be set (just a guess), here the brightness
"FF" being the maximum brightness value (in hexadecimal notation)

The brightness can vary from "00" to "FF" (0 to 255 in decimal notation) but be careful with the low values : if you set it to 00 the screen will be black!

It is not sure that for a N145P model the device number be 00:02.1. To check, type:
Code:

lspci|grepVGA
The code you will see at the beginning of the output is the one to use.

Miranden 07-31-2012 09:50 AM

Yay, it worked! Thank you so much for the clear instructions and explanation. Maybe you wouldn't mind answering just two more questions?

On my output of lspci, could you tell me what the difference is between "00:02.0 VGA compatible controller" and "00:02.1 Display controller?" (00.02.0 was the one I used.)

Code:

root@darkstar:~# lspci
00:00.0 Host bridge: Intel Corporation N10 Family DMI Bridge
00:02.0 VGA compatible controller: Intel Corporation N10 Family Integrated Graphics Controller
00:02.1 Display controller: Intel Corporation N10 Family Integrated Graphics Controller
00:1b.0 Audio device: Intel Corporation N10/ICH 7 Family High Definition Audio Controller (rev 02)
00:1c.0 PCI bridge: Intel Corporation N10/ICH 7 Family PCI Express Port 1 (rev 02)
00:1c.1 PCI bridge: Intel Corporation N10/ICH 7 Family PCI Express Port 2 (rev 02)
00:1c.2 PCI bridge: Intel Corporation N10/ICH 7 Family PCI Express Port 3 (rev 02)
00:1c.3 PCI bridge: Intel Corporation N10/ICH 7 Family PCI Express Port 4 (rev 02)
00:1d.0 USB Controller: Intel Corporation N10/ICH 7 Family USB UHCI Controller #1 (rev 02)
00:1d.1 USB Controller: Intel Corporation N10/ICH 7 Family USB UHCI Controller #2 (rev 02)
00:1d.2 USB Controller: Intel Corporation N10/ICH 7 Family USB UHCI Controller #3 (rev 02)
00:1d.3 USB Controller: Intel Corporation N10/ICH 7 Family USB UHCI Controller #4 (rev 02)
00:1d.7 USB Controller: Intel Corporation N10/ICH 7 Family USB2 EHCI Controller (rev 02)
00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev e2)
00:1f.0 ISA bridge: Intel Corporation NM10 Family LPC Controller (rev 02)
00:1f.2 SATA controller: Intel Corporation N10/ICH7 Family SATA AHCI Controller (rev 02)
00:1f.3 SMBus: Intel Corporation N10/ICH 7 Family SMBus Controller (rev 02)
05:00.0 Network controller: Atheros Communications Inc. AR9285 Wireless Network Adapter (PCI-Express) (rev 01)
09:00.0 Ethernet controller: Marvell Technology Group Ltd. 88E8040 PCI-E Fast Ethernet Controller
root@darkstar:~#

Also, could you please tell me what you mean about the brightness property being identified as F4.B being just a guess? Where can you find such information? I ask because it seems like a pretty good guess, and I would like to learn how to make guesses like that. :D

Thanks again for your help!


All times are GMT -5. The time now is 08:04 PM.