]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
Merge branch 'drivers-platform' into release
authorLen Brown <len.brown@intel.com>
Fri, 9 Jan 2009 09:01:26 +0000 (04:01 -0500)
committerLen Brown <len.brown@intel.com>
Fri, 9 Jan 2009 09:56:56 +0000 (04:56 -0500)
Conflicts:
drivers/misc/Kconfig

Signed-off-by: Len Brown <len.brown@intel.com>
1  2 
drivers/Makefile
drivers/acpi/Makefile
drivers/misc/Kconfig
drivers/misc/Makefile
drivers/platform/x86/Kconfig
drivers/platform/x86/fujitsu-laptop.c
drivers/platform/x86/panasonic-laptop.c
drivers/platform/x86/sony-laptop.c
drivers/platform/x86/tc1100-wmi.c
drivers/platform/x86/thinkpad_acpi.c

diff --combined drivers/Makefile
index 6326f4dbbdab443f31443f6d6462d9c958cc5acc,46d4828042c358d1448cf45c65d473c0bfe05450..c1bf41737936ab00be4a87563a0bb0638074785d
@@@ -18,9 -18,6 +18,9 @@@ obj-$(CONFIG_ARM_AMBA)                += amba
  
  obj-$(CONFIG_XEN)             += xen/
  
 +# regulators early, since some subsystems rely on them to initialize
 +obj-$(CONFIG_REGULATOR)               += regulator/
 +
  # char/ comes before serial/ etc so that the VT console is the boot-time
  # default.
  obj-y                         += char/
@@@ -60,7 -57,6 +60,7 @@@ obj-$(CONFIG_ATA_OVER_ETH)    += block/aoe
  obj-$(CONFIG_PARIDE)          += block/paride/
  obj-$(CONFIG_TC)              += tc/
  obj-$(CONFIG_UWB)             += uwb/
 +obj-$(CONFIG_USB_OTG_UTILS)   += usb/otg/
  obj-$(CONFIG_USB)             += usb/
  obj-$(CONFIG_USB_MUSB_HDRC)   += usb/musb/
  obj-$(CONFIG_PCI)             += usb/
@@@ -104,4 -100,6 +104,5 @@@ obj-$(CONFIG_PPC_PS3)              += ps3
  obj-$(CONFIG_OF)              += of/
  obj-$(CONFIG_SSB)             += ssb/
  obj-$(CONFIG_VIRTIO)          += virtio/
 -obj-$(CONFIG_REGULATOR)               += regulator/
  obj-$(CONFIG_STAGING)         += staging/
+ obj-y                         += platform/
diff --combined drivers/acpi/Makefile
index 5d23c13ac7d48efe54de227ac337ceea1d75ee4c,f64af36b780eb19b7e38fca1f80d429b4200e127..d80f4cc2e0da31c9e3679320f473122c447b4aa2
@@@ -2,8 -2,15 +2,8 @@@
  # Makefile for the Linux ACPI interpreter
  #
  
 -export ACPI_CFLAGS
 -
 -ACPI_CFLAGS   := -Os
 -
 -ifdef CONFIG_ACPI_DEBUG
 -  ACPI_CFLAGS += -DACPI_DEBUG_OUTPUT
 -endif
 -
 -EXTRA_CFLAGS  += $(ACPI_CFLAGS)
 +ccflags-y                     := -Os
 +ccflags-$(CONFIG_ACPI_DEBUG)  += -DACPI_DEBUG_OUTPUT
  
  #
  # ACPI Boot-Time Table Parsing
@@@ -15,13 -22,9 +15,13 @@@ obj-$(CONFIG_X86)           += blacklist.
  # ACPI Core Subsystem (Interpreter)
  #
  obj-y                         += osl.o utils.o reboot.o\
 -                                 dispatcher/ events/ executer/ hardware/ \
 -                                 namespace/ parser/ resources/ tables/ \
 -                                 utilities/
 +                                      acpica/
 +
 +# sleep related files
 +obj-y                         += wakeup.o
 +obj-y                         += main.o
 +obj-$(CONFIG_ACPI_SLEEP)      += proc.o
 +
  
  #
  # ACPI Bus and Device Drivers
@@@ -32,6 -35,7 +32,6 @@@ ifdef CONFIG_CPU_FRE
  processor-objs        += processor_perflib.o
  endif
  
 -obj-y                         += sleep/
  obj-y                         += bus.o glue.o
  obj-y                         += scan.o
  # Keep EC driver first. Initialization of others depend on it.
@@@ -55,9 -59,6 +55,6 @@@ obj-y                         += power.
  obj-$(CONFIG_ACPI_SYSTEM)     += system.o event.o
  obj-$(CONFIG_ACPI_DEBUG)      += debug.o
  obj-$(CONFIG_ACPI_NUMA)               += numa.o
- obj-$(CONFIG_ACPI_WMI)                += wmi.o
- obj-$(CONFIG_ACPI_ASUS)               += asus_acpi.o
- obj-$(CONFIG_ACPI_TOSHIBA)    += toshiba_acpi.o
  obj-$(CONFIG_ACPI_HOTPLUG_MEMORY)     += acpi_memhotplug.o
  obj-$(CONFIG_ACPI_PROCFS_POWER)       += cm_sbs.o
  obj-$(CONFIG_ACPI_SBS)                += sbshc.o
diff --combined drivers/misc/Kconfig
index 2da1781e85c3f7e05669af1f3b46f37b33bc7581,8574879fa63b9aa4391f9c2fe1771a410e94a5b4..419c378bd24b334d5645fa6a35ef5a3b8c158dd0
@@@ -120,7 -120,7 +120,7 @@@ config TIFM_COR
          cards are supported via 'MMC/SD Card support: TI Flash Media MMC/SD
          Interface support (MMC_TIFM_SD)'.
  
-           To compile this driver as a module, choose M here: the module will
+         To compile this driver as a module, choose M here: the module will
          be called tifm_core.
  
  config TIFM_7XX1
          To make actual use of the device, you will have to select some
          flash card format drivers, as outlined in the TIFM_CORE Help.
  
-           To compile this driver as a module, choose M here: the module will
+         To compile this driver as a module, choose M here: the module will
          be called tifm_7xx1.
  
- config ACER_WMI
-         tristate "Acer WMI Laptop Extras (EXPERIMENTAL)"
-       depends on X86
-       depends on EXPERIMENTAL
-       depends on ACPI
-       depends on LEDS_CLASS
-       depends on NEW_LEDS
-       depends on BACKLIGHT_CLASS_DEVICE
-       depends on SERIO_I8042
-       depends on RFKILL
-       select ACPI_WMI
-       ---help---
-         This is a driver for newer Acer (and Wistron) laptops. It adds
-         wireless radio and bluetooth control, and on some laptops,
-         exposes the mail LED and LCD backlight.
-         For more information about this driver see
-         <file:Documentation/laptops/acer-wmi.txt>
-         If you have an ACPI-WMI compatible Acer/ Wistron laptop, say Y or M
-         here.
- config ASUS_LAPTOP
-         tristate "Asus Laptop Extras (EXPERIMENTAL)"
-         depends on X86
-         depends on ACPI
-       depends on EXPERIMENTAL && !ACPI_ASUS
-       depends on LEDS_CLASS
-       depends on NEW_LEDS
-       depends on BACKLIGHT_CLASS_DEVICE
-         ---help---
-         This is the new Linux driver for Asus laptops. It may also support some
-         MEDION, JVC or VICTOR laptops. It makes all the extra buttons generate
-         standard ACPI events that go through /proc/acpi/events. It also adds
-         support for video output switching, LCD backlight control, Bluetooth and
-         Wlan control, and most importantly, allows you to blink those fancy LEDs.
-         For more information and a userspace daemon for handling the extra
-         buttons see <http://acpi4asus.sf.net/>.
-         If you have an ACPI-compatible ASUS laptop, say Y or M here.
- config FUJITSU_LAPTOP
-         tristate "Fujitsu Laptop Extras"
-         depends on X86
-         depends on ACPI
-       depends on INPUT
-         depends on BACKLIGHT_CLASS_DEVICE
-         ---help---
-         This is a driver for laptops built by Fujitsu:
-           * P2xxx/P5xxx/S6xxx/S7xxx series Lifebooks
-           * Possibly other Fujitsu laptop models
-           * Tested with S6410 and S7020
-         It adds support for LCD brightness control and some hotkeys.
-         If you have a Fujitsu laptop, say Y or M here.
- config FUJITSU_LAPTOP_DEBUG
-       bool "Verbose debug mode for Fujitsu Laptop Extras"
-       depends on FUJITSU_LAPTOP
-       default n
-       ---help---
-         Enables extra debug output from the fujitsu extras driver, at the
-         expense of a slight increase in driver size.
-         If you are not sure, say N here.
- config TC1100_WMI
-       tristate "HP Compaq TC1100 Tablet WMI Extras (EXPERIMENTAL)"
-       depends on X86 && !X86_64
-       depends on EXPERIMENTAL
-       depends on ACPI
-       select ACPI_WMI
-       ---help---
-         This is a driver for the WMI extensions (wireless and bluetooth power
-         control) of the HP Compaq TC1100 tablet.
- config HP_WMI
-        tristate "HP WMI extras"
-        depends on ACPI_WMI
-        depends on INPUT
-        depends on RFKILL
-        help
-          Say Y here if you want to support WMI-based hotkeys on HP laptops and
-        to read data from WMI such as docking or ambient light sensor state.
-          To compile this driver as a module, choose M here: the module will
-          be called hp-wmi.
  config ICS932S401
        tristate "Integrated Circuits ICS932S401"
        depends on I2C && EXPERIMENTAL
          This driver can also be built as a module. If so, the module
          will be called ics932s401.
  
