1. 20 7月, 2013 1 次提交
    • L
      iio:trigger: Fix use_count race condition · a1a8e1dc
      Lars-Peter Clausen 提交于
      When using more than one trigger consumer it can happen that multiple threads
      perform a read-modify-update cycle on 'use_count' concurrently. This can cause
      updates to be lost and use_count can get stuck at non-zero value, in which case
      the IIO core assumes that at least one thread is still running and will wait for
      it to finish before running any trigger handlers again. This effectively renders
      the trigger disabled and a reboot is necessary before it can be used again. To
      fix this make use_count an atomic variable. Also set it to the number of
      consumers before starting the first consumer, otherwise it might happen that
      use_count drops to 0 even though not all consumers have been run yet.
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Tested-by: NDenis Ciocca <denis.ciocca@st.com>
      Signed-off-by: NJonathan Cameron <jic23@kernel.org>
      a1a8e1dc
  2. 29 6月, 2013 1 次提交
  3. 07 2月, 2013 1 次提交
  4. 08 7月, 2012 1 次提交
  5. 07 7月, 2012 1 次提交
  6. 23 6月, 2012 1 次提交
  7. 15 5月, 2012 1 次提交
  8. 30 4月, 2012 1 次提交
    • L
      staging:iio: Streamline API function naming · 7cbb7537
      Lars-Peter Clausen 提交于
      Currently we use two different naming schemes in the IIO API, iio_verb_object
      and iio_object_verb. E.g iio_device_register and iio_allocate_device. This
      patches renames instances of the later to the former. The patch also renames allocate to
      alloc as this seems to be the preferred form throughout the kernel.
      
      In particular the following renames are performed by the patch:
      	iio_put_device -> iio_device_put
      	iio_allocate_device -> iio_device_alloc
      	iio_free_device -> iio_device_free
      	iio_get_trigger -> iio_trigger_get
      	iio_put_trigger -> iio_trigger_put
      	iio_allocate_trigger -> iio_trigger_alloc
      	iio_free_trigger -> iio_trigger_free
      
      The conversion was done with the following coccinelle patch with manual fixes to
      comments and documentation.
      
      <smpl>
      @@
      @@
      -iio_put_device
      +iio_device_put
      @@
      @@
      -iio_allocate_device
      +iio_device_alloc
      @@
      @@
      -iio_free_device
      +iio_device_free
      @@
      @@
      -iio_get_trigger
      +iio_trigger_get
      @@
      @@
      -iio_put_trigger
      +iio_trigger_put
      @@
      @@
      -iio_allocate_trigger
      +iio_trigger_alloc
      @@
      @@
      -iio_free_trigger
      +iio_trigger_free
      </smpl>
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Acked-by: NJonathan Cameron <jic23@kernel.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      7cbb7537
  9. 26 4月, 2012 2 次提交
  10. 02 12月, 2011 1 次提交
  11. 27 11月, 2011 3 次提交
  12. 11 10月, 2011 1 次提交
  13. 27 9月, 2011 2 次提交
  14. 07 9月, 2011 3 次提交
  15. 25 8月, 2011 7 次提交
  16. 24 8月, 2011 2 次提交
  17. 29 6月, 2011 1 次提交
  18. 08 6月, 2011 1 次提交
  19. 20 5月, 2011 6 次提交
  20. 26 4月, 2011 2 次提交
  21. 23 7月, 2010 1 次提交