summaryrefslogtreecommitdiffstats
path: root/drivers/staging/android/alarm-dev.c
Commit message (Collapse)AuthorAgeFilesLines
* staging: alarm-dev: Seperate functions with one blank lineSeongJae Park2013-11-191-0/+1
| | | | | Signed-off-by: SeongJae Park <sj38.park@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: alarm-dev: Remove unnecessary blank linesSeongJae Park2013-11-191-3/+0
| | | | | Signed-off-by: SeongJae Park <sj38.park@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: alarm-dev: Remove unnecessary parenthesisSeongJae Park2013-11-191-2/+2
| | | | | Signed-off-by: SeongJae Park <sj38.park@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging/android: Add kerneldoc to one function in alarm-dev.cCruz Julian Bishop2013-09-171-2/+6
| | | | | | | | | | | | Sorry. I thought that this would be a nice easy class to document fully. Turns out I was very wrong - I will have to research the Linux alarm and timer subsystem one day next week and try again. Here is what I started out with, anyway. It's not much, but it's better than nothing! Signed-off-by: Cruz Julian Bishop <cruzjbishop@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: alarm-dev: information leak in alarm_compat_ioctl()Dan Carpenter2013-06-041-1/+3
| | | | | | | | | | If we pass an invalid clock type then "ts" is never set. We need to check for errors earlier, otherwise we end up passing uninitialized stack data to userspace. Reported-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: alarm-dev: information leak in alarm_ioctl()Dan Carpenter2013-06-031-1/+3
| | | | | | | | | | Smatch complains that if we pass an invalid clock type then "ts" is never set. We need to check for errors earlier, otherwise we end up passing uninitialized stack data to userspace. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: alarm-dev: Implement compat_ioctl supportJohn Stultz2013-01-181-0/+35
| | | | | | | | | | | Implement compat_ioctl support for the alarm-dev ioctl. Cc: Serban Constantinescu <serban.constantinescu@arm.com> Cc: Arve Hjønnevåg <arve@android.com> Cc: Colin Cross <ccross@google.com> Cc: Android Kernel Team <kernel-team@android.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: alarm-dev: Refactor alarm-dev ioctl code in prep for compat_ioctlJohn Stultz2013-01-181-89/+139
| | | | | | | | | | | | Cleanup the Android alarm-dev driver's ioctl code to refactor it in preparation for compat_ioctl support. Cc: Serban Constantinescu <serban.constantinescu@arm.com> Cc: Arve Hjønnevåg <arve@android.com> Cc: Colin Cross <ccross@google.com> Cc: Android Kernel Team <kernel-team@android.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: alarm-dev: Drop pre Android 1.0 _OLD ioctlsJohn Stultz2013-01-181-16/+2
| | | | | | | | | | | | | | | | | | Per Colin's comment: "The "support old userspace code" comment for those two ioctls has been there since pre-Android 1.0. Those apis are not exposed to Android apps, I don't see any problem deleting them." Thus this patch removes the ANDROID_ALARM_SET_OLD and ANDROID_ALARM_SET_AND_WAIT_OLD ioctl compatability logic. Cc: Serban Constantinescu <serban.constantinescu@arm.com> Cc: Arve Hjønnevåg <arve@android.com> Cc: Colin Cross <ccross@google.com> Cc: Android Kernel Team <kernel-team@android.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: android: Alarm driver cleanupsDae S. Kim2012-09-041-10/+7
| | | | | | | | | Little cleanups. Enum value ANDROID_ALARM_TYPE_COUNT was treated as an alarm type within a switch statement. That condition was unreachable though. Signed-off-by: Dae S. Kim <dae@velatum.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: android: alarm: remove unnecessary goto statementDevendra Naga2012-06-131-1/+0
| | | | | Signed-off-by: Devendra Naga <devendra.aaru@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: Android: Fix NULL pointer related warning in alarm-dev.c fileSachin Kamat2012-06-121-1/+1
| | | | | | | | | Fixes the following sparse warning: drivers/staging/android/alarm-dev.c:259:35: warning: Using plain integer as NULL pointer Cc: Brian Swetland <swetland@google.com> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: android: alarm: Rename pr_alarm to alarm_dbgJoe Perches2012-06-041-17/+17
| | | | | | | | | | | Rename a macro to make it explicit it's for debugging. Use %s: __func__ instead of embedding function names. Coalesce formats, align arguments. Signed-off-by: Joe Perches <joe@perches.com> Acked-by: David Rientjes <rientjes@google.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: android-alarm: Switch from wakelocks to wakeup sourcesJohn Stultz2012-04-241-19/+7
| | | | | | | | | | | | | | | | | | | | | In their current AOSP tree, the Android in-kernel wakelock infrastructure has been reimplemented in terms of wakeup sources: http://git.linaro.org/gitweb?p=people/jstultz/android.git;a=commitdiff;h=e9911f4efdc55af703b8b3bb8c839e6f5dd173bb The Android alarm driver currently has stubbed out calls to wakelock functionality. So this patch simply converts the stubbed out wakelock calls to wakeup source calls, and removes the empty wakelock macros Greg, would you mind queuing this in staging-next? CC: Colin Cross <ccross@android.com> CC: Arve Hjønnevåg <arve@android.com> CC: Greg KH <gregkh@linuxfoundation.org> CC: Android Kernel Team <kernel-team@android.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: android-alarm: Rework alarm-dev.c to use upstreamed alarmtimersJohn Stultz2012-04-201-10/+98
| | | | | | | | | | | This reworks the alarm-dev.c to use the upstreamed alarmtimers interface. CC: Colin Cross <ccross@android.com> CC: Thomas Gleixner <tglx@linutronix.de> CC: Android Kernel Team <kernel-team@android.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: android-alarm: Convert ALARM_ELAPSED_REALTIME to use CLOCK_BOOTTIMEJohn Stultz2012-04-201-2/+1
| | | | | | | | | | | | | | | | | | | The ALARM_ELAPSED_REALTIME clock domain in Android pointed to the need for something similar in linux system-wide (instead of limited to just the alarm interface). Thus CLOCK_BOOTTIME was introduced into the upstream kernel in 2.6.39. This patch attempts to convert the android alarm timer to utilize the kernel's CLOCK_BOOTTIME clockid for ALARM_ELAPSED_REALTIME, instead of managing it itself. CC: Colin Cross <ccross@android.com> CC: Thomas Gleixner <tglx@linutronix.de> CC: Android Kernel Team <kernel-team@android.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: Fix typo within android drivers.Masanari Iida2012-04-181-1/+1
| | | | | | | Fix spelling typo in comments within android drivers. Signed-off-by: Masanari Iida <standby24x7@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: android-alarm: HACK: wakelock workaroundJohn Stultz2012-02-101-1/+12
| | | | | | | | | | Allow Android alarmtimer device to build while wakelocks are still out of tree. CC: Arve Hjønnevåg <arve@android.com> CC: Android Kernel Team <kernel-team@android.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: android-alarm: Fix namespace collision with upstreamed alarmtimersJohn Stultz2012-02-101-7/+7
| | | | | | | | | | | The upstreamed alarmtimers are similar but not quite 100% API compatibile with the android in-kernel alarm api. To aid the transition, prefix the the android in-kernel api with android_ CC: Arve Hjønnevåg <arve@android.com> CC: Android Kernel Team <kernel-team@android.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: android-alarm: Fix include compile issuesJohn Stultz2012-02-101-2/+1
| | | | | | | | | | | The file asm/mach/time.h doesn't exist on all arches, so include <linux/time.h>. Also linux/sysdev.h is gone so kill it. CC: Arve Hjønnevåg <arve@android.com> CC: Android Kernel Team <kernel-team@android.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: android-alarm: Add needed module.h includesAndy Green2012-02-101-0/+1
| | | | | | | | | | | | | Add module.h includes required to build CC: Arve Hjønnevåg <arve@android.com> CC: Android Kernel Team <kernel-team@android.com> CC: Andy Green <andy.green@linaro.org> Signed-off-by: Andy Green <andy.green@linaro.org> [jstultz: Tweaked commit subject, folded two patches into one] Signed-off-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: android-alarm: Add android alarm driver & in-kernel alarm interfaceArve Hjønnevåg2012-02-101-0/+286
Drivers can now create alarms that will use an hrtimer while the system is running and the rtc to wake up from suspend. CC: Arve Hjønnevåg <arve@android.com> CC: Android Kernel Team <kernel-team@android.com> Signed-off-by: Arve Hjønnevåg <arve@android.com> [Fold and move alarm driver and interface to staging, fix whitespace issue, drop kconfig & make file changes as it currently doesn't build -jstultz] Signed-off-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
OpenPOWER on IntegriCloud