aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/iio/trigger (follow)
AgeCommit message (Collapse)AuthorFilesLines
2016-12-25ktime: Cleanup ktime_set() usageThomas Gleixner1-3/+2
ktime_set(S,N) was required for the timespec storage type and is still useful for situations where a Seconds and Nanoseconds part of a time value needs to be converted. For anything where the Seconds argument is 0, this is pointless and can be replaced with a simple assignment. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: Peter Zijlstra <peterz@infradead.org>
2016-06-03iio:trigger: Experimental kthread tight loop trigger (thread only)Jonathan Cameron3-0/+156
This patch is in response to that of Gregor Boirie <gregor.boirie@parrot.com> who proposed using a tight kthread within a device driver (be it with the support factored out into a helper library) in order to basically spin as fast as possible. It is meant as a talking point rather than a formal proposal of the code (though we are heading towards that I think). Also gives people some working code to mess around with. I proposed that this could be done with a trigger with a few constraints and this is the proof (be it ugly) of that. There are some constraints though, some of which we would want to relax if this were to move forward. * Will only run the thread part of the registered pollfunc. This is to avoid the overhead of jumping in and out of interrupt context. Is the overhead significant? Not certain but feels like it should be! * This limitation precludes any device that 'must' do some work in interrupt context. However, that is true of few if any drivers and I suspect that any that do will be restricted to using triggers they provide themselves. Usually we have a top half mainly to grab a timestamp as soon after the dataready type signal as possible. Signed-off-by: Jonathan Cameron <jic23@kernel.org> Acked-by: Daniel Baluta <daniel.baluta@intel.com>
2015-12-03iio: trigger: Introduce IIO hrtimer based triggerDaniel Baluta3-0/+205
This patch registers a new IIO software trigger interrupt source based on high resolution timers. Notice that if configfs is enabled we create sampling_frequency attribute allowing users to change hrtimer period (1/sampling_frequency). The IIO hrtimer trigger has a long history, this patch is based on an older version from Marten and Lars-Peter. Signed-off-by: Marten Svanfeldt <marten@intuitiveaerial.com> Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Daniel Baluta <daniel.baluta@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2014-12-26iio: trigger: Add a blank line after declarationsRoberta Dobrescu1-0/+2
This patch fixes the following checkpatch.pl warning: WARNING: Missing a blank line after declarations Signed-off-by: Roberta Dobrescu <roberta.dobrescu@gmail.com> Reviewed-by: Daniel Baluta <daniel.baluta@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2014-08-26iio: remove .owner field for driver using module_platform_driverSanjeev Sharma1-1/+0
This patch removes the .owner field for drivers which use the platform_driver_register api because this is overriden in _platform_driver_register. Signed-off-by: Sanjeev Sharma <Sanjeev_Sharma@mentor.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2014-06-14iio: Remove timestamp argument from iio_trigger_poll() and iio_trigger_poll_chained()Peter Meerwald2-3/+2
argument has been ignored; adjust drivers accordingly Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2013-09-28iio:trigger: fix sysfs name on list mutexDenis CIOCCA1-7/+7
Signed-off-by: Denis Ciocca <denis.ciocca@st.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2013-08-03iio: Add a comment to about alphabetical order to Kconfigs and MakefilesLars-Peter Clausen2-0/+3
Keeping Makefile and Kconfig entries in alphabetical order usually works better than just appending new entries at the end, since it reduces the amount of conflicts. This patch adds a comment to the IIO Kconfig and Makefile files to document that the entries should be kept in alphabetical order. Also reorder those entries which weren't in alphabetical order yet. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2013-08-03iio: fix Kconfig typosPeter Meerwald1-1/+1
Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2013-06-08iio:trigger:interrupt fix formatting of rsize variable in nameJonathan Cameron1-1/+1
The name includes irq_res->start which of type resource_size_t not integer. We could in theory use %pa for this but then it would be in hex and also that causes a warning about incorrect types anyway. Hence just use the irq local variable we assigned the line above. Reported-by: Fengguang Wu <fengguang.wu@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2013-06-04iio:triggers:interrupt trigger - move out of staging.Jonathan Cameron3-0/+131
This is now a very simple trigger indeed but useful in many common cases. Signed-off-by: Jonathan Cameron <jic23@kernel.org> Reviewed-by: Lars-Peter Clausen <lars@metafoo.de>
2013-06-04iio: replace strict_strtoul() with kstrtoul()Jingoo Han1-2/+2
The usage of strict_strtoul() is not preferred, because strict_strtoul() is obsolete. Thus, kstrtoul() should be used. Signed-off-by: Jingoo Han <jg1.han@samsung.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2013-05-22iio:trigger:sysfs Move out of staging.Jonathan Cameron3-0/+249
This simple driver is rather useful. No issues about its interface have been raised for some time hence the proposal to move it out of staging. Signed-off-by: Jonathan Cameron <jic23@kernel.org>