Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755763Ab1EERDO (ORCPT ); Thu, 5 May 2011 13:03:14 -0400 Received: from mail-ew0-f46.google.com ([209.85.215.46]:60391 "EHLO mail-ew0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755463Ab1EERC7 convert rfc822-to-8bit (ORCPT ); Thu, 5 May 2011 13:02:59 -0400 DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:from:date:message-id:subject:to:content-type :content-transfer-encoding; b=rj/Og4hhlUuAv6Mqg7NOUDyilKm29Us+43EW8t48581l2UjPf6ib8nj024DR4cQL85 rCd7cSogFeV9iCGWiY6h0OA+oKg/7cnSmRzTK9x2bHqgCtRpL59qvL+/un7Vydhs23q/ 3PrA1YVMMLmwc7r3sBA8zCbv3Pt9SUf1oM+xU= MIME-Version: 1.0 From: Tommaso Massimi Date: Thu, 5 May 2011 19:02:37 +0200 Message-ID: Subject: Samsung Backlight driver To: Greg Kroah-Hartman , linux-kernel@vger.kernel.org Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8BIT Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 5125 Lines: 138 please apply ---------- Forwarded message ---------- From: Tommaso Massimi Date: Sat, Apr 23, 2011 at 10:36 PM Subject: Fwd: [PATCH] Platform: add Samsung Laptop platform driver To: linux-kernel@vger.kernel.org, Greg Kroah-Hartman Hi, my samsung laptop would be very happy if you add these lines to the file drivers/platform/x86/samsung-laptop.c Thanks Tommaso Massimi @@ -666,6 +666,15 @@                },                .callback = dmi_check_cb,        }, +               { +               .ident = "X520", +               .matches = { +                       DMI_MATCH(DMI_SYS_VENDOR, "SAMSUNG ELECTRONICS CO., LTD."), +                       DMI_MATCH(DMI_PRODUCT_NAME, "X520"), +                       DMI_MATCH(DMI_BOARD_NAME, "X520"), +               }, +               .callback = dmi_check_cb, +       },        { },  };  MODULE_DEVICE_TABLE(dmi, samsung_dmi_table); ---------- Forwarded message ---------- From: Tommaso Massimi Date: Fri, Mar 11, 2011 at 6:57 PM Subject: Re: [PATCH] Platform: add Samsung Laptop platform driver To: linux-kernel@vger.kernel.org On 03/10/2011 08:09 PM, Greg KH wrote: >On Thu, Mar 10, 2011 at 07:28:00PM +0200, Nikolai Kondrashov wrote: > > On 03/10/2011 07:19 PM, Greg KH wrote: > > >Can you provide me the output of: > > > grep . /sys/class/dmi/id/* > > >so I can try to add support for this machine to the driver? > > Sure, here it is. > > Great, here's a new version of the samsung-laptop.c file, can you > replace it whereever you were building the previous one, rebuild it and > test it for this machine to see if it works? Hi, here the output you required from my laptop: tom@localhost tom_samsung]$ grep . /sys/class/dmi/id/* /sys/class/dmi/id/bios_date:09/21/2009 /sys/class/dmi/id/bios_vendor:Phoenix Technologies Ltd. /sys/class/dmi/id/bios_version:04IA.M005.20090921.KSY /sys/class/dmi/id/board_name:X420/X520 grep: /sys/class/dmi/id/board_serial: Permission denied /sys/class/dmi/id/board_vendor:SAMSUNG ELECTRONICS CO., LTD. /sys/class/dmi/id/board_version:Not Applicable /sys/class/dmi/id/chassis_asset_tag:No Asset Tag grep: /sys/class/dmi/id/chassis_serial: Permission denied /sys/class/dmi/id/chassis_type:10 /sys/class/dmi/id/chassis_vendor:SAMSUNG ELECTRONICS CO., LTD. /sys/class/dmi/id/chassis_version:N/A /sys/class/dmi/id/modalias:dmi:bvnPhoenixTechnologiesLtd.:bvr04IA.M005.20090921.KSY:bd09/21/2009:svnSAMSUNGELECTRONICSCO.,LTD.:pnX420/X520:pvrNotApplicable:rvnSAMSUNGELECTRONICSCO.,LTD.:rnX420/X520:rvrNotApplicable:cvnSAMSUNGELECTRONICSCO.,LTD.:ct10:cvrN/A: /sys/class/dmi/id/product_name:X420/X520 grep: /sys/class/dmi/id/product_serial: Permission denied grep: /sys/class/dmi/id/product_uuid: Permission denied /sys/class/dmi/id/product_version:Not Applicable /sys/class/dmi/id/sys_vendor:SAMSUNG ELECTRONICS CO., LTD. /sys/class/dmi/id/uevent:MODALIAS=dmi:bvnPhoenixTechnologiesLtd.:bvr04IA.M005.20090921.KSY:bd09/21/2009:svnSAMSUNGELECTRONICSCO.,LTD.:pnX420/X520:pvrNotApplicable:rvnSAMSUNGELECTRONICSCO.,LTD.:rnX420/X520:rvrNotApplicable:cvnSAMSUNGELECTRONICSCO.,LTD.:ct10:cvrN/A: I have added these lines to your source file 668a669,677 >               { >               .ident = "X520", >               .matches = { >                       DMI_MATCH(DMI_SYS_VENDOR, "SAMSUNG ELECTRONICS CO., LTD."), >                       DMI_MATCH(DMI_PRODUCT_NAME, "X520"), >                       DMI_MATCH(DMI_BOARD_NAME, "X520"), >               }, >               .callback = dmi_check_cb, >       }, When I load the module with the option debug=1, it turns on and off my backligth and my wireless card, so I think it is working fine. Here what dmesg says: samsung_laptop: module is from the staging directory, the quality is unknown, you have been warned. samsung_laptop: found laptop model 'X520' This computer supports SABI==f48b4 SABI header:  SMI Port Number = 0x00b2  SMI Interface Function = 0xc0  SMI enable memory buffer = 0xc1  SMI restore memory buffer = 0xc2  SABI data offset = 0x0f00  SABI data segment = 0xdf01 ifaceP = 0x000dff10 sabi_iface = ffff8800000dff10 backlight = 0x01 backlight should be off backlight = 0x00 backlight should be on backlight = 0x01 wireless led = 0x01 wireless led should be off wireless led = 0x00 wireless led should be on wireless led = 0x01 brightness = 0x08 atkbd serio0: Unknown key pressed (translated set 2, code 0x89 on isa0060/serio0). atkbd serio0: Use 'setkeycodes e009 ' to make it known. Now I think I need only to use the setkeycodes command to have these new commands under my fingers :) Thanks for that!! Tom PS: I'm not subscribed to the list, so please CC me if you need some other info -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/