- config MSI_LAPTOP
-         tristate "MSI Laptop Extras"
-         depends on X86
-         depends on ACPI
-         depends on BACKLIGHT_CLASS_DEVICE
-         ---help---
-         This is a driver for laptops built by MSI (MICRO-STAR
-         INTERNATIONAL):
-         MSI MegaBook S270 (MS-1013)
-         Cytron/TCM/Medion/Tchibo MD96100/SAM2000
-         It adds support for Bluetooth, WLAN and LCD brightness control.
-         More information about this driver is available at
-         <http://0pointer.de/lennart/tchibo.html>.
-         If you have an MSI S270 laptop, say Y or M here.
- config PANASONIC_LAPTOP
-       tristate "Panasonic Laptop Extras"
-       depends on X86 && INPUT && ACPI
-         depends on BACKLIGHT_CLASS_DEVICE
-       ---help---
-         This driver adds support for access to backlight control and hotkeys
-         on Panasonic Let's Note laptops.
-         If you have a Panasonic Let's note laptop (such as the R1(N variant),
-         R2, R3, R5, T2, W2 and Y2 series), say Y.
- config COMPAL_LAPTOP
-       tristate "Compal Laptop Extras"
-       depends on X86
-       depends on ACPI
-       depends on BACKLIGHT_CLASS_DEVICE
-       ---help---
-         This is a driver for laptops built by Compal:
-         Compal FL90/IFL90
-         Compal FL91/IFL91
-         Compal FL92/JFL92
-         Compal FT00/IFT00
-         It adds support for Bluetooth, WLAN and LCD brightness control.
-         If you have an Compal FL9x/IFL9x/FT00 laptop, say Y or M here.
- config SONY_LAPTOP
-       tristate "Sony Laptop Extras"
-       depends on X86 && ACPI
-       select BACKLIGHT_CLASS_DEVICE
-       depends on INPUT
-         ---help---
-         This mini-driver drives the SNC and SPIC devices present in the ACPI
-         BIOS of the Sony Vaio laptops.
-         It gives access to some extra laptop functionalities like Bluetooth,
-         screen brightness control, Fn keys and allows powering on/off some
-         devices.
-         Read <file:Documentation/laptops/sony-laptop.txt> for more information.
- config SONYPI_COMPAT
-       bool "Sonypi compatibility"
-       depends on SONY_LAPTOP
-         ---help---
-         Build the sonypi driver compatibility code into the sony-laptop driver.
- config THINKPAD_ACPI
-       tristate "ThinkPad ACPI Laptop Extras"
-       depends on X86 && ACPI
-       select BACKLIGHT_LCD_SUPPORT
-       select BACKLIGHT_CLASS_DEVICE
-       select HWMON
-       select NVRAM
-       select INPUT
-       select NEW_LEDS
-       select LEDS_CLASS
-       select NET
-       select RFKILL
-       ---help---
-         This is a driver for the IBM and Lenovo ThinkPad laptops. It adds
-         support for Fn-Fx key combinations, Bluetooth control, video
-         output switching, ThinkLight control, UltraBay eject and more.
-         For more information about this driver see
-         <file:Documentation/laptops/thinkpad-acpi.txt> and
-         <http://ibm-acpi.sf.net/> .
-         This driver was formerly known as ibm-acpi.
-         If you have an IBM or Lenovo ThinkPad laptop, say Y or M here.
- config THINKPAD_ACPI_DEBUG
-       bool "Verbose debug mode"
-       depends on THINKPAD_ACPI
-       default n
-       ---help---
-         Enables extra debugging information, at the expense of a slightly
-         increase in driver size.
-         If you are not sure, say N here.
- config THINKPAD_ACPI_DOCK
-       bool "Legacy Docking Station Support"
-       depends on THINKPAD_ACPI
-       depends on ACPI_DOCK=n
-       default n
-       ---help---
-         Allows the thinkpad_acpi driver to handle docking station events.
-         This support was made obsolete by the generic ACPI docking station
-         support (CONFIG_ACPI_DOCK).  It will allow locking and removing the
-         laptop from the docking station, but will not properly connect PCI
-         devices.
-         If you are not sure, say N here.
- config THINKPAD_ACPI_BAY
-       bool "Legacy Removable Bay Support"
-       depends on THINKPAD_ACPI
-       default y
-       ---help---
-         Allows the thinkpad_acpi driver to handle removable bays.  It will
-         electrically disable the device in the bay, and also generate
-         notifications when the bay lever is ejected or inserted.
-         If you are not sure, say Y here.
- config THINKPAD_ACPI_VIDEO
-       bool "Video output control support"
-       depends on THINKPAD_ACPI
-       default y
-       ---help---
-         Allows the thinkpad_acpi driver to provide an interface to control
-         the various video output ports.
-         This feature often won't work well, depending on ThinkPad model,
-         display state, video output devices in use, whether there is a X
-         server running, phase of the moon, and the current mood of
-         Schroedinger's cat.  If you can use X.org's RandR to control
-         your ThinkPad's video output ports instead of this feature,
-         don't think twice: do it and say N here to save some memory.
-         If you are not sure, say Y here.
- config THINKPAD_ACPI_HOTKEY_POLL
-       bool "Support NVRAM polling for hot keys"
-       depends on THINKPAD_ACPI
-       default y
-       ---help---
-         Some thinkpad models benefit from NVRAM polling to detect a few of
-         the hot key press events.  If you know your ThinkPad model does not
-         need to do NVRAM polling to support any of the hot keys you use,
-         unselecting this option will save about 1kB of memory.
-         ThinkPads T40 and newer, R52 and newer, and X31 and newer are
-         unlikely to need NVRAM polling in their latest BIOS versions.
-         NVRAM polling can detect at most the following keys: ThinkPad/Access
-         IBM, Zoom, Switch Display (fn+F7), ThinkLight, Volume up/down/mute,
-         Brightness up/down, Display Expand (fn+F8), Hibernate (fn+F12).
-         If you are not sure, say Y here.  The driver enables polling only if
-         it is strictly necessary to do so.
  config ATMEL_SSC
        tristate "Device driver for Atmel SSC peripheral"
        depends on AVR32 || ARCH_AT91
  
          If unsure, say N.
  
- config INTEL_MENLOW
-       tristate "Thermal Management driver for Intel menlow platform"
-       depends on ACPI_THERMAL
-       select THERMAL
-       depends on X86
-       ---help---
-         ACPI thermal management enhancement driver on
-         Intel Menlow platform.
-         If unsure, say N.
- config EEEPC_LAPTOP
-       tristate "Eee PC Hotkey Driver (EXPERIMENTAL)"
-       depends on X86
-       depends on ACPI
-       depends on EXPERIMENTAL
-       select BACKLIGHT_CLASS_DEVICE
-       select HWMON
-       select RFKILL
-       ---help---
-         This driver supports the Fn-Fx keys on Eee PC laptops.
-         It also adds the ability to switch camera/wlan on/off.
-         If you have an Eee PC laptop, say Y or M here.
  config ENCLOSURE_SERVICES
        tristate "Enclosure Services"
        default n
@@@ -498,18 -218,6 +218,18 @@@ config SGI_GRU_DEBU
        This option enables addition debugging code for the SGI GRU driver. If
        you are unsure, say N.
  
 +config DELL_LAPTOP
 +      tristate "Dell Laptop Extras (EXPERIMENTAL)"
 +      depends on X86
 +      depends on DCDBAS
 +      depends on EXPERIMENTAL
 +      depends on BACKLIGHT_CLASS_DEVICE
 +      depends on RFKILL
 +      default n
 +      ---help---
 +      This driver adds support for rfkill and backlight control to Dell
 +      laptops.
 +
  source "drivers/misc/c2port/Kconfig"
  
  endif # MISC_DEVICES
