]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/commit
MFC r321207:
authorken <ken@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Mon, 24 Jul 2017 14:42:45 +0000 (14:42 +0000)
committerken <ken@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Mon, 24 Jul 2017 14:42:45 +0000 (14:42 +0000)
commitfc9054ba3a8aaea9284b4540bf2a568be7706b75
treeccd8fc915ed9f3a54cc0b458c45faa1a5d01053c
parent2124b022a81793e418199fb94af05feb3a3ca1ee
MFC r321207:
  ------------------------------------------------------------------------
  r321207 | ken | 2017-07-19 09:39:01 -0600 (Wed, 19 Jul 2017) | 14 lines

  Fix spurious timeouts on commands sent to mps(4) and mpr(4) controllers.

  mps_wait_command() and mpr_wait_command() were using getmicrotime() to
  determine elapsed time when checking for a timeout in polled mode.
  getmicrotime() isn't guaranteed to monotonically increase, and that
  caused spurious timeouts occasionally.

  Switch to using getmicrouptime(), which does increase monotonically.
  This fixes the spurious timeouts in my test case.

  ------------------------------------------------------------------------
Reviewed by: slm, scottl
Sponsored by: Spectra Logic

git-svn-id: svn://svn.freebsd.org/base/stable/10@321416 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
sys/dev/mpr/mpr.c
sys/dev/mps/mps.c