1. 06 Apr, 2010 3 commits
    • Carsten Emde's avatar
      mqueue: Convert message queue timeout to use hrtimers · 9ca7d8e6
      Carsten Emde authored
      The message queue functions mq_timedsend() and mq_timedreceive()
      have not yet been converted to use the hrtimer interface.
      
      This patch replaces the call to schedule_timeout() by a call to
      schedule_hrtimeout() and transforms the expiration time from
      timespec to ktime as required.
      
      [ tglx: Fixed whitespace wreckage ]
      Signed-off-by: default avatarCarsten Emde <C.Emde@osadl.org>
      Tested-by: default avatarPradyumna Sampath <pradysam@gmail.com>
      Cc: Arjan van de Veen <arjan@infradead.org>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      LKML-Reference: <20100402204331.715783034@osadl.org>
      Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      9ca7d8e6
    • Carsten Emde's avatar
      hrtimers: Provide schedule_hrtimeout for CLOCK_REALTIME · 351b3f7a
      Carsten Emde authored
      The current version of schedule_hrtimeout() always uses the
      monotonic clock. Some system calls such as mq_timedsend()
      and mq_timedreceive(), however, require the use of the wall
      clock due to the definition of the system call.
      
      This patch provides the infrastructure to use schedule_hrtimeout() 
      with a CLOCK_REALTIME timer.
      Signed-off-by: default avatarCarsten Emde <C.Emde@osadl.org>
      Tested-by: default avatarPradyumna Sampath <pradysam@gmail.com>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Cc: Arjan van de Veen <arjan@infradead.org>
      LKML-Reference: <20100402204331.167439615@osadl.org>
      Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      351b3f7a
    • Arjan van de Ven's avatar
      timers: Introduce the concept of timer slack for legacy timers · 3bbb9ec9
      Arjan van de Ven authored
      While HR timers have had the concept of timer slack for quite some time
      now, the legacy timers lacked this concept, and had to make do with
      round_jiffies() and friends.
      
      Timer slack is important for power management; grouping timers reduces the
      number of wakeups which in turn reduces power consumption.
      
      This patch introduces timer slack to the legacy timers using the following
      pieces:
      * A slack field in the timer struct
      * An api (set_timer_slack) that callers can use to set explicit timer slack
      * A default slack of 0.4% of the requested delay for callers that do not set
        any explicit slack
      * Rounding code that is part of mod_timer() that tries to
        group timers around jiffies values every 'power of two'
        (so quick timers will group around every 2, but longer timers
        will group around every 4, 8, 16, 32 etc)
      Signed-off-by: default avatarArjan van de Ven <arjan@linux.intel.com>
      Cc: johnstul@us.ibm.com
      Cc: Ingo Molnar <mingo@elte.hu>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      3bbb9ec9
  2. 23 Mar, 2010 2 commits
  3. 15 Mar, 2010 22 commits
  4. 14 Mar, 2010 13 commits