SUSE 12.2, Samsung NP-R700 back-light problem

Installed SUSE 12.2; the default open source graphics drivers did not work, hence I installed the NVIDIA driver; the NVIDIA driver detected the hardware and now everything is working apart from the back-light button control from a normal/default boot. A typically normal/default boot scenario starts with the BIOS setting the back-light level high if laptop is mains powered; during the boot the back-light dims to a very low level. As root issuing a command of the following form has no affect on the back-light brightness:

echo new-backlight-level > /sys/class/backlight/acpi_video0/brightness

However, when I use the recovery (fail-safe) boot the back-light buttons do work. The only significant differences between a normal/default boot and recovery boot with respect to modules loaded is as follows; normal/default boot:


nvidia              11265951  43
processor              44907  3 acpi_cpufreq
rfkill                 26009  3 samsung_laptop,cfg80211

recovery (fail-safe) boot:


nvidia              11265951  0
processor              44907  1 acpi_cpufreq
rfkill                 26009  3 cfg80211,samsung_laptop

The above was captured from an “lsmod | sort”, since the kernel module load order is different between the two boot modes; I do not know if module load order is a significant factor. Is the VGA fail-safe mode employed in the recovery boot implemented through PC BIOS access?

The output kernel message associated with the Samsung back-light are independent of the boot type and are as follows:


   12.843555] samsung_laptop: detected SABI interface: SwSmi@
   12.843559] samsung_laptop: Backlight controlled by ACPI video driver

Any ideas on how to progress this would be welcome?

I have been attempting to implement the solution outlined here.

The solution essentially involves modifying the samsung-laptop module to include an a DMI table entry specific to my laptop. The steps performed to date are follows:

  1. Installed the kernel-source packages.
  2. Copy kernel sources to home directory.
  3. Determine laptop ID with following command:
dmidecode -s system-product-name

this gives

SR700
  1. Updated the samsung-laptop.c module by adding the following entry to samsung_dmi_table]:
    {
     .callback = samsung_dmi_matched,
     .ident = "SR700",
     .matches = {
        DMI_MATCH(DMI_SYS_VENDOR, "SAMSUNG ELECTRONICS CO., LTD."),
        DMI_MATCH(DMI_PRODUCT_NAME, "SR700"),
        DMI_MATCH(DMI_BOARD_NAME, "SR700"),
        },
     .driver_data = &samsung_broken_acpi_video,
    },
  1. Re-built and installed the updated module with the following commands:
make cloneconfig
make modules
sudo cp linux/drivers/platform/x86/samsung-laptop.ko /lib/modules/3.4.6-2.10-desktop/kernel/drivers/platform/x86/samsung-laptop.ko
depmod -a
  1. Added following option to grub boot:
acpi_backlight=vendor
  1. Re-booted and found that the re-built samsung-laptop.ko module is not loading; I get the following:
dmesg | grep samsung
   12.812224] samsung_laptop: no symbol version for module_layout
   12.812664] samsung_laptop: no symbol version for module_layout

I have not found any coherent posts regarding the error messages.

Other possibly useful information

uname -a
Linux grendel.mere 3.4.6-2.10-desktop #1 SMP PREEMPT Thu Jul 26 09:36:26 UTC 2012 (641c197) x86_64 x86_64 x86_64 GNU/Linux

The following corresponds to the rebuilt module:

modinfo samsung-laptop.ko
filename:       samsung-laptop.ko
license:        GPL
description:    Samsung Backlight driver
author:         Greg Kroah-Hartman <gregkh@suse.de>
srcversion:     169773B4D51D43F416DA1D5
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:pn*SR700*:rn*SR700*:
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:pn*NF110/NF210/NF310*:rn*NF110/NF210/NF310*:
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:pn*N150/N210/N220*:rn*N150/N210/N220*:
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:pn*N145P/N250P/N260P*:rn*N145P/N250P/N260P*:
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:pn*N150P*:rn*N150P*:
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:ct*14*:
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:ct*10*:
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:ct*9*:
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:ct*8*:
depends:        video,rfkill
intree:         Y
vermagic:       3.4.6-2.10-desktop SMP preempt mod_unload modversions 
parm:           force:Disable the DMI check and forces the driver to be loaded (bool)
parm:           debug:Debug enabled or not (bool)

Where did I go wrong in re-building the samsung-laptop module? I am beginning to think that there is a malevolent forcing trying to stop me from having working back-light keys!

On 10/05/2012 10:16 PM, Addanc wrote:
> beginning to think that there is a malevolent forcing trying to stop me
> from having working back-light keys!

some Samsung-Other-software-vendor tie in perhaps ?

so, you are VERY welcome to hang here and see what help flows, but you
may get better/more/faster posts on the mail list:

start here and pick the opensuse@opensuse.org list:
http://en.opensuse.org/openSUSE:Communication_channels#Mailing_lists


dd

On 2012-10-05 22:16, Addanc wrote:

> The solution essentially involves modifying the samsung-laptop module
> to include an a DMI table entry specific to my laptop. The steps
> performed to date are follows:

Wow.

> 5) Re-built and installed the updated module with the following
> commands:
>
> Code:
> --------------------
> make cloneconfig
> make modules
> sudo cp linux/drivers/platform/x86/samsung-laptop.ko /lib/modules/3.4.6-2.10-desktop/kernel/drivers/platform/x86/samsung-laptop.ko
> depmod -a
> --------------------

I’m unsure if this is right, or you need a make modules_install call. Or the entire kernel.

If you don’t get an answer here, there is an opensuse kernel mail list you might try.


Cheers / Saludos,

Carlos E. R.
(from 12.1 x86_64 “Asparagus” at Telcontar)

Have a look at this link on a Samsung.

