)]}'
{
  "commit": "c64aa319f7c8550f870743880a1098a755dcb950",
  "tree": "6f13bb0b63bf5d540ac50e8ccc1c033e91260d89",
  "parents": [
    "d23f0517357ef48d2845846e899d125b3c1a492e"
  ],
  "author": {
    "name": "Takashi Iwai",
    "email": "tiwai@suse.de",
    "time": "Sun Apr 24 22:52:18 2016 +0200"
  },
  "committer": {
    "name": "Takashi Iwai",
    "email": "tiwai@suse.de",
    "time": "Sun Apr 24 23:24:15 2016 +0200"
  },
  "message": "ALSA: hrtimer: Handle start/stop more properly\n\nThis patch tries to address the still remaining issues in ALSA hrtimer\ndriver:\n- Spurious use-after-free was detected in hrtimer callback\n- Incorrect rescheduling due to delayed start\n- WARN_ON() is triggered in hrtimer_forward() invoked in hrtimer\n  callback\n\nThe first issue happens only when the new timer is scheduled even\nwhile hrtimer is being closed.  It\u0027s related with the second and third\nitems; since ALSA timer core invokes hw.start callback during hrtimer\ninterrupt, this may result in the explicit call of hrtimer_start().\n\nAlso, the similar problem is seen for the stop; ALSA timer core\ninvokes hw.stop callback even in the hrtimer handler, too.  Since we\nmust not call the synced hrtimer_cancel() in such a context, it\u0027s just\na hrtimer_try_to_cancel() call that doesn\u0027t properly work.\n\nAnother culprit of the second and third items is the call of\nhrtimer_forward_now() before snd_timer_interrupt().  The timer-\u003estick\nvalue may change during snd_timer_interrupt() call, but this\npossibility is ignored completely.\n\nFor covering these subtle and messy issues, the following changes have\nbeen done in this patch:\n- A new flag, in_callback, is introduced in the private data to\n  indicate that the hrtimer handler is being processed.\n- Both start and stop callbacks skip when called from (during)\n  in_callback flag.\n- The hrtimer handler returns properly HRTIMER_RESTART and NORESTART\n  depending on the running state now.\n- The hrtimer handler reprograms the expiry properly after\n  snd_timer_interrupt() call, instead of before.\n- The close callback clears running flag and sets in_callback flag\n  to block any further start/stop calls.\n\nSigned-off-by: Takashi Iwai \u003ctiwai@suse.de\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "656d9a9032dc2165d1f30f4ef193250a07bec555",
      "old_mode": 33188,
      "old_path": "sound/core/hrtimer.c",
      "new_id": "e2f27022b363c482ba2614a2579f87f2b19192e3",
      "new_mode": 33188,
      "new_path": "sound/core/hrtimer.c"
    }
  ]
}
