Message ID | 20230704100818.30263-1-mwilck@suse.com (mailing list archive) |
---|---|
State | Not Applicable, archived |
Delegated to: | christophe varoqui |
Headers | show |
Series | Fixup "libmultipath: fix dev_loss_tmo even if not set in configuration" | expand |
diff --git a/libmultipath/discovery.c b/libmultipath/discovery.c index 285cbd6..5626d48 100644 --- a/libmultipath/discovery.c +++ b/libmultipath/discovery.c @@ -895,9 +895,11 @@ sysfs_set_scsi_tmo (struct config *conf, struct multipath *mpp) continue; } - if (pp->dev_loss < min_dev_loss) { - warn_dev_loss = (pp->dev_loss != DEV_LOSS_TMO_UNSET); + if (pp->dev_loss == DEV_LOSS_TMO_UNSET) pp->dev_loss = min_dev_loss; + else if (pp->dev_loss < min_dev_loss) { + pp->dev_loss = min_dev_loss; + warn_dev_loss = true; } if (pp->dev_loss != DEV_LOSS_TMO_UNSET && pp->fast_io_fail > 0 &&