Use the file that you have to compile the samsung-backlight.ko file.

It refers to another Samsung laptop but the fix applies to the openSUSE distro instead of Ubuntu.

Follow Up

Open dolphin and navigate to /usr/src/linux-3.4.6-2.10/drivers/platform/x86/samsung-laptop.c

Finally got the re-built module loaded; had to do a complete kernel build i.e. make as opposed to make modules. Module info now gives:

filename:       /lib/modules/3.4.6-2.10-desktop/kernel/drivers/platform/x86/samsung-laptop.ko
license:        GPL
description:    Samsung Backlight driver
author:         Greg Kroah-Hartman <gregkh@suse.de>
srcversion:     169773B4D51D43F416DA1D5
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:pn***SR700***:rn***SR700***:
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:pn*NF110/NF210/NF310*:rn*NF110/NF210/NF310*:
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:pn*N150/N210/N220*:rn*N150/N210/N220*:
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:pn*N145P/N250P/N260P*:rn*N145P/N250P/N260P*:
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:pn*N150P*:rn*N150P*:
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:ct*14*:
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:ct*10*:
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:ct*9*:
alias:          dmi*:svn*SAMSUNGELECTRONICSCO.,LTD.*:ct*8*:
depends:        video,rfkill
intree:         Y
vermagic:       3.4.6-2.10-desktop SMP preempt mod_unload modversions 
parm:           force:Disable the DMI check and forces the driver to be loaded (bool)
parm:           debug:Debug enabled or not (bool)

Loaded the module with debug enabled and I get the following when the brightness buttons are activated:

Oct  7 19:25:24 grendel kernel:  3624.263707] samsung_laptop: SABI command:0x0011 data:{0x00000008, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:33 grendel kernel:  3624.266201] samsung_laptop: SABI command:0x002e data:{0x00000001, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:33 grendel kernel:  3633.301411] samsung_laptop: SABI command:0x0011 data:{0x00000007, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:33 grendel kernel:  3633.304384] samsung_laptop: SABI command:0x002e data:{0x00000001, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:33 grendel kernel:  3633.381746] samsung_laptop: SABI command:0x0011 data:{0x00000006, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:33 grendel kernel:  3633.384703] samsung_laptop: SABI command:0x002e data:{0x00000001, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:33 grendel kernel:  3633.602189] samsung_laptop: SABI command:0x0011 data:{0x00000005, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:33 grendel kernel:  3633.605211] samsung_laptop: SABI command:0x002e data:{0x00000001, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:33 grendel kernel:  3633.679471] samsung_laptop: SABI command:0x0011 data:{0x00000004, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:33 grendel kernel:  3633.683118] samsung_laptop: SABI command:0x002e data:{0x00000001, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:33 grendel kernel:  3633.834463] samsung_laptop: SABI command:0x0011 data:{0x00000003, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:33 grendel kernel:  3633.838081] samsung_laptop: SABI command:0x002e data:{0x00000001, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:33 grendel kernel:  3634.049365] samsung_laptop: SABI command:0x0011 data:{0x00000002, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:34 grendel kernel:  3634.055985] samsung_laptop: SABI command:0x002e data:{0x00000001, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:34 grendel kernel:  3634.140453] samsung_laptop: SABI command:0x0011 data:{0x00000001, 0x00000000, 0x0000, 0x00}

Oct  7 19:25:36 grendel kernel:  3635.458296] samsung_laptop: SABI command:0x002e data:{0x00000001, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:36 grendel kernel:  3636.219426] samsung_laptop: SABI command:0x0011 data:{0x00000001, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:36 grendel kernel:  3636.221912] samsung_laptop: SABI command:0x002e data:{0x00000001, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:36 grendel kernel:  3636.296878] samsung_laptop: SABI command:0x0011 data:{0x00000002, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:36 grendel kernel:  3636.300336] samsung_laptop: SABI command:0x002e data:{0x00000001, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:36 grendel kernel:  3636.533233] samsung_laptop: SABI command:0x0011 data:{0x00000003, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:36 grendel kernel:  3636.536243] samsung_laptop: SABI command:0x002e data:{0x00000001, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:36 grendel kernel:  3636.610405] samsung_laptop: SABI command:0x0011 data:{0x00000004, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:36 grendel kernel:  3636.614503] samsung_laptop: SABI command:0x002e data:{0x00000001, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:36 grendel kernel:  3636.734487] samsung_laptop: SABI command:0x0011 data:{0x00000005, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:36 grendel kernel:  3636.737482] samsung_laptop: SABI command:0x002e data:{0x00000001, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:36 grendel kernel:  3636.838477] samsung_laptop: SABI command:0x0011 data:{0x00000006, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:36 grendel kernel:  3636.840971] samsung_laptop: SABI command:0x002e data:{0x00000001, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:36 grendel kernel:  3636.946457] samsung_laptop: SABI command:0x0011 data:{0x00000007, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:36 grendel kernel:  3636.949689] samsung_laptop: SABI command:0x002e data:{0x00000001, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:36 grendel kernel:  3637.053696] samsung_laptop: SABI command:0x0011 data:{0x00000008, 0x00000000, 0x0000, 0x00}
Oct  7 19:25:37 grendel kernel:  3637.056430] samsung_laptop: SABI command:0x002e data:{0x00000001, 0x00000000, 0x0000, 0x00}

Looking at the samsung-laptop module source, command 0x2e is set_backlight, command 0x11 is set brightness; the commands appear to do absolutely nothing with respect to brightness on my laptop.

Since you have an nVidia card you must add the following line to /etc/X11/xorg.conf.d/50-device.conf

Option “RegistryDwords” EnableBrightnessControl=1

Resave the file changes and restart your laptop.