aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/platform
Commit message (Collapse)AuthorAge
...
| | | | | * | | asus-laptop: use device_create_file() instead of platform_groupCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There is two reason to do that: - we don't want a "gps" file if the model doesn't have a gps - we don't want to use global variables anymore Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: clean led codeCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove all "templates" and add a generic struct asus_led instead. Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: add gps rfkillCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The rfkill subsystem will enable gps by default. Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: set initial lcd stateCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There is no way to find the initial lcd state. A quick workaround is to set it "on" by default. Anyway this feature is scheduled for removal. Signed-off-by: Corentin Chary <corentin.chary@gmail.com>
| | | | | * | | asus-laptop: leds, remove dead code and fix asus_led_exit()/asus_led_init()Corentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These bug where introduced in "asus-laptop: code movement". Signed-off-by: Corentin Chary <corentin.chary@gmail.com>
| | | | | * | | asus-laptop: add backlight changes notificationsCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We don't want to send KEY_BRIGHTNESSDOWN or KEY_BRIGHTNESSUP because it would be a lie to tell userspace that we want to change the brightness while it's actually done by the firmware. Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: add bluetooth keys found on M9VCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reported by Andrey F. Ilchuk Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: switch to sparse keymap libraryCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch is based on Dmitry Torokhov's patch with some modifications and cleanups. Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: rename wireless_status to wlan_status to avoid confusionCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: add error check for write_acpi_int callsCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also add to helpers for bluetooth and wlan. Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: stop using ASUS_HANDLE and use relative methods insteadCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Stop using ASUS_HANDLE because most of the time it is not needed. This macro was introduced to display_get and lcd_switch which are not part of the interface provided by Asus, and are scheduled for removal. Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: rename function talking directly to acpi with asus_xxx schemeCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: removing read_status/store_status/write_status and asus->statusCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: stop using read_status for lcdCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (anyway lcd code is scheduled for removal) Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: stop using read_status and store_status for GPSCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: stop using read_status for bluetooth and wlanCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: code movementCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The asus-laptop driver implements a number of interfaces like the backlight class driver. This change makes it easier to examine the implementation of one interface at at a time, without having to search through the file to find init() and exit() functions etc. Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: callbacks should use "driver data" parameter or fieldCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (Changelog stolen from Alan's patch for eeepc-laptop, but this patch does the same thing for asus-laptop) Callback methods should not refer to a variable like "asus" (formally "hotk"). Instead, they should extract the data they need either from a "driver data" parameter, or the "driver data" field of the object which they operate on. The "asus" variable can then be removed. In practice, drivers under "drivers/platform" can get away without using driver data, because it doesn't make sense to have more than one instance of them. However this makes it harder to review them for correctness. This is especially true for core ACPI developers who have not previously been exposed to this anti-pattern :-). This will serve as an example of best practice for new driver writers (whether they find it themselves, or have it pointed out during review :-). Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: move backlight and dsdt info inside asus_laptop structCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Prepare the use of "driver data" for callbacks. Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: revise namesCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | asus-laptop now does a lot more than just hotkeys. Replace the "hotk" names used throughout the driver with some slightly more appropriate names. The actual strings used in kernel messages and sysfs are left unchanged. Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: change initialization orderCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Clean asus-laptop initialization to match new eeepc-laptop code. Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: remove unecessary hotk != NULL checkCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: use tabs to indent macros and remove unused onesCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: simplify write_acpi_intCorentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We only need a buffer for "INIT". Adds write_acpi_init_ret for it. Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: no need to check argument of set_brightness()Corentin Chary2010-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We already tell the backlight class our maximum brightness value; it will validate the user requested values for us. Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | | * | | asus-laptop: add wireless and bluetooth status parameterCorentin Chary2010-02-28
| | |_|_|/ / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These to parameter allow to set the status of wlan and bluetooth device when the module load. On some models, the device will always be down on boot, so the default behavior is to always enable these devices. Signed-off-by: Corentin Chary <corentincj@iksaif.net>
| | | | * | | toshiba-acpi: fix multimedia keys on some machinesFrans Pop2010-03-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some Toshibas only send ACPI events on key down, not key release. Ignore any release events and send key down and key up events on every ACPI key down event. Signed-off-by: Frans Pop <elendil@planet.nl>
| | | | * | | dell-laptop: Fix errors on failure and exit pathsMatthew Garrett2010-03-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make sure that work is cancelled after removing the i8042 filter, and unregister the platform device rather than deleting it. Signed-off-by: Matthew Garrett <mjg@redhat.com> Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com>
| | | | * | | dell-laptop: Fix build error by making buffer_mutex staticIngo Molnar2010-03-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The following build bug (x86, allyesconfig): arch/x86/oprofile/built-in.o:(.data+0x250): multiple definition of `buffer_mutex' Was triggered in -tip testing, caused by this upstream commit: 116ee77: dell-laptop: Use buffer with 32-bit physical address There's multiple buffer_mutex's in the kernel. Make this new one static. Signed-off-by: Ingo Molnar <mingo@elte.hu>
| | | * | | | Merge branch 'acpica' of ↵Linus Torvalds2010-03-01
| | | |\ \ \ \ | | | | |/ / / | | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6 * 'acpica' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6: ACPI: replace acpi_integer by u64 ACPICA: Update version to 20100121. ACPICA: Remove unused uint32_struct type ACPICA: Disassembler: Remove obsolete "Integer64" field in parse object ACPICA: Remove obsolete ACPI_INTEGER (acpi_integer) type ACPICA: Predefined name repair: fix NULL package elements ACPICA: AcpiGetDevices: Eliminate unnecessary _STA calls ACPICA: Update all ACPICA copyrights and signons to 2010 ACPICA: Update for new gcc-4 warning options
| | | | * | | ACPI: replace acpi_integer by u64Lin Ming2010-01-28
| | | | |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | acpi_integer is now obsolete and removed from the ACPICA code base, replaced by u64. Signed-off-by: Lin Ming <ming.m.lin@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
| | | * | | toshiba_acpi: Add full hotkey supportMatthew Garrett2010-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Calling the ENAB method on Toshiba laptops results in notifications being sent when laptop hotkeys are pressed. This patch simply calls that method and sets up an input device if it's successful. Signed-off-by: Matthew Garrett <mjg@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Len Brown <len.brown@intel.com>
| | | * | | hp-wmi: Add support for tablet rotation keyMatthew Garrett2010-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The HP touchsmart tablet has a key for rotating the UI from landscape to portrait. Add support for it. Signed-off-by: Matthew Garrett <mjg@redhat.com>
| | | * | | dell-laptop: Add another Dell laptop to the DMI whitelistErik Andren2010-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Latitude C640 has another variation of dell in its DMI vendor entry. Add it to the whitelist in order to enjoy the sweet fruits of software backlight toggling. Signed-off-by: Erik Andren <erik.andren@gmail.com>
| | | * | | classmate-laptop: use a single MODULE_DEVICE_TABLE to get correct aliasesThadeu Lima de Souza Cascardo2010-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of a MODULE_DEVICE_TABLE for every acpi_driver ids table, we create a table containing all ids to export to get a module alias for each one. This will fix automatic loading of the driver when one of the ACPI devices is not present (like the accelerometer, which is not present in some models). Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com>
| | | * | | dell-laptop: Pay attention to which devices the hardware switch controlsMatthew Garrett2010-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Right now, we assume that the hardware rfkill switch on Dells toggles all radio devices. In fact, this can be configured in the BIOS and so right now we may mark a device as hardware killed even when it isn't. Add code to query the devices controlled by the switch, and use this when determining the hardware kill state of a radio. Signed-off-by: Matthew Garrett <mjg@redhat.com>
| | | * | | dell-laptop: Use buffer with 32-bit physical addressStuart Hayes2010-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Calls to communicate with system firmware via a SMI (using dcdbas) need to use a buffer that has a physical address of 4GB or less. Currently the dell-laptop driver does not guarantee this, and when the buffer address is higher than 4GB, the address is truncated to 32 bits and the SMI handler writes to the wrong memory address. Signed-off-by: Stuart Hayes <stuart_hayes@dell.com> Acked-by: Matthew Garrett <mjg@redhat.com>
| | | * | | dell-laptop: Blacklist machines not supporting dell-laptopMario Limonciello2010-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Mini family doesn't support smbios 17,11 although it reports it does. Signed-off-by: Mario Limonciello <superm1@ubuntu.com> Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
| | | * | | dell-laptop: Block software state changes when rfkill hard blockedMario Limonciello2010-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The "hardware" switch is tied directly to a BIOS interface that will connect and disconnect the hardware from the bus. If you use the software interface to request the BIOS to make these changes, the HW switch will be in an inconsistent state and LEDs may not reflect the state of the HW. Signed-off-by: Mario Limonciello <Mario_Limonciello@Dell.com>
| | | * | | dell-laptop: Fix small memory leakMatthew Garrett2010-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | da_tokens was not being freed by dell-laptop on unload. Fix that. Signed-off-by: Matthew Garrett <mjg@redhat.com>
| | | * | | dell-laptop: Fix platform device unregistrationMatthew Garrett2010-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | dell-laptop currently fails to clean up its platform device correctly. Make sure that it's unregistered. Signed-off-by: Matthew Garrett <mjg@redhat.com>
| | | * | | dell-laptop: Update rfkill state on kill switchMatthew Garrett2010-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The rfkill interface on Dells only sends a notification that the switch has been changed via the keyboard controller. Add a filter so we can pick these notifications up and update the rfkill state appropriately. Signed-off-by: Matthew Garrett <mjg@redhat.com>
| | | * | | compal-laptop: Replace sysfs support with rfkill supportMario Limonciello2010-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This drops the support for manually groking the files in sysfs to turn on and off the WLAN and BT for Compal laptops in favor of platform rfkill support. It has been combined into a single patch to not introduce regressions in the process of simply adding rfkill support Signed-off-by: Mario Limonciello <Mario_Limonciello@Dell.com> Signed-off-by: Tim Gardner <tim.gardner@canonical.com> Signed-off-by: Matthew Garrett <mjg@redhat.com> Cc: Cezary Jackiewicz <cezary.jackiewicz@gmail.com>
| | | * | | compal-laptop: Add support for known Compal made Dell laptopsMario Limonciello2010-02-25
| | |/ / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The following Dell laptops are known to have been manufacturer by Compal and are supported by the compal-laptop platform driver - Mini 9 - Mini 10 - Mini 12 - Mini 10v - Inspiron 11z Signed-off-by: Mario Limonciello <Mario_Limonciello@Dell.com> Signed-off-by: Tim Gardner <tim.gardner@canonical.com> Signed-off-by: Matthew Garrett <mjg@redhat.com> Cc: Cezary Jackiewicz <cezary.jackiewicz@gmail.com>
| * | | | acer-wmi: Respect current backlight level when loadingCarlos Corbacho2010-02-19
| | |_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Set the backlight to use the current brightness when loaded, rather than always resetting the backlight to maximum brightness. Fixes kernel bugzilla #14207 Signed-off-by: Carlos Corbacho <carlos@strangeworlds.co.uk> Reported-by: Denis Mukhin <denis_mukhin@yahoo.com> Signed-off-by: Len Brown <len.brown@intel.com>
| * | | thinkpad-acpi: wrong thermal attribute_group removed in thermal_exit()Roel Kluin2010-02-16
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | sysfs_remove_group() removed the wrong attribute_group for thermal_read_mode TPEC_8, ACPI_TMP07 and ACPI_UPDT Signed-off-by: Roel Kluin <roel.kluin@gmail.com> Acked-by: Henrique de Moraes Holschuh <ibm-acpi@hmh.eng.br> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Len Brown <len.brown@intel.com>
| * | Merge branch 'misc' into releaseLen Brown2010-01-20
| |\ \
| | * | sony-laptop - fix using of uninitialized variableDmitry Torokhov2010-01-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | CC [M] drivers/platform/x86/sony-laptop.o drivers/platform/x86/sony-laptop.c: In function 'sony_nc_rfkill_setup': drivers/platform/x86/sony-laptop.c:1162: warning: 'i' may be used uninitialized in this function Signed-off-by: Dmitry Torokhov <dtor@mail.ru> Acked-by: Mattia Dongili <malattia@linux.it> Signed-off-by: Len Brown <len.brown@intel.com>
| * | | eeepc-laptop: disable wireless hotplug for 1201NCorentin Chary2010-01-16
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Corentin Chary <corentincj@iksaif.net> Signed-off-by: Len Brown <len.brown@intel.com>
| * | | eeepc-laptop: add hotplug_disable parameterCorentin Chary2010-01-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some new models need to disable wireless hotplug. For the moment, we don't know excactly what models need that, except 1005HA. Users will be able to use that param as a workaround. Signed-off-by: Corentin Chary <corentincj@iksaif.net> Signed-off-by: Len Brown <len.brown@intel.com>