summaryrefslogtreecommitdiffstats
path: root/drivers/platform/x86/amilo-rfkill.c
Commit message (Collapse)AuthorAgeFilesLines
* drivers/platform/x86/amilo-rfkill.c::amilo_rfkill_probe() avoid NULL derefJesper Juhl2012-03-261-1/+4
| | | | | | | | | | | | | | | | In drivers/platform/x86/amilo-rfkill.c::amilo_rfkill_probe() the call to dmi_first_match() may fail and return NULL. If it does return NULL, then we'll be dereferencing a NULL pointer in the rfkill_alloc() call where we do 'system_id->driver_data' --> KABOOM! Avoid that problem by testing for a NULL return value from dmi_first_match() and bailing out if it fails. I was a bit uncertain about what to return in the failure case. In the end I settled for -ENXIO as the most logical error to return. Signed-off-by: Jesper Juhl <jj@chaosbits.net> Signed-off-by: Matthew Garrett <mjg@redhat.com>
* x86: Add amilo-rfkill driver for some Fujitsu-Siemens Amilo laptopsBen Hutchings2012-03-121-0/+173
An rfkill driver based on the fsaa1655g and fsam7440 drivers for Fujitsu-Siemens Amilo A1655 and M7440 models found at: http://sourceforge.net/projects/fsaa1655g/ http://sourceforge.net/projects/fsam7440/ This adds DMI matching, replaces the procfs files with rfkill devices, and uses the proper functions to write to the i8042 safely. Signed-off-by: Ben Hutchings <ben@decadent.org.uk> Signed-off-by: Matthew Garrett <mjg@redhat.com>
OpenPOWER on IntegriCloud