diff --combined drivers/misc/Makefile
index 5de863a0e3956dae444215549e770bdb9a2049bc,d5749a7bc7775d1bddd58016e74c17f276087806..9cf8ae6e4b39f53107cf46887ee4b70633ccd5db
@@@ -1,33 -1,19 +1,20 @@@
  #
  # Makefile for misc devices that really don't fit anywhere else.
  #
- obj- := misc.o        # Dummy rule to force built-in.o to be made
  
  obj-$(CONFIG_IBM_ASM)         += ibmasm/
  obj-$(CONFIG_HDPU_FEATURES)   += hdpuftrs/
- obj-$(CONFIG_ASUS_LAPTOP)     += asus-laptop.o
- obj-$(CONFIG_EEEPC_LAPTOP)    += eeepc-laptop.o
- obj-$(CONFIG_MSI_LAPTOP)      += msi-laptop.o
- obj-$(CONFIG_COMPAL_LAPTOP)   += compal-laptop.o
- obj-$(CONFIG_ACER_WMI)                += acer-wmi.o
  obj-$(CONFIG_ATMEL_PWM)               += atmel_pwm.o
  obj-$(CONFIG_ATMEL_SSC)               += atmel-ssc.o
  obj-$(CONFIG_ATMEL_TCLIB)     += atmel_tclib.o
- obj-$(CONFIG_HP_WMI)          += hp-wmi.o
  obj-$(CONFIG_ICS932S401)      += ics932s401.o
- obj-$(CONFIG_TC1100_WMI)      += tc1100-wmi.o
  obj-$(CONFIG_LKDTM)           += lkdtm.o
  obj-$(CONFIG_TIFM_CORE)               += tifm_core.o
 +obj-$(CONFIG_DELL_LAPTOP)     += dell-laptop.o
  obj-$(CONFIG_TIFM_7XX1)               += tifm_7xx1.o
  obj-$(CONFIG_PHANTOM)         += phantom.o
  obj-$(CONFIG_SGI_IOC4)                += ioc4.o
- obj-$(CONFIG_SONY_LAPTOP)     += sony-laptop.o
- obj-$(CONFIG_THINKPAD_ACPI)   += thinkpad_acpi.o
- obj-$(CONFIG_FUJITSU_LAPTOP)  += fujitsu-laptop.o
- obj-$(CONFIG_PANASONIC_LAPTOP)        += panasonic-laptop.o
  obj-$(CONFIG_EEPROM_93CX6)    += eeprom_93cx6.o
- obj-$(CONFIG_INTEL_MENLOW)    += intel_menlow.o
  obj-$(CONFIG_ENCLOSURE_SERVICES) += enclosure.o
  obj-$(CONFIG_KGDB_TESTS)      += kgdbts.o
  obj-$(CONFIG_SGI_XP)          += sgi-xp/
index 0000000000000000000000000000000000000000,31f3ce2ac01cfc5e8261e8a8b9aa812e30e13066..e65448e99b48b9f0f233d77b8f0bd1dd36532161
mode 000000,100644..100644
--- /dev/null
@@@ -1,0 -1,375 +1,375 @@@
 -      depends on BACKLIGHT_CLASS_DEVICE
 -      depends on HWMON
+ #
+ # X86 Platform Specific Drivers
+ #
+ menuconfig X86_PLATFORM_DEVICES
+       bool "X86 Platform Specific Device Drivers"
+       default y
+       ---help---
+         Say Y here to get to see options for device drivers for various
+         x86 platforms, including vendor-specific laptop extension drivers.
+         This option alone does not add any kernel code.
+         If you say N, all options in this submenu will be skipped and disabled.
+ if X86_PLATFORM_DEVICES
+ config ACER_WMI
+       tristate "Acer WMI Laptop Extras (EXPERIMENTAL)"
+       depends on EXPERIMENTAL
+       depends on ACPI
+       depends on LEDS_CLASS
+       depends on NEW_LEDS
+       depends on BACKLIGHT_CLASS_DEVICE
+       depends on SERIO_I8042
+       depends on RFKILL
+       select ACPI_WMI
+       ---help---
+         This is a driver for newer Acer (and Wistron) laptops. It adds
+         wireless radio and bluetooth control, and on some laptops,
+         exposes the mail LED and LCD backlight.
+         For more information about this driver see
+         <file:Documentation/laptops/acer-wmi.txt>
+         If you have an ACPI-WMI compatible Acer/ Wistron laptop, say Y or M
+         here.
+ config ASUS_LAPTOP
+       tristate "Asus Laptop Extras (EXPERIMENTAL)"
+       depends on ACPI
+       depends on EXPERIMENTAL && !ACPI_ASUS
+       depends on LEDS_CLASS
+       depends on NEW_LEDS
+       depends on BACKLIGHT_CLASS_DEVICE
+       ---help---
+         This is the new Linux driver for Asus laptops. It may also support some
+         MEDION, JVC or VICTOR laptops. It makes all the extra buttons generate
+         standard ACPI events that go through /proc/acpi/events. It also adds
+         support for video output switching, LCD backlight control, Bluetooth and
+         Wlan control, and most importantly, allows you to blink those fancy LEDs.
+         For more information and a userspace daemon for handling the extra
+         buttons see <http://acpi4asus.sf.net/>.
+         If you have an ACPI-compatible ASUS laptop, say Y or M here.
+ config FUJITSU_LAPTOP
+       tristate "Fujitsu Laptop Extras"
+       depends on ACPI
+       depends on INPUT
+       depends on BACKLIGHT_CLASS_DEVICE
+       ---help---
+         This is a driver for laptops built by Fujitsu:
+           * P2xxx/P5xxx/S6xxx/S7xxx series Lifebooks
+           * Possibly other Fujitsu laptop models
+           * Tested with S6410 and S7020
+         It adds support for LCD brightness control and some hotkeys.
+         If you have a Fujitsu laptop, say Y or M here.
+ config FUJITSU_LAPTOP_DEBUG
+       bool "Verbose debug mode for Fujitsu Laptop Extras"
+       depends on FUJITSU_LAPTOP
+       default n
+       ---help---
+         Enables extra debug output from the fujitsu extras driver, at the
+         expense of a slight increase in driver size.
+         If you are not sure, say N here.
+ config TC1100_WMI
+       tristate "HP Compaq TC1100 Tablet WMI Extras (EXPERIMENTAL)"
+       depends on !X86_64
+       depends on EXPERIMENTAL
+       depends on ACPI
+       select ACPI_WMI
+       ---help---
+         This is a driver for the WMI extensions (wireless and bluetooth power
+         control) of the HP Compaq TC1100 tablet.
+ config HP_WMI
+       tristate "HP WMI extras"
+       depends on ACPI_WMI
+       depends on INPUT
+       depends on RFKILL
+       help
+        Say Y here if you want to support WMI-based hotkeys on HP laptops and
+        to read data from WMI such as docking or ambient light sensor state.
+        To compile this driver as a module, choose M here: the module will
+        be called hp-wmi.
+ config MSI_LAPTOP
+       tristate "MSI Laptop Extras"
+       depends on ACPI
+       depends on BACKLIGHT_CLASS_DEVICE
+       ---help---
+         This is a driver for laptops built by MSI (MICRO-STAR
+         INTERNATIONAL):
+         MSI MegaBook S270 (MS-1013)
+         Cytron/TCM/Medion/Tchibo MD96100/SAM2000
+         It adds support for Bluetooth, WLAN and LCD brightness control.
+         More information about this driver is available at
+         <http://0pointer.de/lennart/tchibo.html>.
+         If you have an MSI S270 laptop, say Y or M here.
+ config PANASONIC_LAPTOP
+       tristate "Panasonic Laptop Extras"
+       depends on INPUT && ACPI
+       depends on BACKLIGHT_CLASS_DEVICE
+       ---help---
+         This driver adds support for access to backlight control and hotkeys
+         on Panasonic Let's Note laptops.
+         If you have a Panasonic Let's note laptop (such as the R1(N variant),
+         R2, R3, R5, T2, W2 and Y2 series), say Y.
+ config COMPAL_LAPTOP
+       tristate "Compal Laptop Extras"
+       depends on ACPI
+       depends on BACKLIGHT_CLASS_DEVICE
+       ---help---
+         This is a driver for laptops built by Compal:
+         Compal FL90/IFL90
+         Compal FL91/IFL91
+         Compal FL92/JFL92
+         Compal FT00/IFT00
+         It adds support for Bluetooth, WLAN and LCD brightness control.
+         If you have an Compal FL9x/IFL9x/FT00 laptop, say Y or M here.
+ config SONY_LAPTOP
+       tristate "Sony Laptop Extras"
+       depends on ACPI
+       select BACKLIGHT_CLASS_DEVICE
+       depends on INPUT
+         ---help---
+         This mini-driver drives the SNC and SPIC devices present in the ACPI
+         BIOS of the Sony Vaio laptops.
+         It gives access to some extra laptop functionalities like Bluetooth,
+         screen brightness control, Fn keys and allows powering on/off some
+         devices.
+         Read <file:Documentation/laptops/sony-laptop.txt> for more information.
+ config SONYPI_COMPAT
+       bool "Sonypi compatibility"
+       depends on SONY_LAPTOP
+         ---help---
+         Build the sonypi driver compatibility code into the sony-laptop driver.
+ config THINKPAD_ACPI
+       tristate "ThinkPad ACPI Laptop Extras"
+       depends on ACPI
+       select BACKLIGHT_LCD_SUPPORT
+       select BACKLIGHT_CLASS_DEVICE
+       select HWMON
+       select NVRAM
+       select INPUT
+       select NEW_LEDS
+       select LEDS_CLASS
+       select NET
+       select RFKILL
+       ---help---
+         This is a driver for the IBM and Lenovo ThinkPad laptops. It adds
+         support for Fn-Fx key combinations, Bluetooth control, video
+         output switching, ThinkLight control, UltraBay eject and more.
+         For more information about this driver see
+         <file:Documentation/laptops/thinkpad-acpi.txt> and
+         <http://ibm-acpi.sf.net/> .
+         This driver was formerly known as ibm-acpi.
+         If you have an IBM or Lenovo ThinkPad laptop, say Y or M here.
+ config THINKPAD_ACPI_DEBUG
+       bool "Verbose debug mode"
+       depends on THINKPAD_ACPI
+       default n
+       ---help---
+         Enables extra debugging information, at the expense of a slightly
+         increase in driver size.
+         If you are not sure, say N here.
+ config THINKPAD_ACPI_DOCK
+       bool "Legacy Docking Station Support"
+       depends on THINKPAD_ACPI
+       depends on ACPI_DOCK=n
+       default n
+       ---help---
+         Allows the thinkpad_acpi driver to handle docking station events.
+         This support was made obsolete by the generic ACPI docking station
+         support (CONFIG_ACPI_DOCK).  It will allow locking and removing the
+         laptop from the docking station, but will not properly connect PCI
+         devices.
+         If you are not sure, say N here.
+ config THINKPAD_ACPI_BAY
+       bool "Legacy Removable Bay Support"
+       depends on THINKPAD_ACPI
+       default y
+       ---help---
+         Allows the thinkpad_acpi driver to handle removable bays.  It will
+         electrically disable the device in the bay, and also generate
+         notifications when the bay lever is ejected or inserted.
+         If you are not sure, say Y here.
+ config THINKPAD_ACPI_VIDEO
+       bool "Video output control support"
+       depends on THINKPAD_ACPI
+       default y
+       ---help---
+         Allows the thinkpad_acpi driver to provide an interface to control
+         the various video output ports.
+         This feature often won't work well, depending on ThinkPad model,
+         display state, video output devices in use, whether there is a X
+         server running, phase of the moon, and the current mood of
+         Schroedinger's cat.  If you can use X.org's RandR to control
+         your ThinkPad's video output ports instead of this feature,
+         don't think twice: do it and say N here to save some memory.
+         If you are not sure, say Y here.
+ config THINKPAD_ACPI_HOTKEY_POLL
+       bool "Support NVRAM polling for hot keys"
+       depends on THINKPAD_ACPI
+       default y
+       ---help---
+         Some thinkpad models benefit from NVRAM polling to detect a few of
+         the hot key press events.  If you know your ThinkPad model does not
+         need to do NVRAM polling to support any of the hot keys you use,
+         unselecting this option will save about 1kB of memory.
+         ThinkPads T40 and newer, R52 and newer, and X31 and newer are
+         unlikely to need NVRAM polling in their latest BIOS versions.
+         NVRAM polling can detect at most the following keys: ThinkPad/Access
+         IBM, Zoom, Switch Display (fn+F7), ThinkLight, Volume up/down/mute,
+         Brightness up/down, Display Expand (fn+F8), Hibernate (fn+F12).
+         If you are not sure, say Y here.  The driver enables polling only if
+         it is strictly necessary to do so.
+ config INTEL_MENLOW
+       tristate "Thermal Management driver for Intel menlow platform"
+       depends on ACPI_THERMAL
+       select THERMAL
+       ---help---
+         ACPI thermal management enhancement driver on
+         Intel Menlow platform.
+         If unsure, say N.
+ config EEEPC_LAPTOP
+       tristate "Eee PC Hotkey Driver (EXPERIMENTAL)"
+       depends on ACPI
 -      depends on RFKILL
