]> git.proxmox.com Git - mirror_zfs.git/commitdiff
Don't wakeup unnecessarily in 'zpool events -f'
authorDeHackEd <DeHackEd@users.noreply.github.com>
Mon, 5 Aug 2019 18:35:47 +0000 (14:35 -0400)
committerMatthew Ahrens <mahrens@delphix.com>
Mon, 5 Aug 2019 18:35:47 +0000 (11:35 -0700)
ZED can prevent CPU's from properly sleeping.

Rather than periodically waking up in the zevents code, just go to sleep and wait for a wakeup.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: DHE <git@dehacked.net>
Closes #9091

module/zfs/fm.c

index cc5225dcbbef0ba6be86586955ae166903699349..0a0fc79bd372866e87e36ebc9744718e74cbc91a 100644 (file)
@@ -683,8 +683,7 @@ zfs_zevent_wait(zfs_zevent_t *ze)
                        break;
                }
 
-               error = cv_timedwait_sig(&zevent_cv, &zevent_lock,
-                   ddi_get_lbolt() + MSEC_TO_TICK(10));
+               error = cv_wait_sig(&zevent_cv, &zevent_lock);
                if (signal_pending(current)) {
                        error = SET_ERROR(EINTR);
                        break;