1. 01 Feb, 2019 32 commits
  2. 28 Jan, 2019 8 commits
    • Jan Kiszka's avatar
      ipipe: Introduce ptrace resume notifier · 0d7a1b1a
      Jan Kiszka authored
      This I-pipe hook reports the desired resumption mode to the subscriber:
      resume all process tasks or just single-step a particular one? The use
      case is to enable synchronous stopping / resuming of all head tasks of
      a ptraced real-time process.
      Signed-off-by: Jan Kiszka's avatarJan Kiszka <jan.kiszka@siemens.com>
      0d7a1b1a
    • Jan Kiszka's avatar
      ipipe: Introduce infrastructure for userspace return notifier · 0446de9e
      Jan Kiszka authored
      A little bit inspired by the kernel's user return notifier, this
      introduces an I-pipe hook before the kernel jumps back to a userspace
      context from the root domain. The hook is design to allow a switch back
      to the head domain, thus will not run through signal/preemption checks
      when returning from the callback over head. It is guaranteed to fire on
      return from interrupts and exceptions but may also fire on certain
      syscall-return paths.
      
      The first use case for the hook is resumption of ptraced tasks over
      head if they were stopped in that domain.
      
      This provides just the generic infrastructure, the invocation of
      __ipipe_notify_user_intreturn as well as the definition of
      TIP_USERINTRET are architecture-specific.
      Signed-off-by: Jan Kiszka's avatarJan Kiszka <jan.kiszka@siemens.com>
      0446de9e
    • Philippe Gerum's avatar
      f33c814a
    • Philippe Gerum's avatar
      sched/core: ipipe: do not panic on failed migration to the head stage · 8a91f46e
      Philippe Gerum authored
      __ipipe_migrate_head() should not BUG() unconditionally when failing
      to schedule out a thread, but rather let the real-time core handle the
      situation a bit more gracefully.
      8a91f46e
    • Philippe Gerum's avatar
      ipipe: timer: prevent double-ack if host timer is not grabbed · e20cb615
      Philippe Gerum authored
      Only timers stolen away from the host kernel should be early acked by
      the pipeline core. Otherwise, the regular IRQ handler associated to
      the timer would duplicate the action. The IRQ line is left masked,
      waiting for the IRQ flow handler to unmask it eventually.
      e20cb615
    • Philippe Gerum's avatar
      ipipe: timer: notify co-kernel about entering ONESHOT_STOPPED mode · 219698c4
      Philippe Gerum authored
      Although we don't want to disable the hardware not to wreck the
      outstanding timing requests managed by the co-kernel, we should
      nevertheless notify it about entering the ONESHOT_STOPPED mode, so
      that it may disable the host tick emulation.
      219698c4
    • Philippe Gerum's avatar
      ipipe: timer: do not interpose on undefined handlers · 6d8bfb5b
      Philippe Gerum authored
      There is no point in interposing on clock chip handlers for which
      there was no support originally. In some cases (oneshot_stopped), we
      may even get a kernel fault, jumping to a NULL address.
      
      Interpose on non-NULL original handlers only.
      6d8bfb5b
    • Philippe Gerum's avatar
      ipipe: timer: resume hardware operations in oneshot handler · 9b0b0d7a
      Philippe Gerum authored
      Although we won't allow disabling the hardware when the clock event
      logic switches a device to stopped mode - so that we won't affect the
      timer logic running on the head stage unexpectedly -, we still have to
      enable the hardware when switched (back) to oneshot mode, since it may
      have been stopped prior to interposing on the device in
      ipipe_timer_start().
      
      Failing to do so would leave the hardware shut down for both regular
      and Xenomai operations, with no mean to bring it up again.
      9b0b0d7a