+       depends on EXPERIMENTAL
++      select BACKLIGHT_CLASS_DEVICE
++      select HWMON
++      select RFKILL
+       ---help---
+         This driver supports the Fn-Fx keys on Eee PC laptops.
+         It also adds the ability to switch camera/wlan on/off.
+         If you have an Eee PC laptop, say Y or M here.
+ config ACPI_WMI
+       tristate "WMI (EXPERIMENTAL)"
+       depends on ACPI
+       depends on EXPERIMENTAL
+       help
+         This driver adds support for the ACPI-WMI (Windows Management
+         Instrumentation) mapper device (PNP0C14) found on some systems.
+         ACPI-WMI is a proprietary extension to ACPI to expose parts of the
+         ACPI firmware to userspace - this is done through various vendor
+         defined methods and data blocks in a PNP0C14 device, which are then
+         made available for userspace to call.
+         The implementation of this in Linux currently only exposes this to
+         other kernel space drivers.
+         This driver is a required dependency to build the firmware specific
+         drivers needed on many machines, including Acer and HP laptops.
+         It is safe to enable this driver even if your DSDT doesn't define
+         any ACPI-WMI devices.
+ config ACPI_ASUS
+       tristate "ASUS/Medion Laptop Extras"
+       depends on ACPI
+       select BACKLIGHT_CLASS_DEVICE
+       ---help---
+         This driver provides support for extra features of ACPI-compatible
+         ASUS laptops. As some of Medion laptops are made by ASUS, it may also
+         support some Medion laptops (such as 9675 for example).  It makes all
+         the extra buttons generate standard ACPI events that go through
+         /proc/acpi/events, and (on some models) adds support for changing the
+         display brightness and output, switching the LCD backlight on and off,
+         and most importantly, allows you to blink those fancy LEDs intended
+         for reporting mail and wireless status.
+         Note: display switching code is currently considered EXPERIMENTAL,
+         toying with these values may even lock your machine.
+         All settings are changed via /proc/acpi/asus directory entries. Owner
+         and group for these entries can be set with asus_uid and asus_gid
+         parameters.
+         More information and a userspace daemon for handling the extra buttons
+         at <http://sourceforge.net/projects/acpi4asus/>.
+         If you have an ACPI-compatible ASUS laptop, say Y or M here. This
+         driver is still under development, so if your laptop is unsupported or
+         something works not quite as expected, please use the mailing list
+         available on the above page (acpi4asus-user@lists.sourceforge.net).
+         NOTE: This driver is deprecated and will probably be removed soon,
+         use asus-laptop instead.
+ config ACPI_TOSHIBA
+       tristate "Toshiba Laptop Extras"
+       depends on ACPI
+       depends on INPUT
+       select INPUT_POLLDEV
+       select NET
+       select RFKILL
+       select BACKLIGHT_CLASS_DEVICE
+       ---help---
+         This driver adds support for access to certain system settings
+         on "legacy free" Toshiba laptops.  These laptops can be recognized by
+         their lack of a BIOS setup menu and APM support.
+         On these machines, all system configuration is handled through the
+         ACPI.  This driver is required for access to controls not covered
+         by the general ACPI drivers, such as LCD brightness, video output,
+         etc.
+         This driver differs from the non-ACPI Toshiba laptop driver (located
+         under "Processor type and features") in several aspects.
+         Configuration is accessed by reading and writing text files in the
+         /proc tree instead of by program interface to /dev.  Furthermore, no
+         power management functions are exposed, as those are handled by the
+         general ACPI drivers.
+         More information about this driver is available at
+         <http://memebeam.org/toys/ToshibaAcpiDriver>.
+         If you have a legacy free Toshiba laptop (such as the Libretto L1
+         series), say Y.
+ endif # X86_PLATFORM_DEVICES
index 65dc41540c62bdbe72bd0a68f88c042a7f06fd12,a7dd3e9fb79de5aa4efde7b293f139d90c87e994..65dc41540c62bdbe72bd0a68f88c042a7f06fd12
@@@ -3,7 -3,6 +3,7 @@@
  /*
    Copyright (C) 2007,2008 Jonathan Woithe <jwoithe@physics.adelaide.edu.au>
    Copyright (C) 2008 Peter Gruber <nokos@gmx.net>
 +  Copyright (C) 2008 Tony Vroon <tony@linx.net>
    Based on earlier work:
      Copyright (C) 2003 Shane Spencer <shane@bogomip.com>
      Adrian Yee <brewt-fujitsu@brewt.org>
  #include <linux/kfifo.h>
  #include <linux/video_output.h>
  #include <linux/platform_device.h>
 +#ifdef CONFIG_LEDS_CLASS
 +#include <linux/leds.h>
 +#endif
  
 -#define FUJITSU_DRIVER_VERSION "0.4.3"
 +#define FUJITSU_DRIVER_VERSION "0.5.0"
  
  #define FUJITSU_LCD_N_LEVELS 8
  
  #define ACPI_VIDEO_NOTIFY_INC_BRIGHTNESS     0x86
  #define ACPI_VIDEO_NOTIFY_DEC_BRIGHTNESS     0x87
  
 +/* FUNC interface - command values */
 +#define FUNC_RFKILL   0x1000
 +#define FUNC_LEDS     0x1001
 +#define FUNC_BUTTONS  0x1002
 +#define FUNC_BACKLIGHT  0x1004
 +
 +/* FUNC interface - responses */
 +#define UNSUPPORTED_CMD 0x80000000
 +
 +#ifdef CONFIG_LEDS_CLASS
 +/* FUNC interface - LED control */
 +#define FUNC_LED_OFF  0x1
 +#define FUNC_LED_ON   0x30001
 +#define KEYBOARD_LAMPS        0x100
 +#define LOGOLAMP_POWERON 0x2000
 +#define LOGOLAMP_ALWAYS  0x4000
 +#endif
 +
  /* Hotkey details */
  #define KEY1_CODE     0x410   /* codes for the keys in the GIRB register */
  #define KEY2_CODE     0x411
