summaryrefslogtreecommitdiff
path: root/keypair.c
AgeCommit message (Collapse)AuthorFilesLines
2013-06-12keypair: add missing include fileDaniel Borkmann1-0/+1
Include curve.h so that it also finds the selftest. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-06-11keypair: do selftest before generating and verifying keypairDaniel Borkmann1-0/+4
Be paraniod and make a selftest. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
2013-06-04keypair: Add routines to generate and verify a keypairDaniel Borkmann1-0/+71
This is needed in order to replace curvetun's routines. Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
c118570c276a645ea'>diff)
iio: trigger: helpers to determine own trigger
This adds a helper function to the IIO trigger framework: iio_trigger_using_own(): for an IIO device, this tells whether the device is using itself as a trigger. This is true if the indio device: (A) supplies a trigger and (B) has assigned its own buffer poll function to use this trigger. This helper function is good when constructing triggered, buffered drivers that can either use its own hardware *OR* an external trigger such as a HRTimer or even the trigger from a totally different sensor. Under such circumstances it is important to know for example if the timestamp from the same trigger hardware should be used when populating the buffer: if iio_trigger_using_own() is true, we can use this timestamp, else we need to pick a unique timestamp directly in the trigger handler. For this to work of course IIO devices registering hardware triggers must follow the convention to set the parent device properly, as as well as setting the parent of the IIO device itself. When a new poll function is attached, we check if the parent device of the IIO of the poll function is the same as the parent device of the trigger and in that case we conclude that the hardware is using itself as trigger. Cc: Giuseppe Barba <giuseppe.barba@st.com> Cc: Denis Ciocca <denis.ciocca@st.com> Cc: Crestez Dan Leonard <leonard.crestez@intel.com> Cc: Gregor Boirie <gregor.boirie@parrot.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Diffstat