1. 07 Dec, 2015 4 commits
    • Bryan O'Donoghue's avatar
      greybus: loopback: Ensure we reset stats once and once only · f42a6891
      Bryan O'Donoghue authored
      9445c54c ('greybus/loopback: drop bus aggregate calculation') removed the
      aggregation of data in-kernel but instead of dropping the reset of
      aggregate stastics, converted that reset into a second reset of the
      connection-level stats. While this doesn't result in anything bad it's
      also definitely a dumb thing to be doing, so, drop it now.
      
      Also ensure we reset the bridge-specific tracking variables at least once.
      Signed-off-by: default avatarBryan O'Donoghue <bryan.odonoghue@linaro.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@google.com>
      f42a6891
    • Bryan O'Donoghue's avatar
      greybus: loopback: Convert thread delay to microseconds · b36f04fa
      Bryan O'Donoghue authored
      Currently the loopback code allows a delay between operations specified in
      milliseconds. Having added asynchronous bi-directional support to loopback
      its obvious that the delay value would be far more useful specified in
      microseconds than milliseconds. So, this patch makes the necessary
      conversion.
      Signed-off-by: default avatarBryan O'Donoghue <bryan.odonoghue@linaro.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@google.com>
      b36f04fa
    • Bryan O'Donoghue's avatar
      greybus: loopback: Add asynchronous bi-directional support · 12927835
      Bryan O'Donoghue authored
      A particular ask from the firmware people for some time now has been the
      ability to drive multiple outstanding bi-directional operations from
      loopback to loopback Interfaces. This patch implments that change.
      
      The approach taken is to make a call to gb_operation_send() and have
      loopback capture the completion callback itself, with a parallel timer to
      timeout completion callbacks that take too long. The calling thread will
      issue each gb_operation_send() as fast as it can within the constraints of
      thread-safety.
      
      In order to support this addition the following new sysfs entries are
      created on a per-connection basis.
      
      - async
        Zero indicates loopback should use the traditional synchronous model
        i.e. gb_operation_request_send_sync().
      
        Non-zero indicates loopback should use the new asynchronous model i.e.
        gb_operation_send()
      
      - requests_completed
        This value indicates the number of requests successfully completed.
      
      - requests_timedout
        This value indicates the number of requests which timed out.
      
      - timeout
        The number of microseconds to give an individual asynchronous request
        before timing that request out.
      
      - timeout_min
        Read-only attribute informs user-space of the minimum allowed timeout.
      
      - timeout_max
        Read-only attribute informs user-space of the maximum allowed timeout.
      
      Note requests_completed + requests_timedout should always equal
      iteration_max, once iteration_count == iteration_max. Also, at this time we
      support either synchronous or asynchronous operations in one set of
      transactions.
      Signed-off-by: default avatarBryan O'Donoghue <bryan.odonoghue@linaro.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@google.com>
      12927835
    • Bryan O'Donoghue's avatar
      greybus: loopback: Convert cross-thread mutex to spinlock while relaxing connect locks · 2e238d71
      Bryan O'Donoghue authored
      This patch converts the cross-thread mutex used to synchronize threads with
      respect to each other to a spinlock. This is done to enable taking of locks
      in the following patches while in atomic context. A small re-order of
      locking in connection setup/tear-down is done to minimize the amount of
      time spent in spinlock_irqsave().
      Signed-off-by: default avatarBryan O'Donoghue <bryan.odonoghue@linaro.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@google.com>
      2e238d71
  2. 05 Dec, 2015 4 commits
  3. 04 Dec, 2015 3 commits
  4. 03 Dec, 2015 19 commits
  5. 30 Nov, 2015 1 commit
  6. 25 Nov, 2015 9 commits