@@@ -155,6 -133,7 +155,6 @@@ struct fujitsu_t 
  
  static struct fujitsu_t *fujitsu;
  static int use_alt_lcd_levels = -1;
 -static int disable_brightness_keys = -1;
  static int disable_brightness_adjust = -1;
  
  /* Device used to access other hotkeys on the laptop */
@@@ -166,9 -145,8 +166,9 @@@ struct fujitsu_hotkey_t 
        struct platform_device *pf_device;
        struct kfifo *fifo;
        spinlock_t fifo_lock;
 -
 -      unsigned int irb;       /* info about the pressed buttons */
 +      int rfkill_state;
 +      int logolamp_registered;
 +      int kblamps_registered;
  };
  
  static struct fujitsu_hotkey_t *fujitsu_hotkey;
  static void acpi_fujitsu_hotkey_notify(acpi_handle handle, u32 event,
                                       void *data);
  
 +#ifdef CONFIG_LEDS_CLASS
 +static enum led_brightness logolamp_get(struct led_classdev *cdev);
 +static void logolamp_set(struct led_classdev *cdev,
 +                             enum led_brightness brightness);
 +
 +struct led_classdev logolamp_led = {
 + .name = "fujitsu::logolamp",
 + .brightness_get = logolamp_get,
 + .brightness_set = logolamp_set
 +};
 +
 +static enum led_brightness kblamps_get(struct led_classdev *cdev);
 +static void kblamps_set(struct led_classdev *cdev,
 +                             enum led_brightness brightness);
 +
 +struct led_classdev kblamps_led = {
 + .name = "fujitsu::kblamps",
 + .brightness_get = kblamps_get,
 + .brightness_set = kblamps_set
 +};
 +#endif
 +
  #ifdef CONFIG_FUJITSU_LAPTOP_DEBUG
  static u32 dbg_level = 0x03;
  #endif
  
  static void acpi_fujitsu_notify(acpi_handle handle, u32 event, void *data);
  
 +/* Fujitsu ACPI interface function */
 +
 +static int call_fext_func(int cmd, int arg0, int arg1, int arg2)
 +{
 +      acpi_status status = AE_OK;
 +      union acpi_object params[4] = {
 +      { .type = ACPI_TYPE_INTEGER },
 +      { .type = ACPI_TYPE_INTEGER },
 +      { .type = ACPI_TYPE_INTEGER },
 +      { .type = ACPI_TYPE_INTEGER }
 +      };
 +      struct acpi_object_list arg_list = { 4, &params[0] };
 +      struct acpi_buffer output;
 +      union acpi_object out_obj;
 +      acpi_handle handle = NULL;
 +
 +      status = acpi_get_handle(fujitsu_hotkey->acpi_handle, "FUNC", &handle);
 +      if (ACPI_FAILURE(status)) {
 +              vdbg_printk(FUJLAPTOP_DBG_ERROR,
 +                              "FUNC interface is not present\n");
 +              return -ENODEV;
 +      }
 +
 +      params[0].integer.value = cmd;
 +      params[1].integer.value = arg0;
 +      params[2].integer.value = arg1;
 +      params[3].integer.value = arg2;
 +
 +      output.length = sizeof(out_obj);
 +      output.pointer = &out_obj;
 +
 +      status = acpi_evaluate_object(handle, NULL, &arg_list, &output);
 +      if (ACPI_FAILURE(status)) {
 +              vdbg_printk(FUJLAPTOP_DBG_WARN,
 +                      "FUNC 0x%x (args 0x%x, 0x%x, 0x%x) call failed\n",
 +                              cmd, arg0, arg1, arg2);
 +              return -ENODEV;
 +      }
 +
 +      if (out_obj.type != ACPI_TYPE_INTEGER) {
 +              vdbg_printk(FUJLAPTOP_DBG_WARN,
 +                      "FUNC 0x%x (args 0x%x, 0x%x, 0x%x) did not "
 +                      "return an integer\n",
 +                      cmd, arg0, arg1, arg2);
 +              return -ENODEV;
 +      }
 +
 +      vdbg_printk(FUJLAPTOP_DBG_TRACE,
 +              "FUNC 0x%x (args 0x%x, 0x%x, 0x%x) returned 0x%x\n",
 +                      cmd, arg0, arg1, arg2, (int)out_obj.integer.value);
 +      return out_obj.integer.value;
 +}
 +
 +#ifdef CONFIG_LEDS_CLASS
 +/* LED class callbacks */
 +
 +static void logolamp_set(struct led_classdev *cdev,
 +                             enum led_brightness brightness)
 +{
 +      if (brightness >= LED_FULL) {
 +              call_fext_func(FUNC_LEDS, 0x1, LOGOLAMP_POWERON, FUNC_LED_ON);
 +              call_fext_func(FUNC_LEDS, 0x1, LOGOLAMP_ALWAYS, FUNC_LED_ON);
 +      } else if (brightness >= LED_HALF) {
 +              call_fext_func(FUNC_LEDS, 0x1, LOGOLAMP_POWERON, FUNC_LED_ON);
 +              call_fext_func(FUNC_LEDS, 0x1, LOGOLAMP_ALWAYS, FUNC_LED_OFF);
 +      } else {
 +              call_fext_func(FUNC_LEDS, 0x1, LOGOLAMP_POWERON, FUNC_LED_OFF);
 +      }
 +}
 +
 +static void kblamps_set(struct led_classdev *cdev,
 +                             enum led_brightness brightness)
 +{
 +      if (brightness >= LED_FULL)
 +              call_fext_func(FUNC_LEDS, 0x1, KEYBOARD_LAMPS, FUNC_LED_ON);
 +      else
 +              call_fext_func(FUNC_LEDS, 0x1, KEYBOARD_LAMPS, FUNC_LED_OFF);
 +}
 +
 +static enum led_brightness logolamp_get(struct led_classdev *cdev)
 +{
 +      enum led_brightness brightness = LED_OFF;
 +      int poweron, always;
 +
 +      poweron = call_fext_func(FUNC_LEDS, 0x2, LOGOLAMP_POWERON, 0x0);
 +      if (poweron == FUNC_LED_ON) {
 +              brightness = LED_HALF;
 +              always = call_fext_func(FUNC_LEDS, 0x2, LOGOLAMP_ALWAYS, 0x0);
 +              if (always == FUNC_LED_ON)
 +                      brightness = LED_FULL;
 +      }
 +      return brightness;
 +}
 +
 +static enum led_brightness kblamps_get(struct led_classdev *cdev)
 +{
 +      enum led_brightness brightness = LED_OFF;
 +
 +      if (call_fext_func(FUNC_LEDS, 0x2, KEYBOARD_LAMPS, 0x0) == FUNC_LED_ON)
 +              brightness = LED_FULL;
 +
 +      return brightness;
 +}
 +#endif
 +
  /* Hardware access for LCD brightness control */
  
  static int set_lcd_level(int level)
@@@ -412,34 -263,44 +412,34 @@@ static int get_max_brightness(void
        return fujitsu->max_brightness;
  }
  
 -static int get_lcd_level_alt(void)
 -{
 -      unsigned long long state = 0;
 -      acpi_status status = AE_OK;
 -
 -      vdbg_printk(FUJLAPTOP_DBG_TRACE, "get lcd level via GBLS\n");
 -
 -      status =
 -          acpi_evaluate_integer(fujitsu->acpi_handle, "GBLS", NULL, &state);
 -      if (status < 0)
 -              return status;
 -
 -      fujitsu->brightness_level = state & 0x0fffffff;
 -
 -      if (state & 0x80000000)
 -              fujitsu->brightness_changed = 1;
 -      else
 -              fujitsu->brightness_changed = 0;
 -
 -      return fujitsu->brightness_level;
 -}
 -
  /* Backlight device stuff */
  
  static int bl_get_brightness(struct backlight_device *b)
  {
 -      if (use_alt_lcd_levels)
 -              return get_lcd_level_alt();
 -      else
 -              return get_lcd_level();
 +      return get_lcd_level();
  }
  
  static int bl_update_status(struct backlight_device *b)
  {
 +      int ret;
 +      if (b->props.power == 4)
 +              ret = call_fext_func(FUNC_BACKLIGHT, 0x1, 0x4, 0x3);
 +      else
 +              ret = call_fext_func(FUNC_BACKLIGHT, 0x1, 0x4, 0x0);
 +      if (ret != 0)
 +              vdbg_printk(FUJLAPTOP_DBG_ERROR,
 +                      "Unable to adjust backlight power, error code %i\n",
 +                      ret);
 +
        if (use_alt_lcd_levels)
 -              return set_lcd_level_alt(b->props.brightness);
 +              ret = set_lcd_level_alt(b->props.brightness);
        else
 -              return set_lcd_level(b->props.brightness);
 +              ret = set_lcd_level(b->props.brightness);
 +      if (ret != 0)
 +              vdbg_printk(FUJLAPTOP_DBG_ERROR,
 +                      "Unable to adjust LCD brightness, error code %i\n",
 +                      ret);
 +      return ret;
  }
  
  static struct backlight_ops fujitsubl_ops = {
@@@ -483,7 -344,10 +483,7 @@@ static ssize_t show_lcd_level(struct de
  
        int ret;
  
 -      if (use_alt_lcd_levels)
 -              ret = get_lcd_level_alt();
 -      else
 -              ret = get_lcd_level();
 +      ret = get_lcd_level();
        if (ret < 0)
                return ret;
  
@@@ -508,71 -372,52 +508,71 @@@ static ssize_t store_lcd_level(struct d
        if (ret < 0)
                return ret;
  
 -      if (use_alt_lcd_levels)
 -              ret = get_lcd_level_alt();
 -      else
 -              ret = get_lcd_level();
 +      ret = get_lcd_level();
        if (ret < 0)
                return ret;
  
        return count;
  }
  
 -/* Hardware access for hotkey device */
 -
 -static int get_irb(void)
 +static ssize_t
 +ignore_store(struct device *dev,
 +           struct device_attribute *attr, const char *buf, size_t count)
  {
 -      unsigned long long state = 0;
 -      acpi_status status = AE_OK;
 -
 -      vdbg_printk(FUJLAPTOP_DBG_TRACE, "Get irb\n");
 -
 -      status =
 -          acpi_evaluate_integer(fujitsu_hotkey->acpi_handle, "GIRB", NULL,
 -                                &state);
 -      if (status < 0)
 -              return status;
 +      return count;
 +}
  
 -      fujitsu_hotkey->irb = state;
 +static ssize_t
 +show_lid_state(struct device *dev,
 +                      struct device_attribute *attr, char *buf)
 +{
 +      if (fujitsu_hotkey->rfkill_state == UNSUPPORTED_CMD)
 +              return sprintf(buf, "unknown\n");
 +      if (fujitsu_hotkey->rfkill_state & 0x100)
 +              return sprintf(buf, "open\n");
 +      else
 +              return sprintf(buf, "closed\n");
 +}
  
 -      return fujitsu_hotkey->irb;
 +static ssize_t
 +show_dock_state(struct device *dev,
 +                      struct device_attribute *attr, char *buf)
 +{
 +      if (fujitsu_hotkey->rfkill_state == UNSUPPORTED_CMD)
 +              return sprintf(buf, "unknown\n");
 +      if (fujitsu_hotkey->rfkill_state & 0x200)
 +              return sprintf(buf, "docked\n");
 +      else
 +              return sprintf(buf, "undocked\n");
  }
  
  static ssize_t
 -ignore_store(struct device *dev,
 -           struct device_attribute *attr, const char *buf, size_t count)
 +show_radios_state(struct device *dev,
 +                      struct device_attribute *attr, char *buf)
  {
 -      return count;
 +      if (fujitsu_hotkey->rfkill_state == UNSUPPORTED_CMD)
 +              return sprintf(buf, "unknown\n");
 +      if (fujitsu_hotkey->rfkill_state & 0x20)
 +              return sprintf(buf, "on\n");
 +      else
 +              return sprintf(buf, "killed\n");
  }
  
  static DEVICE_ATTR(max_brightness, 0444, show_max_brightness, ignore_store);
  static DEVICE_ATTR(brightness_changed, 0444, show_brightness_changed,
                   ignore_store);
  static DEVICE_ATTR(lcd_level, 0644, show_lcd_level, store_lcd_level);
 +static DEVICE_ATTR(lid, 0444, show_lid_state, ignore_store);
 +static DEVICE_ATTR(dock, 0444, show_dock_state, ignore_store);
 +static DEVICE_ATTR(radios, 0444, show_radios_state, ignore_store);
  
  static struct attribute *fujitsupf_attributes[] = {
        &dev_attr_brightness_changed.attr,
        &dev_attr_max_brightness.attr,
        &dev_attr_lcd_level.attr,
 +      &dev_attr_lid.attr,
 +      &dev_attr_dock.attr,
 +      &dev_attr_radios.attr,
        NULL
  };
  
@@@ -590,16 -435,24 +590,16 @@@ static struct platform_driver fujitsupf
  static void dmi_check_cb_common(const struct dmi_system_id *id)
  {
        acpi_handle handle;
 -      int have_blnf;
        printk(KERN_INFO "fujitsu-laptop: Identified laptop model '%s'.\n",
               id->ident);
 -      have_blnf = ACPI_SUCCESS
 -          (acpi_get_handle(NULL, "\\_SB.PCI0.GFX0.LCD.BLNF", &handle));
        if (use_alt_lcd_levels == -1) {
 -              vdbg_printk(FUJLAPTOP_DBG_TRACE, "auto-detecting usealt\n");
 -              use_alt_lcd_levels = 1;
 -      }
 -      if (disable_brightness_keys == -1) {
 -              vdbg_printk(FUJLAPTOP_DBG_TRACE,
 -                          "auto-detecting disable_keys\n");
 -              disable_brightness_keys = have_blnf ? 1 : 0;
 -      }
 -      if (disable_brightness_adjust == -1) {
 -              vdbg_printk(FUJLAPTOP_DBG_TRACE,
 -                          "auto-detecting disable_adjust\n");
 -              disable_brightness_adjust = have_blnf ? 0 : 1;
 +              if (ACPI_SUCCESS(acpi_get_handle(NULL,
 +                              "\\_SB.PCI0.LPCB.FJEX.SBL2", &handle)))
 +                      use_alt_lcd_levels = 1;
 +              else
 +                      use_alt_lcd_levels = 0;
 +              vdbg_printk(FUJLAPTOP_DBG_TRACE, "auto-detected usealt as "
 +                      "%i\n", use_alt_lcd_levels);
        }
  }
  
@@@ -728,14 -581,19 +728,14 @@@ static int acpi_fujitsu_add(struct acpi
  
        /* do config (detect defaults) */
        use_alt_lcd_levels = use_alt_lcd_levels == 1 ? 1 : 0;
 -      disable_brightness_keys = disable_brightness_keys == 1 ? 1 : 0;
        disable_brightness_adjust = disable_brightness_adjust == 1 ? 1 : 0;
        vdbg_printk(FUJLAPTOP_DBG_INFO,
 -                  "config: [alt interface: %d], [key disable: %d], [adjust disable: %d]\n",
 -                  use_alt_lcd_levels, disable_brightness_keys,
 -                  disable_brightness_adjust);
 +                  "config: [alt interface: %d], [adjust disable: %d]\n",
 +                  use_alt_lcd_levels, disable_brightness_adjust);
  
        if (get_max_brightness() <= 0)
                fujitsu->max_brightness = FUJITSU_LCD_N_LEVELS;
 -      if (use_alt_lcd_levels)
 -              get_lcd_level_alt();
 -      else
 -              get_lcd_level();
 +      get_lcd_level();
  
        return result;
  
@@@ -786,23 -644,43 +786,23 @@@ static void acpi_fujitsu_notify(acpi_ha
        case ACPI_FUJITSU_NOTIFY_CODE1:
                keycode = 0;
                oldb = fujitsu->brightness_level;
 -              get_lcd_level();  /* the alt version always yields changed */
 +              get_lcd_level();
                newb = fujitsu->brightness_level;
  
                vdbg_printk(FUJLAPTOP_DBG_TRACE,
                            "brightness button event [%i -> %i (%i)]\n",
                            oldb, newb, fujitsu->brightness_changed);
  
 -              if (oldb == newb && fujitsu->brightness_changed) {
 -                      keycode = 0;
 -                      if (disable_brightness_keys != 1) {
 -                              if (oldb == 0) {
 -                                      acpi_bus_generate_proc_event
 -                                          (fujitsu->dev,
 -                                           ACPI_VIDEO_NOTIFY_DEC_BRIGHTNESS,
 -                                           0);
 -                                      keycode = KEY_BRIGHTNESSDOWN;
 -                              } else if (oldb ==
 -                                         (fujitsu->max_brightness) - 1) {
 -                                      acpi_bus_generate_proc_event
 -                                          (fujitsu->dev,
 -                                           ACPI_VIDEO_NOTIFY_INC_BRIGHTNESS,
 -                                           0);
 -                                      keycode = KEY_BRIGHTNESSUP;
 -                              }
 -                      }
 -              } else if (oldb < newb) {
 +              if (oldb < newb) {
                        if (disable_brightness_adjust != 1) {
                                if (use_alt_lcd_levels)
                                        set_lcd_level_alt(newb);
                                else
                                        set_lcd_level(newb);
                        }
 -                      if (disable_brightness_keys != 1) {
 -                              acpi_bus_generate_proc_event(fujitsu->dev,
 -                                      ACPI_VIDEO_NOTIFY_INC_BRIGHTNESS, 0);
 -                              keycode = KEY_BRIGHTNESSUP;
 -                      }
 +                      acpi_bus_generate_proc_event(fujitsu->dev,
 +                              ACPI_VIDEO_NOTIFY_INC_BRIGHTNESS, 0);
 +                      keycode = KEY_BRIGHTNESSUP;
                } else if (oldb > newb) {
                        if (disable_brightness_adjust != 1) {
                                if (use_alt_lcd_levels)
                                else
                                        set_lcd_level(newb);
                        }
 -                      if (disable_brightness_keys != 1) {
 -                              acpi_bus_generate_proc_event(fujitsu->dev,
 -                                      ACPI_VIDEO_NOTIFY_DEC_BRIGHTNESS, 0);
 -                              keycode = KEY_BRIGHTNESSDOWN;
 -                      }
 -              } else {
 -                      keycode = KEY_UNKNOWN;
 +                      acpi_bus_generate_proc_event(fujitsu->dev,
 +                              ACPI_VIDEO_NOTIFY_DEC_BRIGHTNESS, 0);
 +                      keycode = KEY_BRIGHTNESSDOWN;
                }
                break;
        default:
@@@ -889,8 -771,7 +889,8 @@@ static int acpi_fujitsu_hotkey_add(stru
        input->id.bustype = BUS_HOST;
        input->id.product = 0x06;
        input->dev.parent = &device->dev;
 -      input->evbit[0] = BIT(EV_KEY);
 +
 +      set_bit(EV_KEY, input->evbit);
        set_bit(fujitsu->keycode1, input->keybit);
        set_bit(fujitsu->keycode2, input->keybit);
        set_bit(fujitsu->keycode3, input->keybit);
                        printk(KERN_ERR "_INI Method failed\n");
        }
  
 -      i = 0;                  /* Discard hotkey ringbuffer */
 -      while (get_irb() != 0 && (i++) < MAX_HOTKEY_RINGBUFFER_SIZE) ;
 +      i = 0;
 +      while (call_fext_func(FUNC_BUTTONS, 0x1, 0x0, 0x0) != 0
 +              && (i++) < MAX_HOTKEY_RINGBUFFER_SIZE)
 +              ; /* No action, result is discarded */
        vdbg_printk(FUJLAPTOP_DBG_INFO, "Discarded %i ringbuffer entries\n", i);
  
 +      fujitsu_hotkey->rfkill_state =
 +              call_fext_func(FUNC_RFKILL, 0x4, 0x0, 0x0);
 +
 +      /* Suspect this is a keymap of the application panel, print it */
 +      printk(KERN_INFO "fujitsu-laptop: BTNI: [0x%x]\n",
 +              call_fext_func(FUNC_BUTTONS, 0x0, 0x0, 0x0));
 +
 +      #ifdef CONFIG_LEDS_CLASS
 +      if (call_fext_func(FUNC_LEDS, 0x0, 0x0, 0x0) & LOGOLAMP_POWERON) {
 +              result = led_classdev_register(&fujitsu->pf_device->dev,
 +                                              &logolamp_led);
 +              if (result == 0) {
 +                      fujitsu_hotkey->logolamp_registered = 1;
 +              } else {
 +                      printk(KERN_ERR "fujitsu-laptop: Could not register "
 +                      "LED handler for logo lamp, error %i\n", result);
 +              }
 +      }
 +
 +      if ((call_fext_func(FUNC_LEDS, 0x0, 0x0, 0x0) & KEYBOARD_LAMPS) &&
 +         (call_fext_func(FUNC_BUTTONS, 0x0, 0x0, 0x0) == 0x0)) {
 +              result = led_classdev_register(&fujitsu->pf_device->dev,
 +                                              &kblamps_led);
 +              if (result == 0) {
 +                      fujitsu_hotkey->kblamps_registered = 1;
 +              } else {
 +                      printk(KERN_ERR "fujitsu-laptop: Could not register "
 +                      "LED handler for keyboard lamps, error %i\n", result);
 +              }
 +      }
 +      #endif
 +
        return result;
  
  end:
@@@ -1005,15 -852,16 +1005,15 @@@ static void acpi_fujitsu_hotkey_notify(
  
        input = fujitsu_hotkey->input;
  
 -      vdbg_printk(FUJLAPTOP_DBG_TRACE, "Hotkey event\n");
 +      fujitsu_hotkey->rfkill_state =
 +              call_fext_func(FUNC_RFKILL, 0x4, 0x0, 0x0);
  
        switch (event) {
        case ACPI_FUJITSU_NOTIFY_CODE1:
                i = 0;
 -              while ((irb = get_irb()) != 0
 -                     && (i++) < MAX_HOTKEY_RINGBUFFER_SIZE) {
 -                      vdbg_printk(FUJLAPTOP_DBG_TRACE, "GIRB result [%x]\n",
 -                                  irb);
 -
 +              while ((irb =
 +                      call_fext_func(FUNC_BUTTONS, 0x1, 0x0, 0x0)) != 0
 +                              && (i++) < MAX_HOTKEY_RINGBUFFER_SIZE) {
                        switch (irb & 0x4ff) {
                        case KEY1_CODE:
                                keycode = fujitsu->keycode1;
@@@ -1187,15 -1035,6 +1187,15 @@@ static int __init fujitsu_init(void
                goto fail_hotkey1;
        }
  
 +      /* Sync backlight power status (needs FUJ02E3 device, hence deferred) */
 +
 +      if (!acpi_video_backlight_support()) {
 +              if (call_fext_func(FUNC_BACKLIGHT, 0x2, 0x4, 0x0) == 3)
 +                      fujitsu->bl_device->props.power = 4;
 +              else
 +                      fujitsu->bl_device->props.power = 0;
 +      }
 +
        printk(KERN_INFO "fujitsu-laptop: driver " FUJITSU_DRIVER_VERSION
               " successfully loaded.\n");
  
@@@ -1235,14 -1074,6 +1235,14 @@@ fail_acpi
  
  static void __exit fujitsu_cleanup(void)
  {
 +      #ifdef CONFIG_LEDS_CLASS
 +      if (fujitsu_hotkey->logolamp_registered != 0)
 +              led_classdev_unregister(&logolamp_led);
 +
 +      if (fujitsu_hotkey->kblamps_registered != 0)
 +              led_classdev_unregister(&kblamps_led);
 +      #endif
 +
        sysfs_remove_group(&fujitsu->pf_device->dev.kobj,
                           &fujitsupf_attribute_group);
        platform_device_unregister(fujitsu->pf_device);
@@@ -1267,6 -1098,9 +1267,6 @@@ module_exit(fujitsu_cleanup)
  module_param(use_alt_lcd_levels, uint, 0644);
  MODULE_PARM_DESC(use_alt_lcd_levels,
                 "Use alternative interface for lcd_levels (needed for Lifebook s6410).");
 -module_param(disable_brightness_keys, uint, 0644);
 -MODULE_PARM_DESC(disable_brightness_keys,
 -               "Disable brightness keys (eg. if they are already handled by the generic ACPI_VIDEO device).");
  module_param(disable_brightness_adjust, uint, 0644);
  MODULE_PARM_DESC(disable_brightness_adjust, "Disable brightness adjustment .");
  #ifdef CONFIG_FUJITSU_LAPTOP_DEBUG
@@@ -1274,13 -1108,12 +1274,13 @@@ module_param_named(debug, dbg_level, ui
  MODULE_PARM_DESC(debug, "Sets debug level bit-mask");
  #endif
  
 -MODULE_AUTHOR("Jonathan Woithe, Peter Gruber");
 +MODULE_AUTHOR("Jonathan Woithe, Peter Gruber, Tony Vroon");
  MODULE_DESCRIPTION("Fujitsu laptop extras support");
  MODULE_VERSION(FUJITSU_DRIVER_VERSION);
  MODULE_LICENSE("GPL");
  
  MODULE_ALIAS("dmi:*:svnFUJITSUSIEMENS:*:pvr:rvnFUJITSU:rnFJNB1D3:*:cvrS6410:*");
 +MODULE_ALIAS("dmi:*:svnFUJITSUSIEMENS:*:pvr:rvnFUJITSU:rnFJNB1E6:*:cvrS6420:*");
  MODULE_ALIAS("dmi:*:svnFUJITSU:*:pvr:rvnFUJITSU:rnFJNB19C:*:cvrS7020:*");
  
  static struct pnp_device_id pnp_ids[] = {
index f30db367c82eed36540b9db55f7e6b9abb72267b,4a1bc64485d5a61523a2eaee5975555c843ac859..f30db367c82eed36540b9db55f7e6b9abb72267b
@@@ -241,6 -241,8 +241,6 @@@ static int acpi_pcc_write_sset(struct p
        };
        acpi_status status = AE_OK;
  
 -      ACPI_FUNCTION_TRACE("acpi_pcc_write_sset");
 -
        status = acpi_evaluate_object(pcc->handle, METHOD_HKEY_SSET,
                                      &params, NULL);
  
@@@ -252,6 -254,8 +252,6 @@@ static inline int acpi_pcc_get_sqty(str
        unsigned long long s;
        acpi_status status;
  
 -      ACPI_FUNCTION_TRACE("acpi_pcc_get_sqty");
 -
        status = acpi_evaluate_integer(device->handle, METHOD_HKEY_SQTY,
                                       NULL, &s);
        if (ACPI_SUCCESS(status))
@@@ -270,6 -274,8 +270,6 @@@ static int acpi_pcc_retrieve_biosdata(s
        union acpi_object *hkey = NULL;
        int i;
  
 -      ACPI_FUNCTION_TRACE("acpi_pcc_retrieve_biosdata");
 -
        status = acpi_evaluate_object(pcc->handle, METHOD_HKEY_SINF, 0,
                                      &buffer);
        if (ACPI_FAILURE(status)) {
@@@ -495,6 -501,8 +495,6 @@@ static void acpi_pcc_generate_keyinput(
        int key_code, hkey_num;
        unsigned long long result;
  
 -      ACPI_FUNCTION_TRACE("acpi_pcc_generate_keyinput");
 -
        rc = acpi_evaluate_integer(pcc->handle, METHOD_HKEY_QUERY,
                                   NULL, &result);
        if (!ACPI_SUCCESS(rc)) {
@@@ -530,6 -538,8 +530,6 @@@ static void acpi_pcc_hotkey_notify(acpi
  {
        struct pcc_acpi *pcc = (struct pcc_acpi *) data;
  
 -      ACPI_FUNCTION_TRACE("acpi_pcc_hotkey_notify");
 -
        switch (event) {
        case HKEY_NOTIFY:
                acpi_pcc_generate_keyinput(pcc);
@@@ -544,6 -554,8 +544,6 @@@ static int acpi_pcc_init_input(struct p
  {
        int i, rc;
  
 -      ACPI_FUNCTION_TRACE("acpi_pcc_init_input");
 -
        pcc->input_dev = input_allocate_device();
        if (!pcc->input_dev) {
                ACPI_DEBUG_PRINT((ACPI_DB_ERROR,
@@@ -585,6 -597,8 +585,6 @@@ static int acpi_pcc_hotkey_resume(struc
        struct pcc_acpi *pcc = acpi_driver_data(device);
        acpi_status status = AE_OK;
  
 -      ACPI_FUNCTION_TRACE("acpi_pcc_hotkey_resume");
 -
        if (device == NULL || pcc == NULL)
                return -EINVAL;
  
@@@ -602,6 -616,8 +602,6 @@@ static int acpi_pcc_hotkey_add(struct a
        struct pcc_acpi *pcc;
        int num_sifr, result;
  
 -      ACPI_FUNCTION_TRACE("acpi_pcc_hotkey_add");
 -
        if (!device)
                return -EINVAL;
  
@@@ -698,6 -714,8 +698,6 @@@ static int __init acpi_pcc_init(void
  {
        int result = 0;
  
 -      ACPI_FUNCTION_TRACE("acpi_pcc_init");
 -
        if (acpi_disabled)
                return -ENODEV;
  
@@@ -715,6 -733,8 +715,6 @@@ static int acpi_pcc_hotkey_remove(struc
  {
        struct pcc_acpi *pcc = acpi_driver_data(device);
  
 -      ACPI_FUNCTION_TRACE("acpi_pcc_hotkey_remove");
 -
        if (!device || !pcc)
                return -EINVAL;
  
  
  static void __exit acpi_pcc_exit(void)
  {
 -      ACPI_FUNCTION_TRACE("acpi_pcc_exit");
 -
        acpi_bus_unregister_driver(&acpi_pcc_driver);
  }
  
index 537959d07148a9c3f1e76ec0637b6de3c65ac1cb,571b211608d1a7224575d99fe3ca5e27cccd03a2..537959d07148a9c3f1e76ec0637b6de3c65ac1cb
@@@ -935,17 -935,14 +935,17 @@@ static void sony_acpi_notify(acpi_handl
  static acpi_status sony_walk_callback(acpi_handle handle, u32 level,
                                      void *context, void **return_value)
  {
 -      struct acpi_namespace_node *node;
 -      union acpi_operand_object *operand;
 +      struct acpi_device_info *info;
 +      struct acpi_buffer buffer = {ACPI_ALLOCATE_BUFFER, NULL};
  
 -      node = (struct acpi_namespace_node *)handle;
 -      operand = (union acpi_operand_object *)node->object;
 +      if (ACPI_SUCCESS(acpi_get_object_info(handle, &buffer))) {
 +              info = buffer.pointer;
  
 -      printk(KERN_WARNING DRV_PFX "method: name: %4.4s, args %X\n", node->name.ascii,
 -             (u32) operand->method.param_count);
 +              printk(KERN_WARNING DRV_PFX "method: name: %4.4s, args %X\n",
 +                      (char *)&info->name, info->param_count);
 +
 +              kfree(buffer.pointer);
 +      }
  
        return AE_OK;
  }
index b4a4aa9ee482edacecb4224b4245ee8db2ba0c7f,f25e4c974dcf9d7f4ff557451d234cd6d2a05428..b4a4aa9ee482edacecb4224b4245ee8db2ba0c7f
@@@ -30,6 -30,7 +30,6 @@@
  #include <linux/init.h>
  #include <linux/types.h>
  #include <acpi/acpi.h>
 -#include <acpi/actypes.h>
  #include <acpi/acpi_bus.h>
  #include <acpi/acpi_drivers.h>
  #include <linux/platform_device.h>
index 3478453eba7a3e8e2997cc25fcdd807f377efb86,899766e16fa822cdfd7abc240e2ce0ee7ea329e4..3478453eba7a3e8e2997cc25fcdd807f377efb86
@@@ -76,6 -76,7 +76,6 @@@
  #include <linux/workqueue.h>
  
  #include <acpi/acpi_drivers.h>
 -#include <acpi/acnamesp.h>
  
  #include <linux/pci_ids.h>